This PR allows users to log extra environment information to the oink.log, if environment keys are specified.
If an optional env_vars array is passed to the middleware, the logs will have an additional Environment: line with specified environment keys and values:
This is especially useful for logging the request ID, since logs may be distributed among multiple app servers, and timestamps don't always line up exactly.
This PR allows users to log extra environment information to the oink.log, if environment keys are specified.
If an optional
env_vars
array is passed to the middleware, the logs will have an additionalEnvironment:
line with specified environment keys and values:This is especially useful for logging the request ID, since logs may be distributed among multiple app servers, and timestamps don't always line up exactly.