• EnglishEspañol日本語한국어Português
  • 로그인지금 시작하기

Ruby agent v6.0.0

January 28, 2019Download


  • Tracer API for flexible custom instrumentation

    With agent version 6.0, we are introducing the Tracer class, an officially supported public API for more flexible custom instrumentation. By calling its in_transaction method, you can instrument an arbitrary section of Ruby code without needing to juggle any explicit state. Behind the scenes, the agent will make sure that the measured code results in an APM segment inside a transaction.

    The same API contains additional methods for creating transactions and segments, and for interacting with the current transaction. For more details, see the custom instrumentation documentation.

    If you were previously using any of the agent's private, undocumented APIs, such as Transaction.wrap or Transaction.start/stop, you will need to update your code to use the Tracer API.

    The full list of APIs that were removed or deprecated are:

    • External.start_segment

    • Transaction.create_segment

    • Transaction.start

    • Transaction.stop

    • Transaction.start_datastore_segment

    • Transaction.start_segment

    • Transaction.wrap

    • TransactionState.current_transaction

      If are you using any of these APIs, please see the upgrade guide for a list of replacements.

  • Agent detects Rails 6.0

    The agent properly detects Rails 6.0 and no longer logs an error when started in a Rails 6.0 environment. This does not include full Rails 6.0 support, which will be coming in a future release. Thanks to Jacob Bednarz for the contribution.

Copyright © 2024 New Relic Inc.

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