-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
fix: save and restore pb state #9606
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.
It's a opentelemetry or grpc-transcode problem, add the test cases to opentelemetry2.t or grpc-transcode3.t, no need to create a new test file.
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.
No, it doesn't belong to any plugin, this is a common pb status issue with any plugin. It's best to use a stand-alone test file to highlight this issue.
local pb_old_state = pb.state(proto.pb_state) | ||
local ret = handle_error_response(status_detail_type) | ||
pb.state(pb_old_state) |
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.
Why not do this in handle_error_response
function, around pd.decode
like other place.
- example-plugin | ||
- key-auth | ||
- opentelemetry | ||
plugin_attr: |
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.
Don't you need the grpc-transcode plugin to reproduce the problem?
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.
No.
Line 23 in 71c6048
local compile_proto = require("apisix.plugins.grpc-transcode.proto").compile_proto |
Mark my last words. It does not depend on a specific plugin. Instead, it's a general problem with lua-protobuf lib usage.
Description
Fixes #9270
Checklist