Class AwsXrayIdGenerator
- java.lang.Object
-
- io.opentelemetry.sdk.extension.aws.trace.AwsXrayIdGenerator
-
- All Implemented Interfaces:
io.opentelemetry.sdk.trace.IdGenerator
public final class AwsXrayIdGenerator extends Object implements io.opentelemetry.sdk.trace.IdGenerator
Generates tracing ids compatible with the AWS X-Ray tracing service. In the X-Ray system the first 32 bits of the trace id are the Unix epoch time in secords. Spans (AWS calls them segments) submit with trace id timestamps outside of the last 30 days are rejected.- See Also:
- Generating Trace IDs
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgenerateSpanId()StringgenerateTraceId()static AwsXrayIdGeneratorgetInstance()Returns a singleton instance ofAwsXrayIdGenerator.
-
-
-
Method Detail
-
getInstance
public static AwsXrayIdGenerator getInstance()
Returns a singleton instance ofAwsXrayIdGenerator.
-
generateSpanId
public String generateSpanId()
- Specified by:
generateSpanIdin interfaceio.opentelemetry.sdk.trace.IdGenerator
-
generateTraceId
public String generateTraceId()
- Specified by:
generateTraceIdin interfaceio.opentelemetry.sdk.trace.IdGenerator
-
-