Class SpanContext
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<SpanContext.Builder,SpanContext>
The contextual information that uniquely identifies a span within the distributed tracing system. Contains session, trace, and span identifiers used to correlate evaluation results with specific agent execution points.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic SpanContext.Builderbuilder()final booleanfinal booleanequalsBySdkFields(Object obj) final <T> Optional<T>getValueForField(String fieldName, Class<T> clazz) final inthashCode()static Class<? extends SpanContext.Builder>final StringThe unique identifier of the session containing this span.final StringspanId()The unique identifier of the specific span being referenced.final StringtoString()Returns a string representation of this object.final StringtraceId()The unique identifier of the trace containing this span.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
Method Details
-
sessionId
The unique identifier of the session containing this span. Sessions represent complete conversation flows and are detected using configurable
SessionTimeoutMinutes(default 15 minutes).- Returns:
- The unique identifier of the session containing this span. Sessions represent complete conversation flows
and are detected using configurable
SessionTimeoutMinutes(default 15 minutes).
-
traceId
The unique identifier of the trace containing this span. Traces represent individual request-response interactions within a session and group related spans together.
- Returns:
- The unique identifier of the trace containing this span. Traces represent individual request-response interactions within a session and group related spans together.
-
spanId
The unique identifier of the specific span being referenced. Spans represent individual operations like tool calls, model invocations, or other discrete actions within the agent's execution.
- Returns:
- The unique identifier of the specific span being referenced. Spans represent individual operations like tool calls, model invocations, or other discrete actions within the agent's execution.
-
toBuilder
- Specified by:
toBuilderin interfaceToCopyableBuilder<SpanContext.Builder,SpanContext>
-
builder
-
serializableBuilderClass
-
hashCode
public final int hashCode() -
equals
-
equalsBySdkFields
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value. -
getValueForField
-
sdkFields
-
sdkFieldNameToField
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo
-