- Fixed an error in the Connect and Express middleware instrumentation. Another tip of the hat to Jeff Howell at Kabam for identifying this problem and pointing to a solution!
- Rewrote the MongoDB instrumentation. Big thanks to Jeff Howell at Kabam for demonstrating a much more reliable and simple approach than what we had before! Also expanded the number of MongoDB methods instrumented to include more of the common operations and indexing operations.
- Changed the default value of the
top_nconfiguration parameter. Read the documentation inlib/config.default.jsfor the details (we've taken another run at making the docs fortop_neasier to understand), but the upshot is that by default you should see a greater diversity of slow transaction traces now. - Closed a hole in the transaction tracer related to Connect and Express-style middleware chains.
- Fixed issues identified by testing against various versions of 0.11 and master.
- Added guidelines for contributing to the module. Read CONTRIBUTING.md for details.
- Fixed a bug with the Connect instrumentation that would cause it to
crash when using Connect's static middleware in strict mode. Using
ES5 future reserved keywords for function names is a bad idea, and
this is why, but static's name is highly unlikely to change. For
those of you who are examining the state of your middleware stack after
configuring it, you probably shouldn't be doing that, but if you run into
problems with the New Relic agent installed, try changing your test to use
name.indexOf('whatever') === 0as the predicate instead ofname === 'whatever'.
- Prevent requests from being double-counted by changing the tracer to always reuse existing transactions rather than trying to nest them.
- Changed the Connect instrumentation to preserve the names of middleware functions after wrapping them. If you need this change, you should probably change your code so you don't need it anymore.
- Added a bunch of server-side configuration options that are known but unsupported to the agent.
- IMPORTANT. There have been MAJOR CHANGES in how requests are named for
display and aggregation in the New Relic user interface. Read the section in
the README on transactions and request naming for details. For good measure,
read it twice. If your requests are all still ending up named
/*, read it a third time. This is especially true if you're not using Express or Restify, in which case you will almost certainly want to make changes in how you configure New Relic. - IMPORTANT. New Relic for Node.js now supports the full range of server-side
configuration options offered by the New Relic web interface. By default,
server-side settings will override the settings in your configuration file
(or environment variables). You can disable server-side configuration by
setting
ignore_server_configurationtotruein your configuration file (or settingNEW_RELIC_IGNORE_SERVER_CONFIGURATIONto 'true'). - BREAKING CHANGE: The New Relic module now exports an API to be used for
naming transactions and for adding URL to transaction name mapping rules. If
you were using
require('newrelic')as an interface to the agent's configuration or its internals, you'll need to fix your code (also you probably shouldn't have been doing that). - BREAKING CHANGE: The configuration parameter
transaction_tracer.trace_thresholdhas been renamedtransaction_tracer.transaction_thresholdto make it consistent with New Relic's other agents. - Applications using the Express or Restify routers will now have their requests named after the matching routes. These names can be overridden but the transaction-naming API.
- There are new configuration parameters for adding rules for naming or ignoring requests. The README has a good example for how to keep socket.io from blowing out your average response time. You should read it!
- Tweaked the calculation of exclusive time in transaction traces, which should make more of the transaction trace detail pages make sense.
- Fixed a regression in
beta-25that caused the agent to incorrectly calculate an important timestamp, thus leading to data not showing up in New Relic. - Improved in-memory aggregation (when the connection between the agent and New Relic is unavailable or failing).
- Fixed a serious error in how the agent handles communication errors when sending errors to New Relic. If you're running v0.10.0 or v0.10.1, upgrade sooner rather than later, as those versions are losing data.
- Substantially improved the quality of reporting on errors noticed by the Node agent. Stack traces, scopes, and messages should be much better.
- The instrumentation for
httpno longer assumes that the hostname for external requests will be namedhost(hostnameis also allowed, andhttp.request()defaults tolocalhost). - The Node agent and New Relic's servers disagreed about what many metrics should be called. The agent was wrong and it regrets the error.
- Minor tweaks to database instrumentation (MongoDB and MySQL) that could have a small but visible impact on the overview display.
- IMPORTANT. The transaction tracer in this build is COMPLETELY NEW. This means that the agent will probably work just fine under Node 0.8 and newer, but Node versions 0.6 and older are presently unsupported, and support for them may or may not come back. However, the quality of the metrics gathered by the agent is now vastly improved.
- There are over 100 commits included in this build. Every effort has been made to ensure that we will not crash your applications, but be aware there may be regressions.
- Substantially more information is displayed by New Relic for slow transaction traces. How this information is displayed is a work in progress, as New Relic works to create a consistent user experience for developers writing both synchronous and asynchronous applications.
- Most Redis and memcached operations will now provide details on which keys were involved in an operation.
- The error tracer has been given a new coat of paint as well, and takes better advantage of Node domains, when they're available. Fewer errors should be double-counted, as well.
- MongoDB instrumentation is substantially improved.
- Express instrumentation now deals with the removal of the (very helpful) version field from recent versions of Express.
- Exclusive durations are reported for metrics, improving transaction breakdowns.
- Several bugs in the communication between the New Relic agent and New Relic's servers have been fixed.
- Failed connection attempts between the agent and New Relic's servers no longer cause aggregated metrics to be lost, nor will this trigger an agent crash.
- Capture request URL before Express can mess with it.
- Don't try to connect without a license key.
- Clear out previous connection listeners on failed connection attempts.
- Don't crash when normalizing paths without a leading slash.
- The implementation of domains changed in Node 0.10.x, which necessitated a fair amount of work on the error tracer to preserve the existing error tracer behavior.
- The error tracer no longer improperly swallows thrown errors.
- The agent no longer assumes that a home directory is set.
- The agent now works correctly with the
shouldassertion helper library.
- HTTPS instrumentation is both more complete and far better tested.
- Restify servers using HTTPS listeners should now be properly instrumented.
;is now treated as a query separator in URLs, just like?.- When using
stdoutorstderrfor logging and not using a configuration file, logging will now work as expected. - The error-handling code for DNS lookup of New Relic's servers was itself erroneous. It should no longer crash instrumented apps when DNS lookup fails.
- Simplified agent startup process.
- Using fs.readdir will no longer crash the agent and your apps. Oops!
- Added error-tracing middleware for Connect 1 & 2 applications, which includes Express 2 and 3 applications. This middleware is inserted automatically and transparently. Because it's common for end-user error handlers to not propagate errors (by calling next(error) from within the handler), the instrumentation inserts the middleware before the first error handler added to the middleware chain.
- The node-redis driver now correctly traces Redis calls made without a callback.
- Connections to New Relic that partially succeeded will now correctly keep attempting to connect until the connection succeeds or the number of retries is exhausted.
- Added a handler for yet another kind of New Relic server error (RuntimeError).
- For some of the modules instrumented by the agent (fs, http, Express 2 and 3), the error tracer now adds error tracing to wrapped function calls. This means that more of the functions in those modules will send traced errors to New Relic, even if they're trapping errors themselves. Also improves error tracer in versions of Node without domains. The error tracer rethrows all caught errors, so as to not alter behavior of instrumented apps.
- The error count sent by the agent was frequently incorrect due to an off-by-one bug.
- Include the entire stacktrace in traced errors.
- When the agent fails to successfully connect to New Relic's servers, it will try 6 more times, progressively waiting longer between each failed attempt. If no connection can be made, the agent will shut itself down.
- The agent no longer crashes instrumented applications when DNS resolution fails during the initial handshake with New Relic's servers. It logs the failures instead and retries later.
- The agent no longer alters the behavior of the generic-pool module in a way that causes modules using it to break (including node-postgres).
- In some cases, the domains-based error tracer was not working correctly.
- The agent logs significantly more useful debugging information.
- The agent's built-in compression for sending large payloads to New Relic wasn't correctly handling the Buffer returned by zlib, leading to a crash.
- In some cases, the monkeypatching used by the instrumentation wasn't written sufficiently defensively, leading to applications crashing at startup when using the agent.
- Changed how packages and dependencies are serialized when sent to New Relic's servers.
- When New Relic's servers (or an intermediate proxy) returned a response with a status code other than 20x, the entire instrumented application would crash.
- Some metric normalization rules were not being interpreted correctly, leading to malformed normalized metric names.
- Metric normalization rules that specifed that matching metrics were to be ignored were not being enforced.
- Fixed the agent's auto-restart support to cleanly shut down the connection (also fixed a bunch of bugs in restart).
- When server-side configuration changes, the agent will now correctly restart when told to do so by New Relic's servers.
- Correctly wrap net.Server.prototype.listen -- wasn't returning the server object, which broke some apps.
- If you're on a SmartOS VM with a 64-bit base image and a 64-bit build of Node that's v0.8.5 or earlier, the agent will no longer cause Node to crash. Don't even ask.
- Squared up the environment variable names with existing practice, especially with an eye towards conformity with Heroku documentation.
- Flushed out all configuration used anywhere in the agent and made sure it was documented in config.default.js.
- Using the new environment setting NEW_RELIC_NO_CONFIG_FILE, override the need to have a settings file at all.
- Add the ability to send log output to stdout or stderr.
- Can now configure the agent via environment variables. See README.md for details.
- Can now configure the location of the agent log via either logging.filepath in the configuration file, or NR_LOGGING_FILEPATH in the app's environment.
- Turning off the error tracer via configuration now actually disables it.
- Express view rendering was being instrumented improperly before, causing rendering to fail and Express to hang. Both Express 2 and 3 were affected, and both have been fixed.
- When NODE_PATH is set, resolve NODE_PATH elements properly so that package lookup for environmental information gathering doesn't crash the app.
- Now send the Node version along with the rest of the environment data.
- Added first cut at support for error tracing via Node.js 0.8+ domains. Versions of Node.js that support it (v0.8.9 and above) will make a best-faith effort to clean up after errors.
- Improved non-domain error handling on outbound HTTP requests.
- Dramatically improved accuracy of HTTP request timing.
- Be more careful in dealing with HTTP requests.
- Further improvements to node-mongodb-native instrumentation.
- Package now available via npm as "newrelic".
- Send a list of the packages and dependencies available to an app on connection to New Relic servers.
- Generally cleaned up submission of configuration information.
- Added trace-level logging of instrumentation to help diagnose issues with transaction tracing.
- Fixes to web error transaction reporting.
- Added support for node-mysql 2.0.0a driver series.
- Added support for Express 3.
- Added rudimentary instrumentation for node-redis.
- Added rudimentary support for generic-pool (for use with MySQL).
- Fixed view instrumentation for Express.
- Improved coverage of MongoDB driver.
- Many small fixes to make logging more robust.
- Don't return a partially initialized agent -- shut agent down gracefully if startup fails.
- Fixed an issue in how transaction traces were serialized that kept them from being displayed within RPM.
- Added request parameters to transaction traces, as well as URL normalization.
- Reconciled segment names in transaction traces with the corresponding metric names.
- Changed the logging module to bunyan. This means that logs are now stored
as JSON. If you want pretty-printed logs,
npm install -g bunyanand then use the bunyan CLI tool to format and filter the logs. - The agent now sets the logging level to the configured level. Logs sent to New Relic should have been captured at the 'trace' level for the duration of the beta.
- Fixed metric -> ID renaming semantics.
- Verified that agent works with Node 0.8's cluster module.
- Completely new transaction tracer. Faster, simpler and vastly more deterministic, but the reworking likely introduced a bunch of new bugs. This also means that the agent no longer directly affects the call stack or overrides any of the core event-handling methods, which means the overhead of the transaction tracer is vastly reduced. Which is good, because you still can't turn it off.
- Transaction traces should now report the correct caller-callee relationships.
- Transaction tracer is now internally instrumented, for better debugging.
- Added support for Restify.
- Using the Node.js agent in Restify app no longer causes them to crash (fixes NA-47).
- Improved support for Express (NA-8).
- Lots of fixes to the MongoDB, MySQL and memcached instrumentation.
- MongoDB instrumentation no longer crashes MongoDB apps that include the agent (NA-48).
- More testing in Node.js 0.6.x (hard to completely test, as node-tap isn't that friendly to Node < 0.6.21).
- Transaction trace durations are now reported properly (were seconds, now milliseconds).
- The agent no longer causes Restify applications to crash.
- The internal Node metrics sampler now shuts itself down properly.
- Improved timing of Express / Connect request handlers.
- Added support for internal supportability metrics (enabled via setting debug.internal_metrics to true in newrelic.js).
- By popular demand, support for Node 0.6.x. Tested against versions 0.6.5 and 0.6.19.
- Transaction traces no longer crash the RPM transaction trace viewer.
- The Node.js agent now follows the rules for Top N slow trace gathering.
- Compress large requests before submitting them to the New Relic collector.
- trace_threshold can now be configured from the server, and is not hard coded to apdex_f.
- The agent definitely doesn't work (for now) in Node 0.6.x and earlier. The agent will now notify developers (on the console) that it's refusing to start up under old versions, but won't crash the app.
- Don't crash the instrumented app if config is missing.
- The agent faithfully records and reports basic metrics.
- The agent reports error metrics.
- The agent gathers basic slow transaction trace data.
- The agent reports transaction trace data.