• /
  • EnglishEspañolFrançais日本語한국어Português
  • Inicia sesiónComenzar ahora

Ruby agent release notesRSS

October 26, 2022
Ruby agent v8.12.0

v8.12.0

La versión 8.12.0 del agente de Ruby ofrece una nueva instrumentación de Elasticsearch. La versión 8.12.0 del agente de Ruby también aumenta el número predeterminado de eventos personalizados registrados, anuncia la obsolescencia de Ruby 2.3 y aporta una valiosa limpieza de código.

  • Soporte para la instrumentación de Elasticsearch

    Esta versión del agente de Ruby agrega compatibilidad para instrumentar automáticamente la gema elasticsearch. Las versiones 7.x y 8.x son compatibles. PR#1525

    Nombre de la configuraciónPor defectoComportamiento
    instrumentation.elasticsearchautoControla la instrumentación automática de la biblioteca de elasticsearch al inicio. Puede ser uno de auto, prepend, chain, disabled.
    elasticsearch.capture_queriesverdaderoSi true, el agente captura la consulta de Elasticsearch en la traza de la transacción.
    elasticsearch.obfuscate_queriesverdaderoSi true, el agente confunde la consulta de Elasticsearch en la traza de la transacción.
  • Aumento del límite de eventos personalizados

    Esta versión del agente de Ruby aumenta el límite predeterminado de eventos personalizados de 1000 eventos por minuto a 3000 eventos por minuto. Si se estaban limitando los eventos personalizados, este cambio permitirá enviar más eventos personalizados a New Relic. También hay un nuevo límite máximo configurable de 100 000 eventos por minuto. Para cambiar los límites, consulte la documentación de max_samples_stored. Para obtener más información sobre el cambio y cómo determinar si se están descartando eventos personalizados, consulte nuestra publicación en el Explorers Hub. PR#1541

  • Se descontinuó el soporte para Ruby 2.3

    Ruby 2.3 llegó al final de su vida útil el 31 de marzo de 2019. El agente de Ruby ha descontinuado el soporte para Ruby 2.3 y realizará cambios importantes para esta versión en su próximo lanzamiento principal, v9.0.0 (fecha de lanzamiento aún no planificada). Todas las versiones 8.x.x del agente seguirán siendo compatibles con Ruby 2.3.

  • Limpieza: elimine el código huérfano

    Tanto en el agente como en las pruebas unitarias, se han producido cambios a lo largo de los años que han dejado ciertas partes del código inalcanzables. Este código huérfano puede complicar el mantenimiento y la refactorización del código, por lo que solucionarlo puede ser muy útil. El miembro de la comunidad @ohbarye contribuyó con dos PR de limpieza separados para esta versión; uno para el agente y otro para las pruebas. PR#1537 PR#1548

    ¡Gracias a @ohbarye por contribuir con esta útil limpieza!

Declaración de apoyo

New Relic recomienda que actualice el agente Ruby regularmente y, como mínimo, cada 3 meses. A partir de este lanzamiento, la versión compatible más antigua es la 6.7.0.359.

October 11, 2022
Ruby agent v8.11.0

v8.11.0

