mirror of
https://github.com/actix/actix-extras.git
synced 2025-02-22 18:33:18 +01:00
Request ID in Response Header
This example shows how to set the RequestId
as a response header.
Running
You can launch this example with
cargo run
An actix-web
application will be listening on port 8080
.
You can fire requests to it with:
curl -v http://localhost:8080/hello
...
< HTTP/1.1 200 OK
< content-length: 12
< x-request-id: 1d5c5448-44d2-4051-ab59-985868875f94
...