-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Make http3 codec not encode empty trailers block #35907
Conversation
Signed-off-by: Raven Black <[email protected]>
Signed-off-by: Raven Black <[email protected]>
Signed-off-by: Raven Black <[email protected]>
/retest |
(Failure appears to be a flake added in #34461) |
/retest |
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.
Nice! Thanks for fixing this. I think we should probably have a runtime guard for this, on the off chance that this behavior change breaks someone. LGTM otherwise.
Signed-off-by: Raven Black <[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.
docs/changelog nits ...
changelogs/current.yaml
Outdated
@@ -107,7 +107,9 @@ bug_fixes: | |||
- area: http3 | |||
change: | | |||
Fixed a bug where an empty trailers block could be sent. This would occur if a filter removed | |||
the last trailer - a likely occurrence with the ``grpc_web_filter``. | |||
the last trailer - a likely occurrence with the ``grpc_web_filter``. This change makes http3 codec | |||
behave the same way http2 codec does, converting an empty trailers block to no trailers. |
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.
behave the same way http2 codec does, converting an empty trailers block to no trailers. | |
behave the same way HTTP/2 codec does, converting an empty trailers block to no trailers. |
changelogs/current.yaml
Outdated
@@ -107,7 +107,9 @@ bug_fixes: | |||
- area: http3 | |||
change: | | |||
Fixed a bug where an empty trailers block could be sent. This would occur if a filter removed | |||
the last trailer - a likely occurrence with the ``grpc_web_filter``. | |||
the last trailer - a likely occurrence with the ``grpc_web_filter``. This change makes http3 codec |
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.
the last trailer - a likely occurrence with the ``grpc_web_filter``. This change makes http3 codec | |
the last trailer - a likely occurrence with the ``grpc_web_filter``. This change makes HTTP/3 codec |
changelogs/current.yaml
Outdated
the last trailer - a likely occurrence with the ``grpc_web_filter``. | ||
the last trailer - a likely occurrence with the ``grpc_web_filter``. This change makes http3 codec | ||
behave the same way http2 codec does, converting an empty trailers block to no trailers. | ||
This behavior can be reverted by setting the runtime guard ``envoy.reloadable_features.http3_remove_empty_trailers`` to false. |
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 behavior can be reverted by setting the runtime guard ``envoy.reloadable_features.http3_remove_empty_trailers`` to false. | |
This behavior can be reverted by setting the runtime guard ``envoy.reloadable_features.http3_remove_empty_trailers`` to ``false``. |
Signed-off-by: Raven Black <[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.
lgtm, thanks!
/retest |
2 similar comments
/retest |
/retest |
Commit Message: Make http3 codec not encode empty trailers block
Additional Description: http3 and
grpc_web_filter
combined resulted in an incompatibility with Chrome - a grpc web request received a response with an empty trailers block, which Chrome treats as a network error. The http2 codec had a special case in it for empty trailers, which was not mimicked in the http3 codec. This PR makes the http3 codec similar to the http2 codec in this respect, and adds an integration test ensuring that this behavior is in all downstream codecs.Risk Level: Small. It is a behavior change, but from an already malfunctioning state in a rare edge case.
Testing: Added integration test which fails before the change and passes after.
Docs Changes: n/a
Release Notes: Yes
Platform Specific Features: n/a