-
-
Notifications
You must be signed in to change notification settings - Fork 10
Description
Using the proposed dynamic context from #293 we could create a Logger instance per request, which most importantly would allow us to attach logs to a transaction ID after determining we are in a GCP environment.
While doing this means we then have to pass this new ctx through every layer, it importantly would allow us to track all logs to a singular request, rather than having to piece it together mentally every time we have to look at the logs.
Additionally, being able to log anything attached to a specific request means we could log additional data not included in GCP logs by default, such as additional headers (specifically Server-Timing), or authenticated users on a request.
Potentially we could even use it to link frontend requests that trigger a backend request, so that we are able to track the full lifecycle of a singular request.