Version 8.11.0 of the agent updates the newrelic deployments command to work with API keys issued to newer accounts, fixes a memory leak in the instrumentation of Curb error handling, further preps for Ruby 3.2.0 support, and includes several community member driven cleanup and improvement efforts. Thank you to everyone involved!

  • Added support for New Relic REST API v2 when using newrelic deployments command

    Previously, the newrelic deployments command only supported the older version of the deployments api, which does not currently support newer license keys. Now you can use the New Relic REST API v2 to record deployments by providing your user API key to the agent configuration using api_key. When this configuration option is present, the newrelic deployments command will automatically use the New Relic REST API v2 deployment endpoint. PR#1461

    Thank you to @Arkham for bringing this to our attention!

  • Cleanup: Performance tests, constants, rubocop-minitest assertions and refutations

    Community member @esquith contributed a whole slew of cleanup successes for our performance test configuration, orphaned constants in our code base, and RuboCop related improvements. PR#1406 PR#1408 PR#1409 PR#1411

    Thank you @esquith for these great contributions!

  • CI: Notify on a change from failure to success

    A super handy, much beloved feature of certain CI and build systems is to not only notify when builds start to fail, but also to notify again when the builds once again start to go green. Community member @luigieai was able to figure out how to configure our existing complex, multiple-3rd-party-action based GitHub Actions pipeline to notify on a switch back to success from failure. PR#1519

    This is much appreciated! Thank you, @luigieai.

  • Spelling corrections

    Community member @jsoref, author of the Check Spelling GitHub Action, contributed a significant number of spelling corrections throughout the code base. The intelligent issues that were flagged made for a more comprehensive review than a simple dictionary based check would have been able to provide, and the changes are much appreciated. PR#1508

    Thank you very much, @jsoref!

  • Ruby 3.2.0-preview2 compatibility

    Ruby 3.2.0-preview1 introduced a change to the way that Ruby reports VM stats and the approach was changed yet again to a 3rd approach with the preview2 release. New Relic reports on Ruby VM stats and is keeping track of the Ruby 3.2 development process to help ensure our customers with a smooth and worthwhile upgrade process once Ruby 3.2.0 (non-preview) is released. PR#1436

  • Bugfix: Fix memory leak in the Curb instrumentation

    Community member @charkost was able to rework the on_failure callback logic prepped via the agent's Curb instrumentation in order to avoid some nesting that was causing memory leaks. PR#1518

    Many thanks for both the heads up on the issue and the fix, @charkost!

Support statement

New Relic recommends that you upgrade the agent regularly and at a minimum every 3 months. As of this release, the oldest supported version is 6.7.0.359.

September 13, 2022
Ruby agent v8.10.1

v8.10.1

  • Bugfix: Missing unscoped metrics when instrumentation.thread.tracing is enabled

    Previously, when instrumentation.thread.tracing was set to true, some puma applications encountered a bug where a varying number of unscoped metrics would be missing. The agent now will correctly store and send all unscoped metrics.

    Thank you to @texpert for providing details of their situation to help resolve the issue.

  • Bugfix: gRPC instrumentation causes ArgumentError when other Google gems are present

    Previously, when the agent had gRPC instrumentation enabled in an application using other gems (such as google-ads-googleads), the instrumentation could cause the error ArgumentError: wrong number of arguments (given 3, expected 2). The gRPC instrumentation has been updated to prevent this issue from occurring in the future.

    Thank you to @FeminismIsAwesome for bringing this issue to our attention.

Support statement

New Relic recommends that you upgrade the agent regularly and at a minimum every 3 months. As of this release, the oldest supported version is 6.5.0.357.

August 17, 2022
Ruby agent v8.10.0

