slightly improve logging
This commit is contained in:
parent
3705d412b4
commit
4b3c723ce1
1 changed files with 1 additions and 2 deletions
|
@ -247,13 +247,12 @@ async fn main() {
|
|||
method = ?request.method(),
|
||||
path = ?request.uri().path(),
|
||||
matched_path,
|
||||
some_other_field = tracing::field::Empty,
|
||||
)
|
||||
})
|
||||
.on_response(|response: &Response<_>, duration: Duration, span: &Span| {
|
||||
let _ = span.enter();
|
||||
let status = response.status();
|
||||
info!(?status, ?duration);
|
||||
info!(?status, ?duration, "response");
|
||||
}),
|
||||
);
|
||||
|
||||
|
|
Loading…
Reference in a new issue