Can I use Stackdriver Trace on infrastructure not hosted on Google Cloud Platform?
Several projects already do this today! Stackdriver Trace will analyze all data submitted through its API, regardless of where the instrumented service is hosted, including traces and spans collected from the Stackdriver Trace instrumentation libraries or through the Stackdriver Trace Zipkin Connector.
How long does Stackdriver Trace retain trace data?
Traces are stored for 30 days.
Does Google Stackdriver Trace sample every request?
Google Stackdriver Trace samples requests at a rate of 0.1 requests per second for each App Engine instance. The Stackdriver Trace SDKs can be configured to sample at custom rates.
How do I force a request to be traced?
To force a specific request to be traced, add an
header to the request. The header specification is:
TRACE_IDis a 32-character hex value representing a 128-bit number. It should be unique between your requests, unless you intentionally want to bundle the requests together. You can use UUIDs.
0for the first span in your trace. For subsequent requests, set
SPAN_IDto the span ID of the parent request. See the description of
TraceSpan(REST, RPC) for more information about nested traces.
1to trace this request. Specify
0to not trace the request.
For example, to force a trace with cURL:
curl "http://www.example.com" --header "X-Cloud-Trace-Context: 105445aa7843bc8bf206b120001000/0;o=1"