v8.10.0

  • New gRPC instrumentation

    The agent will now instrument gRPC activity performed by clients and servers that use the grpc RubyGem. Instrumentation is automatic and enabled by default, so gRPC users should not need to modify any existing application code or agent configuration to benefit from the instrumentation. The instrumentation makes use of distributed tracing for a comprehensive overview of all gRPC traffic taking place across multiple monitored applications. This allows you to observe your client and server activity using any service that adheres to the W3C standard.

    The following new configuration parameters have been added for gRPC. All are optional.

    Configuration nameDefaultBehavior
    instrumentation.grpc_clientautoSet to 'disabled' to disable, set to 'chain' if there are module prepending conflicts
    instrumentation.grpc_serverautoSet to 'disabled' to disable, set to 'chain' if there are module prepending conflicts
    instrumentation.grpc.host_denylist""Provide a comma delimited list of host regex patterns (ex: "private.com$,exception.*")
  • Code-level metrics functionality is enabled by default

    The code-level metrics functionality for the Ruby agent's CodeStream integration is now enabled by default after we have received positive feedback and no open bugs for the past two releases.

  • Performance: Rework timing range overlap calculations for multiple transaction segments

    Many thanks to GitHub community members @bmulholland and @hkdnet. @bmulholland alerted us to rmosolgo/graphql-ruby#3945. That Issue essentially notes that the New Relic Ruby agent incurs a significant perfomance hit when the graphql RubyGem (which ships with New Relic Ruby agent support) is used with DataLoader to generate a high number of transactions. Then @hkdnet diagnosed the root cause in the Ruby agent and put together both a proof of concept fix and a full blown PR to resolve the problem. The agent keeps track multiple segments that are concurrently in play for a given transaction in order to merge the ones whose start and stop times intersect. The logic for doing this find-and-merge operation has been reworked to a) be deferred entirely until the transaction is ready to be recorded, and b) made more performant when it is needed. GraphQL DataLoader users and other users who generate lots of activity for monitoring within a short amount of time will hopefully see some good performance gains from these changes.

  • Performance: Make frozen string literals the default for the agent

    The Ruby frozen_string_literal: true magic source code comment has now been applied consistently across all Ruby files belonging to the agent. This can provide a performance boost, given that Ruby can rely on the strings remaining immutable. Previously only about a third of the agent's code was freezing string literals by default. Now that 100% of the code freezes string literals by default, we have internally observed some related performance gains through testing. We are hopeful that these will translate into some real world gains in production capacities.

  • Bugfix: Error when setting the yaml configuration with transaction_tracer.transaction_threshold: apdex_f

    Originally, the agent was only checking the transaction_tracer.transaction_threshold from the newrelic.yml correctly if it was on two lines.

    Example:

    # newrelic.yml
    transaction_tracer:
    transaction_threshold: apdex_f

    When this was instead changed to be on one line, the agent was not able to correctly identify the value of apdex_f.

    Example:

    # newrelic.yml
    transaction_tracer.transaction_threshold: apdex_f

    This would cause prevent transactions from finishing due to the error ArgumentError: comparison of Float with String failed. This has now been corrected and the agent is able to process newrelic.yml with a one line transaction_tracer.transaction_threshold: apdex_f correctly now.

    Thank you to @oboxodo for bringing this to our attention.

  • Bugfix: Don't modify frozen Logger

    Previously the agent would modify each instance of the Logger class by adding a unique instance variable as part of the instrumentation. This could cause the error FrozenError: can't modify frozen Logger to be thrown if the Logger instance had been frozen. The agent will now check if the object is frozen before attempting to modify the object. Thanks to @mkcosta for bringing this issue to our attention.

Support statement

New Relic recommends that you upgrade the agent regularly and at a minimum every 3 months. As of this release, the oldest supported version is 6.5.0.357.

July 11, 2022
Ruby agent v8.9.0

v8.9.0

  • Add support for Dalli 3.1.0 to Dalli 3.2.2

    Dalli versions 3.1.0 and above include breaking changes where the agent previously hooked into the gem. We have updated our instrumentation to correctly hook into Dalli 3.1.0 and above. At this time, 3.2.2 is the latest Dalli version and is confirmed to be supported.

  • Bugfix: Infinite Tracing hung on connection restart

    Previously, when using infinite tracing, the agent would intermittently encounter a deadlock when attempting to restart the infinite tracing connection. This bug would prevent the agent from sending all data types, including non-infinite-tracing-related data. This change reworks how we restart Infinite Tracing to prevent potential deadlocks.

  • Bugfix: Use read_nonblock instead of read on pipe

    Previously, our PipeChannelManager was using read which could cause resque jobs to get stuck in some versions. This change updates the PipeChannelManager to use read_nonblock instead to avoid this issue.

Support statement

New Relic recommends that you upgrade the agent regularly and at a minimum every 3 months. As of this release, the oldest supported version is 6.5.0.357.

June 2, 2022
Ruby agent v8.8.0

