Skip to content

response decoder: Roll forward ResponseDecoderHandle#41193

Merged
danzh2010 merged 7 commits intoenvoyproxy:mainfrom
danzh2010:rollforwardhandle
Sep 26, 2025
Merged

response decoder: Roll forward ResponseDecoderHandle#41193
danzh2010 merged 7 commits intoenvoyproxy:mainfrom
danzh2010:rollforwardhandle

Conversation

@danzh2010
Copy link
Copy Markdown
Contributor

@danzh2010 danzh2010 commented Sep 23, 2025

Commit Message: Reapply "response decoder: add new interfaces for life time tracking of response decoder (#41048)"

Additional Description: In addition to changes in #41048, this PR added a new constructor to ResponseDecoderWrapper to take a ResponseDecoderHandle to avoid accessing the decode object at anytime without checking its liveliness. It also changes ConnectivityGrid and HttpConnPoolImplBase to retain an ResponseDecoderHandle rather than directly referencing to ResponseDecoder during the async connection establishment.

Added a regression test for the crash observed with the previous change.

Risk Level: medium
Testing: new integration tests
Docs Changes: N/A
Release Notes: Y
Platform Specific Features: N/A
Runtime guard: envoy.reloadable_features.use_response_decoder_handle default true and envoy.reloadable_features.abort_when_accessing_dead_decoder default false

…of response decoder (envoyproxy#41048)"

This reverts commit bfd5b10.

Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
@repokitteh-read-only
Copy link
Copy Markdown

As a reminder, PRs marked as draft will not be automatically assigned reviewers,
or be handled by maintainer-oncall triage.

Please mark your PR as ready when you want it to be reviewed!

🐱

Caused by: #41193 was opened by danzh2010.

see: more, trace.

@repokitteh-read-only
Copy link
Copy Markdown

CC @envoyproxy/runtime-guard-changes: FYI only for changes made to (source/common/runtime/runtime_features.cc).

🐱

Caused by: #41193 was opened by danzh2010.

see: more, trace.

@danzh2010 danzh2010 marked this pull request as ready for review September 23, 2025 15:57
@danzh2010 danzh2010 changed the title Roll forward ResponseDecoderHandle response decoder: Roll forward ResponseDecoderHandle Sep 23, 2025
@danzh2010
Copy link
Copy Markdown
Contributor Author

/retest

@danzh2010
Copy link
Copy Markdown
Contributor Author

/assign @RyanTheOptimist @abeyad

abeyad
abeyad previously approved these changes Sep 23, 2025
Copy link
Copy Markdown
Contributor

@abeyad abeyad left a comment

Choose a reason for hiding this comment

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

Thanks @danzh2010 !

namespace Envoy {
namespace Router {

class UpstreamToDownstreamImplBase : public UpstreamToDownstream {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Just FYI, I think we'll have to update some Google-specific (internal) classes with this change.

EXPECT_EQ(0u, quic_session_.bytesToSend());
}

TEST_F(EnvoyQuicClientStreamTest, DecoderDestroyedBeforeDecoding1xxHeader) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

thanks for the test!

Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
@danzh2010
Copy link
Copy Markdown
Contributor Author

/retest

Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
@danzh2010
Copy link
Copy Markdown
Contributor Author

/retest

@danzh2010
Copy link
Copy Markdown
Contributor Author

I've address the test coverage issue. PTAL again!

Copy link
Copy Markdown
Contributor

@abeyad abeyad left a comment

Choose a reason for hiding this comment

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

Thanks @danzh2010 !

@danzh2010 danzh2010 merged commit c6fe45e into envoyproxy:main Sep 26, 2025
25 checks passed
eric846 pushed a commit to envoyproxy/nighthawk that referenced this pull request Oct 1, 2025
- Update the ENVOY_COMMIT and ENVOY_SHA in bazel/repositories.bzl to the latest Envoy's commit.
- Update .bazelrc to envoyproxy/envoy#40908
- Update tools/code_format/config.yaml to envoyproxy/envoy#41148
- Changes to support envoyproxy/envoy#41193

Signed-off-by: tomjzzhang <4367421+tomjzzhang@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants