-
Notifications
You must be signed in to change notification settings - Fork 683
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
feat: add interceptor for bufbuild/protovalidate #614
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this, this is great!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect, thanks a lot for this :)
…ling $(BUF) env in Makefile
The lint error seems to imply we need to rerun the generation script? https://github.com/grpc-ecosystem/go-grpc-middleware/actions/runs/5872315640/job/15923608916?pr=614 |
Thanks for your contribution! |
@johanbrandhorst and @gvencadze - awesome to see this has already landed! Are you open to a follow-up PR that adds an unimplemented |
Sounds reasonable, this hasn't hit a released version yet. |
Interceptor for validating incoming requests using bufbuild/protovalidate with Google's Common Expression Language (CEL) support (+ legacy protoc-gen-validate)
Changes
Validate()
interface, so I can't reuse already existing contract and codegenbuf.yaml
as depedency, I've tried to use it as local, but without any success. (If usage of protoc for codegen is important, I'll rework this moment)Verification
I've created sample project, with some proto APIs and check both modes of protovalidate - legacy (like in protoc-gen-validate) and new powered by Google's Common Expression Language (CEL)
I've added examples only for new mode