elastic / elastic/ecs-logging-nodejs
url.full coming from req instead of ecs
Open
agent-nodejs
community
- Dominant language
- JavaScript
- Stars
- 69
- Forks
- 45
- PR merge metrics
- No merged PRs in 30d
Description
https://github.com/elastic/ecs-logging-nodejs/blob/26aaa6a8e75dd1cfe73023e81f676ef0a526b111/helpers/lib/http-formatters.js#L59
It looks like `url` attribute is being set with information from `req` instead of `ecs` like the rest of the attributes. This is causing `full` to reflect a different address than `domain` in our environment. Would this be more appropriate?
`ecs.url.full = (socket && socket.encrypted ? 'https://' : 'http://') + ecs.headers.host + ecs.url.path`
Contributor guide
Assessment
This issue has not been assessed yet.