Notes
- Increased the default limit of custom events from 1,000 events per minute to 3,000 events per minute. In the scenario that custom events were being limited, this change will allow more custom events to be sent to New Relic. There is also a new configurable maximum limit of 100,000 events per minute. To change the limits, see the docs for custom_insights_events. To learn more about the change and how to determine if custom events are being dropped, see our Explorers Hub post. 
- Updated CI process to include collection of code coverage statistics. 
- Added a [doc about our current feature flags)(https://github.com/newrelic/node-newrelic/blob/main/documentation/feature-flags.md). 
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Removed legacy agent async context propagation. The default behavior is now what was behind the - feature_flag.new_promise_tracking. You can read more about the difference here.
- Fixed an issue with the ES Module loader that properly registers instrumentation when the file path included url encoded characters. 
- Added an API for enqueuing application logs for forwarding newrelic.recordLogEvent({ message: 'hello world', level: 'info' })`- Note: If you're including a serialized error make sure it's on the - errorkey of the log event:const error = new Error('testing errors');newrelic.recordLogEvent({ message: 'error example', level: 'error', error })
- Fixed - cassandra-driverinstrumentation to properly set instance details on query segments/spans.
- Added a new context manager that leverages AsyncLocalStorage for async context propagation. - This will be available via a feature flag config.feature_flag.async_local_context
- Alternatively you can set the environment variable of NEW_RELIC_FEATURE_FLAG_ASYNC_LOCAL_CONTEXT=1
- By enabling this feature flag it should make the agent use less memory and CPU.
 
- This will be available via a feature flag 
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Added instrumentation to bunyan to support application logging use cases: forwarding, local decorating, and metrics. Big thanks to @brianphillips for his contribution 
- Added c8 to track code coverage. 
- Added documentation about custom instrumentation in ES module applications 
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Added ability to instrument ES Modules with the New Relic ESM Loader. 
- Added support for custom ESM instrumentation. - There is structure to registering custom ESM instrumentation.  Set the relative path to the instrumentation entry point via api.esm.custom_instrumentation_entrypoint
- Sample custom ESM instrumentation entrypoint
- All the newrelic.instrument*methods will still work exceptnewrelic.instrumentLoadedModule. This is because it is geared toward CommonJS modules.
 
- There is structure to registering custom ESM instrumentation.  Set the relative path to the instrumentation entry point via 
- Added test for asserting ESM loader functionality on ESM-only package 
- Added supportability metric of - Supportability/Nodejs/Collector/MaxPayloadSizeLimit/<endpoint>when- max_payload_size_in_bytesconfiguration value is exceeded.
- Removed - application_logging.forwarding.enabledstanza from sample config as the feature is now enabled by default.
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Added experimental loader to support instrumentation of CommonJS packages in ECMAScript Module(ESM) applications. - It only supports versions of Node.js >= 16.12.0.
- It is subject to change due to its experimental stability.
 
- It only supports versions of Node.js >= 
- Enhanced supportability metrics for ESM support. - Added new metrics to track usage of ESM loader(Supportability/Features/ESM/LoaderandSupportability/Features/ESM/UnsupportedLoader).
- Updated instrumentation map to include an optional "friendly name" for tracking metrics.
 
- Added new metrics to track usage of ESM loader(
- Enabled re-throwing ESM import errors of - newrelic.jsso that the user is informed to rename it to- newrelic.cjs
- Fixed an issue with mongodb instrumentation where IPv6 address([::1]) was not getting mapped to localhost when setting the host attribute on the segment. 
- Added a test ESM loader to properly mock out agent in versioned tests. 
- Added ESM versioned tests for: - express,- pg,- mongodb, and- @grpc/grpc-js.
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Updated gRPC client instrumenation to respect - grpc.record_errorswhen deciding to log errors on gRPC client requests.
- Fixed transaction name finalization to properly copy the appropriate transaction name to root segment. 
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Added unit test suite for - lib/logger.js.
- Added destructive integration test for Configuration instantiation. 
- Added a special case to serialize BigInts when sending them to New Relic. BigInts can appear in log data that our customers may be trying to forward. 
- Exposed - compressed_content_encodingconfiguration and defaulted it to "gzip".
- Fixed public jsdoc generation. 
- Added - minamiback as a dev dependency for use with- jsdoc-conf.js.
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Fixed properly setting logging metrics when using custom levels with winston. 
- Handled setting the logging metric name to - UNKNOWNwhen using custom log levels in pino and/or winston. Thanks for your contribution @billouboq.
- Removed unnecessary unit test and fixture for OSS license generation. 
- Updated versioned tests to remove the use of the - asyncmodule.
- Removed 3rd party - asynclibrary from agent code.
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Added official parity support for Node 18. 
- BREAKING: Dropped Node 12.x support. For further information on our support policy, see Node agent compatibility. - Upgraded @newrelic/superagent@newrelic/aws-sdk@newrelic/koa@newrelic/native-metricsand@newrelic/test-utilitiesto the latest major versions
- Removed Node 12 from CI workflows.
- Updated engines stanza to be >=14.
- Updated all versioned tests stanza to be >=14
- Converted fs.rmdirSynctofs.rmSyncintest/unit/config/config-location.test.js.
- Converted uses of /dev/nulltoos.devNullin tests.
 
- Upgraded 
- BREAKING: Removed certificate bundle from agent. The configuration value - config.feature_flag.certificate_bundlewill no longer work.- The agent no-longer includes the New Relic certificate bundle when using the 'certificates' configuration (commonly with proxies). If you find this breaking your current environment, we recommend getting a CA bundle such as the one from Mozilla. 
- BREAKING: The agent now excludes port when making external HTTPS requests to port 443 to be in compliance with the spec and other agents. - Previous external segments would be named - External/example.com:443when using default HTTPS port. The external segment will now be named- External/example.com.
- BREAKING: Removed ability to disable async hooks based promise context tracking via the - await_supportfeature flag. This also removes the legacy Promise instrumentation.- Released the - await_supportfeature flag. The agent now relies on async_hooks to track async promise propagation. The net result is the if you had- feature_flag.await_supportset to false, the legacy instrumentation tracked every function in a promise chain as a separate segment.
- BREAKING: Removed instrumentation for the obsolete oracle npm package. 
- BREAKING: Updated the minimum version of - pgto be 8.2.x. This is the earliest support version that runs on Node 14+.
- BREAKING: Updated the minimum supported version of hapi to be >= v20.0.0. All versions < v20.0.0 are deprecated by hapi for security reasons, see their support policy. - Dropped tests for hapi < v20.0.0.
 
- Bumped - @newrelic/test-utilitiesto ^7.0.0.- This new version of test utilities defaults the number of concurrent jobs to currently available CPUs. For local development on modern machines, this can speed up full versioned test runs by 30-40%. 
- Introduced JOBS ENV var for agent versioned test runs to control number of attempted concurrent test folder runs. Set to 4 for CI runs in GHA. 
- Removed the async library from distributed tracing and pricing integration tests 
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.
Notes
- Fixed issue where instrumented code invoked within a @grpc/grpc-js client callback would not get tracked by the agent. - Bound the external client segment to the onReceiveStatus listener to propagate transaction context to the grpc client callbacks. 
- Fixed issue with truncate in - lib/util/application-logging.js. It now checks that the argument is a string before checking its length.
Support statement:
- New Relic recommends that you upgrade the agent regularly to ensure that you're getting the latest features and performance benefits. Additionally, older releases will no longer be supported when they reach end-of-life.