36 std::chrono::system_clock::time_point
start;
routing::Middleware tracing(TracingOptions options={})
W3C Trace Context: continues the trace from an incoming traceparent header (or starts a new one),...
routing::Middleware request_id(RequestIdOptions options={})
Gives every request an ID (req.request_id) and echoes it in the response header, so a client report c...
routing::Middleware access_log(AccessLogOptions options={})
Logs one line per request when its response is sent: method, path, status, response bytes,...
Definition HttpRequest.hpp:19
std::function< bool(http::HttpRequest &, std::shared_ptr< http::ResponseWriter >)> Middleware
Definition Router.hpp:19
LogLevel
Definition Logger.hpp:16
Options for access_log().
Definition Observability.hpp:66
utils::LogLevel level
Definition Observability.hpp:67
Options for request_id().
Definition Observability.hpp:14
std::string header
Definition Observability.hpp:15
bool trust_incoming
Definition Observability.hpp:18
A finished request, as reported to TracingOptions::on_span_end.
Definition Observability.hpp:31
std::chrono::system_clock::time_point start
Definition Observability.hpp:36
std::chrono::microseconds duration
Definition Observability.hpp:37
std::string client_ip
Definition Observability.hpp:39
std::string span_id
16 hex digits
Definition Observability.hpp:33
std::string name
"GET /orders/42"
Definition Observability.hpp:35
int status
Definition Observability.hpp:38
std::string parent_span_id
From the incoming traceparent; empty for a root span.
Definition Observability.hpp:34
std::string trace_id
32 hex digits
Definition Observability.hpp:32
Options for tracing().
Definition Observability.hpp:45
std::function< void(const Span &)> on_span_end
Definition Observability.hpp:49