Skip to content

protogen: guarantee message field's Tag Number compatibility #218

@wenchy

Description

@wenchy

See https://protobuf.dev/best-practices/dos-donts/

Don’t Re-use a Tag Number
Never re-use a tag number. It messes up deserialization. Even if you think no one is using the field, don’t re-use a tag number. If the change was live ever, there could be serialized versions of your proto in a log somewhere. Or there could be old code in another server that will break.

To guarantee both backward and forward compatibility, the field's tag number should be fixed (specified explicitly), to avoid frequent changes (due to column additions/deletions) if auto generated by tableau protogen.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions