Tracing
5/14/25Less than 1 minutecomponenttraceropentelemetryjaeger
Tracing Usage Example
Tracing is a component encapsulated based on go.opentelemetry.io/otel. Click to view the Tracing Usage Example.
Click to view Example of using tracing in single and multi-service created by sponge.
Tracing Configuration
In services created by sponge, the tracing component is disabled by default.
Set the fields enableTrace
and jaeger
in the yaml configuration file under the configs
directory:
app:
enableTrace: false # Whether tracing is enabled, true: enable, false: disable. If true, jaeger configuration must be set.
tracingSamplingRate: 1.0 # Tracing sampling rate, range 0~1.0 float. 0 means no sampling, 1.0 means sampling all links.
jaeger:
agentHost: "127.0.0.1"
agentPort: 6831