fix: save and restore pb state#9606
Conversation
There was a problem hiding this comment.
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.
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.
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.
Don't you need the grpc-transcode plugin to reproduce the problem?
There was a problem hiding this comment.
No.
Line 23 in 71c6048
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