-
Notifications
You must be signed in to change notification settings - Fork 70
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
Force stop iteration after local response is sent #88
Conversation
I made the change almost identical to envoyproxy/envoy#13873 but something weird seems to happen here: with the change in Envoy, the decorder/encoder message like this and it looks fine (I mean, the local response is be sent to the client properly).
but with the change here, we have the following logs, and the response never is never returned to the client (curl in this case)
It seems like the change here somehow affects the encoder of local reply (I'm not sure how local response is handled in Envoy) and stops it from continuing 🤔 |
Signed-off-by: mathetake <[email protected]>
2814f7b
to
5cf9df2
Compare
Signed-off-by: mathetake <[email protected]>
same problem lingers on....... |
it seems to me that OnResponseHeaders and OnResponseBody are called in response to the sendLocalResponse? And the BaseContext used to handle these events must be the same the context which invoked sendLocalResponse, which means |
I'm know next to nothing about the internal behavior of local response, but the logs show that the filter addresses(?) are different |
Yes, |
Signed-off-by: mathetake <[email protected]>
Signed-off-by: mathetake <[email protected]>
… stop_iteration_ Signed-off-by: mathetake <[email protected]>
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.
This looks great, thanks! Although, I wonder if we should be so permissive and "fix" the broken code on the fly.
Similarly, could you open a PR in Envoy against your branch to verify that it passes all tests?
Signed-off-by: mathetake <[email protected]>
Signed-off-by: mathetake <[email protected]>
Agreed |
@PiotrSikora envoyproxy/envoy#13930 all tests passed! |
@mathetake It looks that we don't have good coverage, since this breaks send local reply in production code. |
@mathetake OK, I see the issue now. We're overriding "current" action with |
Resolves #13857 ref: -proxy-wasm/proxy-wasm-rust-sdk#44 -proxy-wasm/proxy-wasm-cpp-host#88 -proxy-wasm/proxy-wasm-cpp-host#93 Signed-off-by: mathetake <[email protected]>
…3930) Resolves envoyproxy#13857 ref: -proxy-wasm/proxy-wasm-rust-sdk#44 -proxy-wasm/proxy-wasm-cpp-host#88 -proxy-wasm/proxy-wasm-cpp-host#93 Signed-off-by: mathetake <[email protected]> Signed-off-by: Piotr Sikora <[email protected]>
* build: update rules_rust to allow Rustc in RBE (envoyproxy#13595) Signed-off-by: Lizan Zhou <[email protected]> Signed-off-by: Piotr Sikora <[email protected]> * fix macos v8 build (envoyproxy#13572) Signed-off-by: Rama Chavali <[email protected]> * wasm: update proxy-wasm-cpp-host (envoyproxy#13606) The PR updates proxy-wasm-cpp-host dependency for enhancing the capability and fixing a bug in WASM extensions. The change consists of three PRs in proxy-wasm-cpp-host: 1. proxy-wasm/proxy-wasm-cpp-host#68 @PiotrSikora 2. proxy-wasm/proxy-wasm-cpp-host#65 @mathetake (me) 3. proxy-wasm/proxy-wasm-cpp-host#64 @mathetake (me) The code change can be found at proxy-wasm/proxy-wasm-cpp-host@49ed20e...c5658d3 . 1 & 2 enhance WASM capability, and 3 fixes a bug in situations where users share vm_id for multiple filters. For details, please take a look at these original PRs. Signed-off-by: mathetake <[email protected]> Signed-off-by: Piotr Sikora <[email protected]> * wasm: re-enable tests with precompiled modules. (envoyproxy#13583) Fixes envoyproxy#12335. Signed-off-by: Piotr Sikora <[email protected]> * wasm: flip the meaning of the "repository" in envoy_wasm_cc_binary(). (envoyproxy#13621) Change the meaning of the "repository" parameter to refer to an external Bazel repository, instead of using "@envoy" in targets that are included in the Envoy repository. This aligns with other envoy_* rules. Signed-off-by: Piotr Sikora <[email protected]> * build: support ppc64le with wasm (envoyproxy#13657) The build has only been tested with gn git sha 5da62d5 as recommended by ppc64 maintainers of the v8 runtime. Signed-off-by: Christopher M. Luciano <[email protected]> * wasm: remove no longer needed Emscripten metadata. (envoyproxy#13667) Signed-off-by: Piotr Sikora <[email protected]> * fix wasm compilation (envoyproxy#13765) Signed-off-by: Asra Ali <[email protected]> * wasm: strip only Custom Sections with precompiled Wasm modules. (envoyproxy#13775) Signed-off-by: Piotr Sikora <[email protected]> * build: don't build shared libraries for zlib and zlib-ng. (envoyproxy#13652) Signed-off-by: Piotr Sikora <[email protected]> * wasm: update V8 to v8.7.220.10. (envoyproxy#13568) Signed-off-by: Piotr Sikora <[email protected]> * build: exclude wee8/out from inputs (envoyproxy#13866) If you build without sandboxing for performance, the output files from this custom build genrule contained timestamps which caused it to rebuild every single build. Signed-off-by: Keith Smiley <[email protected]> * tls: fix detection of the upstream connection close event. (envoyproxy#13858) Fixes envoyproxy#13856. Signed-off-by: Piotr Sikora <[email protected]> * wasm: Force stop iteration after local response is sent (envoyproxy#13930) Resolves envoyproxy#13857 ref: -proxy-wasm/proxy-wasm-rust-sdk#44 -proxy-wasm/proxy-wasm-cpp-host#88 -proxy-wasm/proxy-wasm-cpp-host#93 Signed-off-by: mathetake <[email protected]> Signed-off-by: Piotr Sikora <[email protected]> * wasm: fix order of callbacks for paused requests. (envoyproxy#13840) Fixes proxy-wasm/proxy-wasm-rust-sdk#43. Signed-off-by: Piotr Sikora <[email protected]> * wasm: fix network leak (envoyproxy#13836) Signed-off-by: Kuat Yessenov <[email protected]> Co-authored-by: Lizan Zhou <[email protected]> Co-authored-by: Rama Chavali <[email protected]> Co-authored-by: Takeshi Yoneda <[email protected]> Co-authored-by: cmluciano <[email protected]> Co-authored-by: asraa <[email protected]> Co-authored-by: Keith Smiley <[email protected]> Co-authored-by: Takeshi Yoneda <[email protected]> Co-authored-by: Kuat <[email protected]>
Signed-off-by: mathetake [email protected]
ref