As you get ready to migrate, review these major changes between the 8.x and 9.x series of the Ruby agent. You'll also learn about issues you could face while upgrading, which will ensure a successful migration to version 9.x.
Summary
The main changes include:
- Removed all deprecated configuration options
- Dropped support for Ruby 2.2 and 2.3
- Enabled thread tracing by default
- Removed deprecated instrumentation for gems
- Updated API method
set_transaction_name
- Removed deprecated API methods
See the milestone for 9.0 for more information.
Removed deprecated configuration
We've removed the following configuration options, so they will no longer work. Please update all configs to use the replacements listed below, and see our configuration documentation for details.
Removed | Replacement |
|
---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Removed support for Ruby 2.2 and 2.3
Ruby 2.2 and 2.3 are no longer supported by the Ruby agent. To continue using the latest Ruby agent version, please update to Ruby 2.4.0 or higher.
New Relic continues to support certain older Ruby versions even after they have fallen out of the officially supported maintenance window provided by the Ruby language development team (Ruby team). For example, as of March 31, 2023 the oldest Ruby version supported by the Ruby team will be version 3.0, whereas with Ruby agent version 9.0, Ruby versions 2.4 and higher are still supported. For more information about official Ruby team support of Ruby versions, see Ruby Maintenance Branches.
Enabled thread tracing by default
The configuration option instrumentation.thread.tracing
is now enabled by default. This configuration allows the agent to watch code occurring inside threads. Ruby agent 9.0 records instrumented code within threads and associates it with the current transaction.
If you're currently using custom thread instrumentation, this may be a breaking change. New transactions inside of threads will no longer start if one already exists.
If you are using the old UI, you may see segments named "#" in your transaction charts. When looking at the segment table, the full name is "Thread: #." These segments refer to thread instrumentation. See Issue#1859 for details.
Removed deprecated instrumentation
The following instrumented gems had been previously deprecated and are now no longer supported:
Acts As Solr
Authlogic
DataMapper
Rainbows
Sunspot
Versions of the following technologies had been previously deprecated and are no longer supported.
Passenger: 2.2.x - 4.0.x
Puma: 2.0.x
Grape: 0.2.0
Padrino: 0.14.x
Rails: 3.2.x
Sinatra: 1.4.x, 1.5.x
Mongo: 1.8.x - 2.3.x
Sequel: 3.37.x, 4.0.x
Delayed_Job: 2.0.x - 4.0.x
Sidekiq: 4.2.x
Excon: below 0.55.0
HttpClient: 2.2.0 - 2.8.0
HttpRb: 0.9.9 - 2.2.1
Typhoeus: 0.5.3 - 1.2.x
Bunny: 2.0.x - 2.6.x
ActiveMerchant: 1.25.0 - 1.64.x
Updated API method set_transaction_name
When the method NewRelic::Agent.set_transaction_name
is called, it will now always change the name and category of the currently running transaction to what's passed into the method. This is a change from previous agent versions.
Previously, if set_transaction_name
was called with a new transaction name and a new category that didn't match the category already assigned to a transaction, neither the new name nor category would be saved to the transaction.
If this method is being called in a situation in which it was previously ignored due to category differences, this will now change the name and category of the transaction.
Removed API method
The deprecated API method NewRelic::Agent.disable_transaction_tracing
has been removed. Instead use either NewRelic::Agent#ignore_transaction
to disable the recording of the current transaction or NewRelic::Agent.disable_all_tracing
to yield a block without collecting any metrics or traces in any of the subsequent calls.