Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use golang/protobuf instead of gogo/protobuf #109

Open
wants to merge 142 commits into
base: main
Choose a base branch
from

Conversation

ebroberson
Copy link
Contributor

Summary

gogo/protobuf has been deprecated for years. We should be using up-to-date protobufs provided by google.golang.org/protobuf. In order to fit our use cases, a protobuf plugin (protoc-gen-go-bbs) has been created to catch any customizations we want to add.

Backward Compatibility

Breaking Change? No

Move optional to beginning of line
Remove json_name definitions where not needed
Remove extra Proto for ProtoRoutes
Regen protos
Rearrange some code for scope changes
Remove unnecessary check on len(msg.Enums)
Regen protos
Change file.proto definitions to match new convention
Regen protos
Resolve go vet and staticcheck
Regen protos
Resolve issues with unit tests
Add Protobuf Models doc
@ebroberson ebroberson marked this pull request as ready for review February 14, 2025 21:49
@ebroberson ebroberson requested a review from a team as a code owner February 14, 2025 21:49
New way:
DesiredLRPUpdate -> ProtoDesiredLRPUpdate -> Protobuf binary -> ProtoDesiredLRPUpdate -> DesiredLRPUpdate

2024-05-15: It remains to be seen if this extra layer is going to cause performance issues
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an ominous comment. Has any further investigation been done on the potential perf issues?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No specific perf testing has been done yet.

@geofffranks
Copy link
Contributor

I raised a couple questions, and fund a number of spots that could use either cleanup, or uncommenting depending on if the code is actually needed anymore.

I don't fully understand all the reasons for protoc-gen-bbs, and trying to understand how it's templating the generated code is breaking my brain.

This is very impressive, well done!

Add performance results for old (gogo) protobufs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

2 participants