elastic / ecs-logging-nodejs

https://www.elastic.co/guide/en/ecs-logging/nodejs/master/intro.html
Apache License 2.0
68 stars 39 forks source link

fix: use req.originalUrl (express, fastify) #167

Closed trentm closed 1 year ago

trentm commented 1 year ago

Use req.originalUrl, if available, when converting req to ECS fields. This is necessary because Express, and possibly Fastify, will mutate req.url during routing in some cases.

Fixes: https://github.com/elastic/ecs-logging-nodejs/issues/114