salvo-rs / salvo

A powerful web framework built with a simplified design.
https://salvo.rs
Apache License 2.0
3.26k stars 197 forks source link

Request Id #890

Closed lywa1998 closed 1 week ago

lywa1998 commented 2 weeks ago

Request Id 中的 overwrite 要求的 HeaderName 为::salvo::request_id, 但向请求头中添加的为 x-request-id,不知道能不能统一一下。

curl  -v -H "::salvo::request_id: 01J731EV60DKQQ64NXENAWA01Z" -X GET http://127.0.0.1:5800  

*   Trying 127.0.0.1:5800...
* Connected to 127.0.0.1 (127.0.0.1) port 5800 (#0)
> GET / HTTP/1.1
> Host: 127.0.0.1:5800
> User-Agent: curl/8.1.2
> Accept: */*
>
< HTTP/1.1 200 OK
< content-type: text/plain; charset=utf-8
< content-length: 46
< date: Fri, 06 Sep 2024 07:18:08 GMT
<
* Connection #0 to host 127.0.0.1 left intact
chrislearn commented 1 week ago

谢谢,似乎这里写错了,我修复一下。