From ba10534a5a402b6c13899363b9ac6e10546c0c59 Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Thu, 16 Feb 2023 17:09:28 -0800 Subject: [PATCH 1/5] Update CHANGELOG Update CHANGELOG to add feedback given in the migration guide --- CHANGELOG.md | 53 +++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 38 insertions(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fdad359c7a..d86e923dac 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,12 +2,12 @@ ## v9.0.0 - Version 9.0.0 of the agent removes several deprecated configuration options and API methods, enables thread tracing by default, adds fiber instrumentation, removes support for Ruby versions 2.2 and 2.3, removes instrumentation for several deprecated gems, changes how the API method `set_transaction_name` works, and updates `rails_defer_initialization` to be an environment variable only configuration option. + Version 9.0.0 of the agent removes several deprecated configuration options and API methods, enables Thread tracing by default, adds Fiber instrumentation, removes support for Ruby versions 2.2 and 2.3, removes instrumentation for several deprecated gems, changes how the API method `set_transaction_name` works, and updates `rails_defer_initialization` to be an environment variable only configuration option. -- **Remove Deprecated Configuration Options** +- **Remove deprecated configuration options** - The following configuration options have been removed in this version and will no longer work. Please replace them with the appropriate configurations. [PR#1782](https://github.com/newrelic/newrelic-ruby-agent/pull/1782) + The following configuration options have been removed and will no longer work. Please update all configs to use the replacements listed below. [PR#1782](https://github.com/newrelic/newrelic-ruby-agent/pull/1782) | Removed | Replacement | `newrelic.yml` example | | ----------------------------------------- | ----------------------------------------- | ----------------------------------------------------------------------------------- | @@ -52,38 +52,61 @@ -- **Enable Thread Instrumentation by default** +- **Enable Thread instrumentation by default** - The configuration option `instrumentation.thread.tracing` is now enabled by default. This will allow the agent to properly monitor code that occurs inside of threads. If you are currently using custom instrumentation to start a new transaction inside of threads, this may be a breaking change, as it will no longer start a new transaction if one already exists. [PR#1767](https://github.com/newrelic/newrelic-ruby-agent/pull/1767) + The configuration option `instrumentation.thread.tracing` is now enabled by default. This configuration allows the agent to properly monitor code occurring inside threads. In Ruby agent 9.0, instrumented code within threads will be recorded and associated with the current transaction when the thread was created. -- **Add Fiber Instrumentation** + This may be a breaking change if you are currently using custom thread instrumentation. New transactions inside of threads will no longer be started if one already exists. [PR#1767](https://github.com/newrelic/newrelic-ruby-agent/pull/1767) + +- **Add Fiber instrumentation** `Fiber` instances are now automatically instrumented similarly to `Thread` instances. This can be configured using `instrumentation.fiber`. [PR#1802](https://github.com/newrelic/newrelic-ruby-agent/pull/1802) -- **Ruby 2.2 and 2.3 Dropped** +- **Removed support for Ruby 2.2 and 2.3** - Support for Ruby 2.2 and 2.3 dropped with this release. They are no longer included in our test matrices and are not supported - for 9.0.0 and onward. [PR#1778](https://github.com/newrelic/newrelic-ruby-agent/pull/1778) + 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 above. [PR#1778](https://github.com/newrelic/newrelic-ruby-agent/pull/1778) -- **Instrumentation dropped for select gems** +- **Removed deprecated instrumentation** - Support for the following gems had been dropped. [PR#1788](https://github.com/newrelic/newrelic-ruby-agent/pull/1788) + Instrumentation for the following gems had been previously deprecated and has now been removed. [PR#1788](https://github.com/newrelic/newrelic-ruby-agent/pull/1788) - Acts As Solr - Authlogic - DataMapper - Rainbows - Sunspot + Versions of the following technologies had been previously deprecated and are no longer supported. + + - CRuby: 2.2.x, 2.3.x + - 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`** -- **Changes how the API method `set_transaction_name` works** + 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 is passed into the method. This is a change from previous agent versions. [PR#1797](https://github.com/newrelic/newrelic-ruby-agent/pull/1797) - 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 is passed in to the method. This is a change from how it functioned in previous agent versions. Previously, if `set_transaction_name` was called with a new transaction name and a new category that did not match the category that was already assigned to a transaction, neither the new name nor category would be saved to the transaction. [PR#1797](https://github.com/newrelic/newrelic-ruby-agent/pull/1797) + Previously, if `set_transaction_name` was called with a new transaction name and a new category that did not 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. -- **Dropped method: `NewRelic::Agent.disable_transaction_tracing`** +- **Removed API method: `NewRelic::Agent.disable_transaction_tracing`** - The previously deprecated `NewRelic::Agent.disable_transaction_tracing` method has been removed. Users are encouraged to use `NewRelic::Agent.disable_all_tracing` or `NewRelic::Agent.ignore_transaction`. [PR#1792](https://github.com/newrelic/newrelic-ruby-agent/pull/1792) + 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. [PR#1792](https://github.com/newrelic/newrelic-ruby-agent/pull/1792) - **Renamed ActiveJob metrics** From 56568fd2bdd9dd0585666c664e41dc1f6f66cf00 Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Fri, 17 Feb 2023 09:01:06 -0800 Subject: [PATCH 2/5] Remove CRuby from list --- CHANGELOG.md | 1 - 1 file changed, 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d86e923dac..1c2c16dcba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -78,7 +78,6 @@ Versions of the following technologies had been previously deprecated and are no longer supported. - - CRuby: 2.2.x, 2.3.x - Passenger: 2.2.x - 4.0.x - Puma: 2.0.x - Grape: 0.2.0 From 3588b245f177fbe1c38ba66ffe1ae89f36fd600d Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Fri, 17 Feb 2023 13:25:40 -0800 Subject: [PATCH 3/5] Move PR link around --- CHANGELOG.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1c2c16dcba..d6abe577b9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -98,10 +98,9 @@ - **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 is passed into the method. This is a change from previous agent versions. [PR#1797](https://github.com/newrelic/newrelic-ruby-agent/pull/1797) - - Previously, if `set_transaction_name` was called with a new transaction name and a new category that did not 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. + 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 is 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 did not 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. [PR#1797](https://github.com/newrelic/newrelic-ruby-agent/pull/1797) - **Removed API method: `NewRelic::Agent.disable_transaction_tracing`** From cf4511ab298afa5331908e8856986924b24d67f2 Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Fri, 17 Feb 2023 13:27:28 -0800 Subject: [PATCH 4/5] Remove second PR link --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d6abe577b9..cc8d86478f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -123,7 +123,7 @@ For those having troubles with agent initialization and Rails initializers, you can now pass the environment variable `NEW_RELIC_DEFER_RAILS_INITIALIZATION=true` to make the agent initialize after `config/initializers` are run. This config option can only be set using an environment variable and can't be set using YAML. [PR#1791](https://github.com/newrelic/newrelic-ruby-agent/pull/1791) - Thanks to [@jdelStrother](https://github.com/jdelStrother) for bringing this issue to our attention and testing our fixes along the way. [Issue#662](https://github.com/newrelic/newrelic-ruby-agent/issues/662) [PR#1791](https://github.com/newrelic/newrelic-ruby-agent/pull/1791) + Thanks to [@jdelStrother](https://github.com/jdelStrother) for bringing this issue to our attention and testing our fixes along the way. [Issue#662](https://github.com/newrelic/newrelic-ruby-agent/issues/662) ## 8.16.0 From 69c5455a3b26b45b67884d14aa16cf487628e5a4 Mon Sep 17 00:00:00 2001 From: Hannah Ramadan <76922290+hannahramadan@users.noreply.github.com> Date: Fri, 17 Feb 2023 13:31:42 -0800 Subject: [PATCH 5/5] Add link to fiber config --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cc8d86478f..4950388ae5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -60,7 +60,7 @@ - **Add Fiber instrumentation** - `Fiber` instances are now automatically instrumented similarly to `Thread` instances. This can be configured using `instrumentation.fiber`. [PR#1802](https://github.com/newrelic/newrelic-ruby-agent/pull/1802) + `Fiber` instances are now automatically instrumented similarly to `Thread` instances. This can be [configured](https://docs.newrelic.com/docs/apm/agents/ruby-agent/configuration/ruby-agent-configuration/#instrumentation-fiber) using `instrumentation.fiber`. [PR#1802](https://github.com/newrelic/newrelic-ruby-agent/pull/1802) - **Removed support for Ruby 2.2 and 2.3**