Class TraceContextFormat

    • Field Detail

      • TRACESTATE_DEFAULT

        private static final Tracestate TRACESTATE_DEFAULT
      • FIELDS

        private static final java.util.List<java.lang.String> FIELDS
      • TRACEPARENT_DELIMITER_SIZE

        private static final int TRACEPARENT_DELIMITER_SIZE
        See Also:
        Constant Field Values
      • TRACEPARENT_HEADER_SIZE

        private static final int TRACEPARENT_HEADER_SIZE
        See Also:
        Constant Field Values
      • TRACESTATE_MAX_MEMBERS

        private static final int TRACESTATE_MAX_MEMBERS
        See Also:
        Constant Field Values
      • TRACESTATE_KEY_VALUE_DELIMITER

        private static final char TRACESTATE_KEY_VALUE_DELIMITER
        See Also:
        Constant Field Values
      • TRACESTATE_ENTRY_DELIMITER

        private static final char TRACESTATE_ENTRY_DELIMITER
        See Also:
        Constant Field Values
      • TRACESTATE_ENTRY_DELIMITER_SPLITTER

        private static final com.google.common.base.Splitter TRACESTATE_ENTRY_DELIMITER_SPLITTER
    • Constructor Detail

      • TraceContextFormat

        public TraceContextFormat()
    • Method Detail

      • fields

        public java.util.List<java.lang.String> fields()
        Description copied from class: TextFormat
        The propagation fields defined. If your carrier is reused, you should delete the fields here before calling TextFormat.inject(SpanContext, Object, Setter).

        For example, if the carrier is a single-use or immutable request object, you don't need to clear fields as they couldn't have been set before. If it is a mutable, retryable object, successive calls should clear these fields first.

        Specified by:
        fields in class TextFormat
      • inject

        public <C> void inject​(SpanContext spanContext,
                               C carrier,
                               TextFormat.Setter<C> setter)
        Description copied from class: TextFormat
        Injects the span context downstream. For example, as http headers.
        Specified by:
        inject in class TextFormat
        Parameters:
        spanContext - possibly not sampled.
        carrier - holds propagation fields. For example, an outgoing message or http request.
        setter - invoked for each propagation key to add or remove.