livery_request_id (livery v0.2.0)

View Source

Request-ID middleware.

Generates a fresh per-request identifier or honors an existing X-Request-ID header. The id is stored on the request value (livery_req:req_id/1) and echoed on the response so that clients and downstream services can correlate.

Identifiers are 32-character lowercase hex strings derived from crypto:strong_rand_bytes/1.

Summary

Functions

Run the middleware. State is unused.

Functions

call(Req, Next, State)

Run the middleware. State is unused.