elastic / elastic/apm-agent-nodejs
Clean up payload stringification/truncation/cloning
Open
agent-nodejs
performance
- Dominant language
- JavaScript
- Stars
- 594
- Forks
- 244
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 16
Description
Today we clone some objects multiple times before sending them to the APM Server. There's no need for that and we could optimize it so that cloning only happens when needed.
Places where we always need to deep clone:
- HTTP headers
- Lambda context
In all other scenarios we technically don't need to clone. Though to make it easy to use, we could consider just always cloning `context.custom` no matter what, so that users didn't have to do this.
Contributor guide
Assessment
This issue has not been assessed yet.