Class UuidRequestIdConfig

  • All Implemented Interfaces:
    com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, UuidRequestIdConfigOrBuilder, Serializable

    public final class UuidRequestIdConfig
    extends com.google.protobuf.GeneratedMessageV3
    implements UuidRequestIdConfigOrBuilder
     Configuration for the default UUID request ID extension which has the following behavior:
     1. Request ID is propagated using the :ref:`x-request-id
        <config_http_conn_man_headers_x-request-id>` header.
     2. Request ID is a universally unique identifier `(UUID4)
        <https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_4_(random)>`_.
     3. Tracing decision (sampled, forced, etc) is set in 14th nibble of the UUID. By default this will
        overwrite existing UUIDs received in the ``x-request-id`` header if the trace sampling decision
        is changed. The 14th nibble of the UUID4 has been chosen because it is fixed to '4' by the
        standard. Thus, '4' indicates a default UUID and no trace status. This nibble is swapped to:
          a. '9': Sampled.
          b. 'a': Force traced due to server-side override.
          c. 'b': Force traced due to client-side request ID joining.
        See the :ref:`x-request-id <config_http_conn_man_headers_x-request-id>` documentation for
        more information.
     
    Protobuf type envoy.extensions.request_id.uuid.v3.UuidRequestIdConfig
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  UuidRequestIdConfig.Builder
      Configuration for the default UUID request ID extension which has the following behavior: 1.
      • Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3

        com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,​BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,​BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
      • Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite

        com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int PACK_TRACE_REASON_FIELD_NUMBER  
      static int USE_REQUEST_ID_FOR_TRACE_SAMPLING_FIELD_NUMBER  
      • Fields inherited from class com.google.protobuf.GeneratedMessageV3

        alwaysUseFieldBuilders, unknownFields
      • Fields inherited from class com.google.protobuf.AbstractMessage

        memoizedSize
      • Fields inherited from class com.google.protobuf.AbstractMessageLite

        memoizedHashCode
    • Field Detail

      • PACK_TRACE_REASON_FIELD_NUMBER

        public static final int PACK_TRACE_REASON_FIELD_NUMBER
        See Also:
        Constant Field Values
      • USE_REQUEST_ID_FOR_TRACE_SAMPLING_FIELD_NUMBER

        public static final int USE_REQUEST_ID_FOR_TRACE_SAMPLING_FIELD_NUMBER
        See Also:
        Constant Field Values
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getUnknownFields

        public final com.google.protobuf.UnknownFieldSet getUnknownFields()
        Specified by:
        getUnknownFields in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getUnknownFields in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • hasPackTraceReason

        public boolean hasPackTraceReason()
         Whether the implementation alters the UUID to contain the trace sampling decision as per the
         ``UuidRequestIdConfig`` message documentation. This defaults to true. If disabled no
         modification to the UUID will be performed. It is important to note that if disabled,
         stable sampling of traces, access logs, etc. will no longer work and only random sampling will
         be possible.
         
        .google.protobuf.BoolValue pack_trace_reason = 1;
        Specified by:
        hasPackTraceReason in interface UuidRequestIdConfigOrBuilder
        Returns:
        Whether the packTraceReason field is set.
      • getPackTraceReason

        public com.google.protobuf.BoolValue getPackTraceReason()
         Whether the implementation alters the UUID to contain the trace sampling decision as per the
         ``UuidRequestIdConfig`` message documentation. This defaults to true. If disabled no
         modification to the UUID will be performed. It is important to note that if disabled,
         stable sampling of traces, access logs, etc. will no longer work and only random sampling will
         be possible.
         
        .google.protobuf.BoolValue pack_trace_reason = 1;
        Specified by:
        getPackTraceReason in interface UuidRequestIdConfigOrBuilder
        Returns:
        The packTraceReason.
      • getPackTraceReasonOrBuilder

        public com.google.protobuf.BoolValueOrBuilder getPackTraceReasonOrBuilder()
         Whether the implementation alters the UUID to contain the trace sampling decision as per the
         ``UuidRequestIdConfig`` message documentation. This defaults to true. If disabled no
         modification to the UUID will be performed. It is important to note that if disabled,
         stable sampling of traces, access logs, etc. will no longer work and only random sampling will
         be possible.
         
        .google.protobuf.BoolValue pack_trace_reason = 1;
        Specified by:
        getPackTraceReasonOrBuilder in interface UuidRequestIdConfigOrBuilder
      • hasUseRequestIdForTraceSampling

        public boolean hasUseRequestIdForTraceSampling()
         Set whether to use :ref:`x-request-id<config_http_conn_man_headers_x-request-id>` for sampling or not.
         This defaults to true. See the :ref:`context propagation <arch_overview_tracing_context_propagation>`
         overview for more information.
         
        .google.protobuf.BoolValue use_request_id_for_trace_sampling = 2;
        Specified by:
        hasUseRequestIdForTraceSampling in interface UuidRequestIdConfigOrBuilder
        Returns:
        Whether the useRequestIdForTraceSampling field is set.
      • getUseRequestIdForTraceSampling

        public com.google.protobuf.BoolValue getUseRequestIdForTraceSampling()
         Set whether to use :ref:`x-request-id<config_http_conn_man_headers_x-request-id>` for sampling or not.
         This defaults to true. See the :ref:`context propagation <arch_overview_tracing_context_propagation>`
         overview for more information.
         
        .google.protobuf.BoolValue use_request_id_for_trace_sampling = 2;
        Specified by:
        getUseRequestIdForTraceSampling in interface UuidRequestIdConfigOrBuilder
        Returns:
        The useRequestIdForTraceSampling.
      • getUseRequestIdForTraceSamplingOrBuilder

        public com.google.protobuf.BoolValueOrBuilder getUseRequestIdForTraceSamplingOrBuilder()
         Set whether to use :ref:`x-request-id<config_http_conn_man_headers_x-request-id>` for sampling or not.
         This defaults to true. See the :ref:`context propagation <arch_overview_tracing_context_propagation>`
         overview for more information.
         
        .google.protobuf.BoolValue use_request_id_for_trace_sampling = 2;
        Specified by:
        getUseRequestIdForTraceSamplingOrBuilder in interface UuidRequestIdConfigOrBuilder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(ByteBuffer data)
                                             throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(ByteBuffer data,
                                                    com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                             throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(com.google.protobuf.ByteString data)
                                             throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(com.google.protobuf.ByteString data,
                                                    com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                             throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(byte[] data)
                                             throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(byte[] data,
                                                    com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                             throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static UuidRequestIdConfig parseFrom​(com.google.protobuf.CodedInputStream input,
                                                    com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                             throws IOException
        Throws:
        IOException
      • newBuilderForType

        public UuidRequestIdConfig.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public UuidRequestIdConfig.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected UuidRequestIdConfig.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getParserForType

        public com.google.protobuf.Parser<UuidRequestIdConfig> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public UuidRequestIdConfig getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder