Introduction to transaction traces

In New Relic APM, a transaction trace gives a detailed snapshot of a single transaction in your application. A transaction trace records the available function calls, database calls, and external calls. You can use transaction traces to troubleshoot performance issues and to get detailed low-level insight into how your app is working.

Access to this feature depends on your subscription level.

Transaction trace basics

In New Relic APM, a transaction trace records the segments that make up a transaction. Because they give you more detail, you can use transaction traces to analyze and troubleshoot performance issues.

Here are the default rules that govern which transactions a New Relic agent traces:

  • Over the minute-long harvest cycle, all transactions that violate the threshold (either four times your Apdex T value or a specific number of seconds) are added to a pool of transactions.
  • At the end of that minute, the New Relic agent selects the slowest transaction in that pool and performs a transaction trace on it.

These are the general rules, but there are some agent-specific differences. To name one example: The Java agent collects occasional non-slow transactions. Another example: If one transaction is frequently traced, some agents will select other transactions to give a more diverse sampling.

If you don't see traces in your account, it's possible that no transactions meet the necessary criteria. If that's the case, you can adjust transaction trace settings to ensure some transactions will be traced.

If you use New Relic Synthetics, you will likely have Synthetics monitor traces. Synthetics traces can happen more frequently than APM traces: there may be several per minute.

Configure transaction traces

To learn how to edit transaction trace settings, see Configure transaction traces.

To learn how to create transaction traces for key transactions, see Tracing key transactions.

Find transaction traces in UI

APM - Transaction trace page

From rpm.newrelic.com, select APM > (selected app) > Transactions > (selected transaction trace): This is the transaction trace summary page in New Relic APM. You can also view in-depth details in the Trace details page and examine database queries, if present, in the Database queries page.

You can find transaction traces from either the APM Transactions page or the APM Overview page:

From the Transactions page

  1. From rpm.newrelic.com/apm, select an application and then select the Transactions page.
  2. Under Transaction traces, select a transaction trace to view that trace's Summary page.

From the Overview page:

  1. From rpm.newrelic.com/apm, click an app to view its Overview page.
  2. In the Transactions section, select a transaction trace link beneath a transaction. This will take you to that trace's Summary page.

Once you select a transaction trace, these are the main UI pages:

  • Summary page: The landing page when you select a transaction trace: it shows the slowest components and the attributes of a transaction.
  • Trace details page: Shows all recorded segments of a transaction, with links to associated stack traces and database query data.
  • Database queries page: Shows a table of all the database calls captured in the trace.
  • Cross-application trace map: If you have more than one app monitored by New Relic, this displays a map of their connections. (Not available for some New Relic agents.)

If you expect to see transaction traces but do not see them, see Troubleshooting: Not seeing transaction traces.

Video example: Troubleshoot an issue with transaction traces

Here is a video showing how to use transaction traces and error traces to troubleshoot an app performance issue:

 

[video link] To learn about using transaction traces and traced errors to troubleshoot your app, watch this video (approximately 16 minutes). View more videos and tutorials at learn.newrelic.com.

For more on using transaction traces, slow queries, and service maps to solve performance issues, see Analyze performance issues.

For more help

Join the discussion about New Relic APM in the New Relic Online Technical Community! The Technical Community is a public platform to discuss and troubleshoot your New Relic toolset.

If you need additional help, get support at support.newrelic.com.