Closed YuriGal closed 3 years ago
I don't know Fastify, but maybe something like this in your Pino config:
mixin() {
return { request_id: rTracer.id() };
},
https://github.com/pinojs/pino/blob/master/docs/api.md#mixin-function
Thanks for creating this issue. I was thinking of adding a sample for Pino, but didn't find the time to do this yet. Not sure if I find the time in the nearest future, so contributions are welcome (as always).
Not an issue, but rather request. Fastify already uses Pino under the hood as de facto logger. I am struggling to integrate cls-tracer with Pino in Fastify, so far without success. Would it be possible to provide an example of using cls-traces with Pino in fastify?