v8.8.0

  • Support Makara database adapters with ActiveRecord

    Thanks to a community submission from lucasklaassen with PR #1177, the Ruby agent will now correctly work well with the Makara gem. Functionality such as SQL obfuscation should now work when Makara database adapters are used with Active Record.

  • Lowered the minimum payload size to compress

    Previously the Ruby agent used a particularly large payload size threshold of 64KiB that would need to be met before the agent would compress data en route to New Relic's collector. The original value stems from segfault issues that very old Rubies (older than 2.2) used to encounter when compressing smaller payloads. This value has been lowered to 2KiB (2048 bytes), which should provide a more optimal balance between the CPU cycles spent on compression and the bandwidth savings gained from it.

  • Provide Code Level Metrics for New Relic CodeStream

    For Ruby on Rails applications and/or those with manually traced methods, the agent is now capable of reporting metrics with Ruby method-level granularity. When the new code_level_metrics.enabled configuration parameter is set to a true value, the agent will associate source-code-related metadata with the metrics for things such as Rails controller methods. Then, when the corresponding Ruby class file that defines the methods is loaded up in a New Relic CodeStream-powered IDE, the four golden signals for each method will be presented to the developer directly.

  • Supportability Metrics will always report uncompressed payload size

    New Relic's agent specifications call for Supportability Metrics to always reference the uncompressed payload byte size. Previously, the Ruby agent was calculating the byte size after compression. Furthermore, compression is only performed on payloads of a certain size. This means that sometimes the value could have represented a compressed size and sometimes an uncompressed one. Now the uncompressed value is always used, bringing consistency for comparing two instances of the same metric and alignment with the New Relic agent specifications.

Support statement

New Relic recommends that you upgrade the agent regularly and at a minimum every 3 months. As of this release, the oldest supported version is 6.5.0.357.

May 3, 2022
Ruby agent v8.7.0

