Closed jafingerhut closed 3 years ago
Hi @jafingerhut - this is from the Default Entry
section in the current spec:
The default entry is identified by setting the is_default_action boolean field to true. When this flag is set to true, the repeated match field must be empty and the priority field must be set to zero, otherwise the P4Runtime server must return an INVALID_ARGUMENT error code.
@antoninbas Thanks for pointing that out. Glad it is already covered in the spec, then. Closing this issue.
This is a minor corner case, not a big issue. I just happened to be looking at what the spec says about when you need to specify a priority value for a TableEntry, and I could have missed something, but it currently seems to imply that a priority must be provided if the table has at least one ternary, range, or optional key field.
For non-default table entries, I am in complete agreement.
The priority isn't really needed when modifying a default action for a table, though, is it?
Maybe the spec already mentions that corner case, not sure. If not, is it worth adding a sentence for this case?