require()statements explicitly reference
This solves a problem when requiring/importing
newrelic from a Typescript file.
- Check if
process.mainModule.filenameexists before using in missing config file check.
When the agent is preloaded with Node's
mainModule is not yet defined when the agent checks for a config file, resulting in a
TypeError in the event that no config file exists. Defaulting to the file path being executed in
process.argv ensures that the app will not crash when preloaded without a config file.
- Updated dev dependency tap to
- Fixed identification of errors with express.
Previously the call
next('router') was considered an error. This is actually valid usage of express and will no longer generate an error.
This legacy debug configuration was never used since trace-level logging provides everything this did and more.
- Upgraded optional dependency
With this update comes pre-built binaries for Node 5 and 7. GC metrics are also now aggregated in C++ until the agent is ready to harvest them instead of hopping into JS for each event.
- Added additional checks to
uninstrumentedensuring that files with names matching instrumented modules do not result in a false uninstrumented status.
For example, some users load config/env info before the agent. In that case, a file responsible for exporting DB config information (
config/redis.js), may result in a false uninstrumented status, because the agent would interpret
redis.js as the module itself.