Skip to content
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

Move request logging near the top of the middleware stack #2383

Merged

Conversation

jtgeibel
Copy link
Member

@jtgeibel jtgeibel commented Apr 2, 2020

By converting to a regular Middleware (instead of AroundMiddleware),
the logging can now sit near the top of the middleware stack.
Previously logging occurred at the top of the around stack, which sits
under the layers added via add().

This change ensures that middleware sitting below the request logger
in the stack are able to add logging metadata in a call to after().

r? @JohnTitor

By converting to a regular `Middleware` (instead of `AroundMiddleware`),
the logging can now sit near the top of the middleware stack.
Previously logging occurred at the top of the around stack, which sits
under the layers added via `add()`.

This change ensures that middleware sitting below the request logger
in the stack are able to add logging metadata in a call to `after()`.
@JohnTitor
Copy link
Member

Looks good! @bors r+

@bors
Copy link
Contributor

bors commented Apr 2, 2020

📌 Commit dc6f424 has been approved by JohnTitor

@bors
Copy link
Contributor

bors commented Apr 2, 2020

⌛ Testing commit dc6f424 with merge d983a7b...

@bors
Copy link
Contributor

bors commented Apr 2, 2020

☀️ Test successful - checks-travis
Approved by: JohnTitor
Pushing d983a7b to master...

@bors bors merged commit d983a7b into rust-lang:master Apr 2, 2020
@jtgeibel jtgeibel deleted the move-logging-near-top-of-middleware branch May 11, 2020 23:18
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