Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
[Serve] Expose serve request id from http request/resp #35789
[Serve] Expose serve request id from http request/resp #35789
Changes from all commits
2d8bc37
1591c45
7a26549
43593fe
6f3de23
5b4dad7
be22390
e6ee3ce
3243ef9
1e3fb8f
a2ab1b8
83874b1
d01ddfb
3d091cd
8e4310f
38f8494
10c663c
10f2848
2330e28
2a22636
f43b10d
7377923
f26fee7
ccc7c55
dc6ba44
205b498
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
does this update the underlying
scope
passed in?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.
Not sure i understand the question, I assume all headers information for
http.response.start
is under the message directly.The
MutableHeaders
will only extract headers from the message https://github.com/encode/starlette/blob/2168e47052239da5df35d5353bb986f760c51cef/starlette/datastructures.py#L534There 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.
oh I'm just confused because you're never modifying the
message
here, doesheaders.append(RAY_SERVE_REQUEST_ID, request_id)
do it?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.
ah, yes. the
headers
object hold the message header Dict ref. and whenever you update theheaders
, it will update the message. It is same as you update the message header directly, but this is more standard instead of updating raw dict by yourself.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.
perfect thanks for explaining