This advanced guide covers how to integrate Gentrace with complex OpenTelemetry setups.
Instrument your application
Export spans to Gentrace
View your traces in Gentrace
JSON.stringify()
and handle circular referencesjson.dumps()
gentrace.sample=true
to relevant spans, and then filter in your exporter on the basis of gentrace.sample
.
gentrace.sample
from the baggage to the span.
For convenience, we provide a span processor that does this for you:
http://collector.example.com:4318
), which will then forward filtered spans to Gentrace’s OTLP endpoint at /api/otel/v1/traces
gentrace.sample=true
.
For simplicity, we supply the GentraceSampler
, which is an in-process sampler that filters spans based on OpenTelemetry baggage.
gentrace.sample=true
attribute (set by SDK helpers or manually)GENTRACE_API_KEY
is correctly set in the collector