Project

General

Profile

Actions

Feature #15863

closed

Log request IDs (tagged logging) in production.log

Added by Dominic Cleal almost 8 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Logging
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Request IDs can be added to Foreman's logs to make it easier to trace all log messages relating to a particular request when they interleave from multiple server processes.

Rails stores an ID in the request environment by default, and since Rails 5, the default configuration is to log it. The request ID is derived from the X-Request-ID header, otherwise a random UUID. Since Foreman uses the logging gem without tagging support instead of the default Rails logger, implementing this requires passing the extra information to its MDC/NDC (context) storage.


Related issues 3 (0 open3 closed)

Related to Foreman - Feature #15876: Send request and session ids to foreman-proxy as HTTP headersDuplicate07/28/2016Actions
Related to Foreman - Feature #10982: Add logging to smart proxy requests (ProxyAPI)ClosedDominic Cleal07/02/2015Actions
Related to Foreman - Bug #19017: Use request id instead of session id of tagged loggingClosedIvan Necas03/24/2017Actions
Actions

Also available in: Atom PDF