v8.7.0

  • Reenvío de logs de logs en el contexto APM habilitado de forma predeterminada

    El reenvío automático de logs de aplicación ahora está habilitado por defecto. Esta versión del agente enviará automáticamente el log de aplicación enriquecido a New Relic. Para obtener más información sobre esta característica, consulte aquí, y las opciones de configuración adicionales están disponibles aquí. Para obtener información sobre cómo activar o desactivar la ingesta de logs por cuenta, consulte aquí.

  • Soporte asíncrono mejorado e instrumentación de Thread

    Anteriormente, el agente no podía registrar eventos y métricas dentro de los Hilos creados dentro de una transacción ya en ejecución. Esta versión incluye 2 nuevas opciones de configuración para permitir que las aplicaciones multihilo puedan instrumentar hilos automáticamente. Se ha introducido una nueva opción de configuración,instrumentation.thread.tracing (desactivada por defecto), que, cuando está habilitada, permitirá que el agente inserte el rastreo de New Relic dentro de todos los Hilos creados por una aplicación. Para admitir las aplicaciones que solo desean que algunos hilos estén instrumentados por New Relic, hay una nueva clase disponible, NewRelic::TracedThread, que creará un hilo que incluye la instrumentación de New Relic; consulte nuestra documentación de la API para obtener más detalles.

    Nuevas opciones de configuración incluidas en esta versión:

    Nombre de la configuración

    Por defecto

    Comportamiento

    instrumentation.thread

    auto (habilitado)

    Permite al agente anidar correctamente los spans dentro de una transacción asíncrona.

    instrumentation.thread.tracing

    false (desactivado)

    Agregar rastreo automáticamente a todos los hilos creados en la aplicación. Esto podría habilitarse de forma predeterminada en una versión futura.

    Nos gustaría agradecer a @mikeantonelli por compartir con nosotros un gist que le proporcionó a nuestro equipo un punto de entrada para esta característica.

  • Descontinuar la compatibilidad con Ruby 2.2

    Ruby 2.2 llegó al final de su vida útil el 31 de marzo de 2018. El agente ha descontinuado el soporte para Ruby 2.2 y realizará cambios incompatibles para esta versión en su próxima versión principal.

  • Se agregaron opciones de configuración actualizadas para eventos de transacción y se declararon obsoletas las configuraciones anteriores

    Esta versión marca como obsoleta la siguiente instrumentación:

    Obsoleto

    Reemplazo

    ActiveMerchant 1.64.0 o inferior

    ActiveMerchant 1.65.0 o superior

    ActiveRecord 3.2.22.5 o inferior

    ActiveRecord 4.0.0 o superior

    Acts As Solr (todas las versiones)

    ninguno

    Authlogic (todas las versiones)

    ninguno

    Bunny 2.6.7 o inferior

    Bunny 2.7.0 o superior

    Dalli 2.7.6 o inferior

    Dalli 2.7.7 o superior

    DataMapper (todas las versiones)

    ninguno

    Delayed Job 4.1.2 o inferior

    Delayed Job 4.1.3 o superior

    Excon 0.55.0 o inferior

    Excon 0.56.0 o superior

    Grape 0.19.1 o inferior

    Grape 0.19.2 o superior

    HTTPClient 2.8.2.4 o inferior

    HTTPClient 2.8.3

    HTTP.rb 2.2.1 o inferior

    HTTP.rb 2.2.2 o superior

    Mongo 2.4.0 o inferior

    Mongo 2.4.1 o superior

    Padrino 0.14.4 o inferior

    Padrino 0.15.0 o superior

    Passenger 5.1.2 o inferior

    Passenger 5.1.3 o superior

    Puma 3.8.2 o inferior

    Puma 3.9.0 o superior

    Rack 1.6.7 o inferior

    Rack 1.6.8 o superior

    Rails 3.2.22.5 o inferior

    Rails 4.0.0 o superior

    Rainbows (todas las versiones)

    ninguno

    Sequel 4.44.0 o inferior

    Sequel 4.45.0 o superior

    Sidekiq 4.2.10 o inferior

    Sidekiq 5.0.0 o superior

    Sinatra 1.4.8 o inferior

    Sinatra 2.0.0 o superior

    Sunspot (todas las versiones)

    ninguno

    Typhoeus 1.1.2 o inferior

    Typhoeus 1.3.0 o superior

    Unicorn 5.2.0 o inferior

    Unicorn 5.3.0 o superior

    Para las gemas con versiones descontinuadas, ya no probaremos esas versiones en la suite multiverse. Sin embargo, es posible que sigan siendo compatibles con el agente. Ya no solucionaremos los informes de errores para los problemas con estas versiones de la gema.

  • Aprovechar internamente Object.const_get y Object.const_defined?

    Al verificar u obtener dinámicamente una referencia a una constante de clase a partir de una cadena, aproveche los métodos integrados de la clase Object siempre que sea posible para lograr operaciones más sencillas y eficientes. Todos los JRubies y CRubies v2.5 y anteriores necesitan un poco de ayuda más allá de lo que Object puede proporcionar, dado que esos Rubies pueden generar una constante no deseada de un namespace diferente al que se especificó. Pero para todos los demás Rubies, e incluso para aquellos Rubies en contextos donde podemos confiar al 100 % en el valor de la cadena entrante, aproveche los métodos de la clase Object y disfrute de los beneficios.

  • Aclarar la documentación para la configuración de rake.tasks

    La descripción de rake.tasks en el archivo newrelic.yml predeterminado y la documentación de configuración del agente de Ruby de New Relic se han actualizado para aclarar su comportamiento y uso. La documentación ahora indica:

    Especifique una matriz de tareas de Rake a las que aplicar el instrumento automáticamente. Esta opción de configuración convierte la matriz en una lista de expresiones regulares. Si desea permitir todas las tareas de forma predeterminada, use rake.tasks: [.+]. Las tareas de Rake no tendrán un estado instrumentado a menos que se agreguen a esta lista. Para obtener más información, visite la (documentación de instrumentación de Rake de New Relic para el agente APM)[/docs/apm/agents/ruby-agent/background-jobs/rake-instrumentation].

    Agradecemos a @robotfelix por sugerir estos cambios.

  • Habilitar variables de entorno que establecen la configuración de matriz para que se conviertan en matriz

    Antes de este cambio, cuando se pasaban listas separadas por comas como variables de entorno, se emitía un error a newrelic_agent.log y se establecía un String como valor. Ahora, la matriz se convertirá con precisión.

  • Corrección de errores: permitir que TransactionEvents se muestree a la tasa esperada

    El valor de capacidad transaction_events.max_samples_stored dentro de TransactionEventAggregator no coincidía con el intervalo de su ciclo de recolección esperado, lo que provocaba un sobremuestreo de TransactionEvents. Esta corrección de errores se basa en las actualizaciones realizadas en #952 para que el intervalo y la capacidad se comporten según lo esperado para las opciones de configuración transaction_events* renombradas.

  • Corrección de error: faltan atributos en los eventos de error cuando se crean fuera de una transacción

    Anteriormente, el agente no asignaba una prioridad a los eventos de error que se creaban al llamar a notice_error fuera del alcance de una transacción. Esto provocó problemas con el muestreo cuando el búfer de eventos de error estaba lleno, lo que resultó en un NoMethodError: undefined method '<' for nil:NilClass en el newrelic_agent.log. Esta corrección de errores garantiza que siempre se asigne una prioridad a los eventos de error para que el agente pueda muestrear estos eventos de error correctamente. Gracias a @olleolleolle por informarnos sobre este problema.

