Transaction Trace Sampling

AppOptics APM instrumentation gathers not only metrics on application performance but also high-fidelity distributed trace data. Each traced request, called a trace, contains a rich data set about the request’s handling across all tiers of the application stack, including queries issued, exceptions raised, backtraces at relevant code execution points, and so on.

This instrumentation has the potential to incur application overhead under load, and consequently AppOptics employs adaptive sampling as a means to ensure good monitoring data in balance with application performance.

In a low-traffic environment like development or staging, typically every request will be traced. However, in high-traffic production environments, it is possible to see sample rates of <1%.

How do I know if a request has been sampled for tracing?

The easiest way to tell if a request has been sampled for tracing is to look at the returned X-Trace header:

$ curl -I
HTTP/1.1 302 Found
Date: Tue, 13 Feb 2018 00:16:21 GMT
Content-Type: text/html; charset=utf-8
Connection: keep-alive
X-Trace: 2BC6ADF7BF847C7BD3486A271E464912DBB8E50D4D1BDC926811F4BF1E01

AppOptics X-Trace IDs will always begin with “2B” and end in either “00” or “01”. A return value of “01” indicates that the request has been traced, and will be available in the AppOptics UI in the next few seconds.

How can I control the sample rate for particular requests?

There are tunables available to help you get the right coverage; however, they should be used carefully to preserve performance characteristics of the application. Contact for more information.