Declaración de apoyo

New Relic recomienda que actualice el agente regularmente y, como mínimo, cada 3 meses. A partir de este lanzamiento, la versión compatible más antigua es la 5.7.0.350.

April 4, 2022
Ruby agent v8.6.0

v8.6.0

  • Telemetry-in-Context: Automatic Application Logs, a quick way to view logs no matter where you are in the platform

    • Adds support for forwarding application logs to New Relic. This automatically sends application logs that have been enriched to power Telemetry-in-Context. This is disabled by default in this release. This may be on by default in a future release.
    • Adds support for enriching application logs written to disk or standard out. This can be used with another log forwarder to power Telemetry-in-Context if in-agent log forwarding is not desired. We recommend enabling either log forwarding or local log decorating, but not both features. This is disabled by default in this release.
    • Improves speed and Resque support for logging metrics which shows the rate of log message by severity in the Logs chart in the APM Summary view. This is enabled by default in this release.

    To learn more about Telemetry-in-Context and the configuration options please see the documentation here.

  • Bugfix: Curb - satify method_with_tracing's verb argument requirement

    When Curb instrumentation is used (either via prepend or chain), be sure to always pass the verb argument over to method_with_tracing which requires it. Thank you to @knarewski for bringing this issue to our attention, for providing a means of reproducing an error, and for providing a fix. That fix has been replicated by the agent team with permission. See Issue 1033 for more details.

  • Improve the usage of the 'hostname' executable and other executables

    In all places where a call to an executable binary is made (currently this is done only for the 'hostname' and 'uname' binaries), leverage a new helper method when making the call. This new helper will a) not attempt to execute the binary if it cannot be found, and b) prevent STDERR/STDOUT content from appearing anywhere except New Relic's own logs if the New Relic logger is set to the 'debug' level. When calling 'hostname', fall back to Socket.gethostname if the 'hostname' binary cannot be found. When calling 'uname', fall back on using a value of 'unknown' if the 'uname' command fails. Many thanks to @metaskills and @brcarp for letting us know that Ruby AWS Lambda functions can't invoke 'hostname' and for providing ideas and feedback with Issue #697.

  • Documentation: remove confusing duplicate RUM entry from newrelic.yml

    The browser_monitoring.auto_instrument configuration option to enable web page load timing (RUM) was confusingly listed twice in the newrelic.yml config file. This option is enabled by default. The newrelic.yml file has been updated to list the option only once. Many thanks to @robotfelix for bringing this to our attention with Issue #955.

  • Bugfix: fix unit test failures when New Relic environment variables are present

    Previously, unit tests would fail with unexpected invocation errors when NEW_RELIC_LICENSE_KEY and NEW_RELIC_HOST environment variables were present. Now, tests will discard these environment variables before running.

Support statement

New Relic recommends that you upgrade the agent regularly and at a minimum every 3 months. As of this release, the oldest supported version is 6.3.0.355.

Copyright © 2026 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.