Class OpenTelemetryAccessLogConfig

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

    public final class OpenTelemetryAccessLogConfig
    extends com.google.protobuf.GeneratedMessageV3
    implements OpenTelemetryAccessLogConfigOrBuilder
     Configuration for the built-in ``envoy.access_loggers.open_telemetry``
     :ref:`AccessLog <envoy_v3_api_msg_config.accesslog.v3.AccessLog>`. This configuration will
     populate `opentelemetry.proto.collector.v1.logs.ExportLogsServiceRequest.resource_logs <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/collector/logs/v1/logs_service.proto>`_.
     In addition, the request start time is set in the dedicated field.
     [#extension: envoy.access_loggers.open_telemetry]
     
    Protobuf type envoy.extensions.access_loggers.open_telemetry.v3.OpenTelemetryAccessLogConfig
    See Also:
    Serialized Form
    • Field Detail

      • COMMON_CONFIG_FIELD_NUMBER

        public static final int COMMON_CONFIG_FIELD_NUMBER
        See Also:
        Constant Field Values
      • RESOURCE_ATTRIBUTES_FIELD_NUMBER

        public static final int RESOURCE_ATTRIBUTES_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ATTRIBUTES_FIELD_NUMBER

        public static final int ATTRIBUTES_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
      • hasCommonConfig

        public boolean hasCommonConfig()
         [#comment:TODO(itamarkam): add 'filter_state_objects_to_log' to logs.]
         
        .envoy.extensions.access_loggers.grpc.v3.CommonGrpcAccessLogConfig common_config = 1 [(.validate.rules) = { ... }
        Specified by:
        hasCommonConfig in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        Whether the commonConfig field is set.
      • hasResourceAttributes

        public boolean hasResourceAttributes()
         OpenTelemetry `Resource <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/logs/v1/logs.proto#L51>`_
         attributes are filled with Envoy node info.
         Example: ``resource_attributes { values { key: "region" value { string_value: "cn-north-7" } } }``.
         
        .opentelemetry.proto.common.v1.KeyValueList resource_attributes = 4;
        Specified by:
        hasResourceAttributes in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        Whether the resourceAttributes field is set.
      • getResourceAttributes

        public KeyValueList getResourceAttributes()
         OpenTelemetry `Resource <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/logs/v1/logs.proto#L51>`_
         attributes are filled with Envoy node info.
         Example: ``resource_attributes { values { key: "region" value { string_value: "cn-north-7" } } }``.
         
        .opentelemetry.proto.common.v1.KeyValueList resource_attributes = 4;
        Specified by:
        getResourceAttributes in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        The resourceAttributes.
      • getResourceAttributesOrBuilder

        public KeyValueListOrBuilder getResourceAttributesOrBuilder()
         OpenTelemetry `Resource <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/logs/v1/logs.proto#L51>`_
         attributes are filled with Envoy node info.
         Example: ``resource_attributes { values { key: "region" value { string_value: "cn-north-7" } } }``.
         
        .opentelemetry.proto.common.v1.KeyValueList resource_attributes = 4;
        Specified by:
        getResourceAttributesOrBuilder in interface OpenTelemetryAccessLogConfigOrBuilder
      • hasBody

        public boolean hasBody()
         OpenTelemetry `LogResource <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/logs/v1/logs.proto>`_
         fields, following `Envoy access logging formatting <https://www.envoyproxy.io/docs/envoy/latest/configuration/observability/access_log/usage>`_.
         See 'body' in the LogResource proto for more details.
         Example: ``body { string_value: "%PROTOCOL%" }``.
         
        .opentelemetry.proto.common.v1.AnyValue body = 2;
        Specified by:
        hasBody in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        Whether the body field is set.
      • getBody

        public AnyValue getBody()
         OpenTelemetry `LogResource <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/logs/v1/logs.proto>`_
         fields, following `Envoy access logging formatting <https://www.envoyproxy.io/docs/envoy/latest/configuration/observability/access_log/usage>`_.
         See 'body' in the LogResource proto for more details.
         Example: ``body { string_value: "%PROTOCOL%" }``.
         
        .opentelemetry.proto.common.v1.AnyValue body = 2;
        Specified by:
        getBody in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        The body.
      • getBodyOrBuilder

        public AnyValueOrBuilder getBodyOrBuilder()
         OpenTelemetry `LogResource <https://github.com/open-telemetry/opentelemetry-proto/blob/main/opentelemetry/proto/logs/v1/logs.proto>`_
         fields, following `Envoy access logging formatting <https://www.envoyproxy.io/docs/envoy/latest/configuration/observability/access_log/usage>`_.
         See 'body' in the LogResource proto for more details.
         Example: ``body { string_value: "%PROTOCOL%" }``.
         
        .opentelemetry.proto.common.v1.AnyValue body = 2;
        Specified by:
        getBodyOrBuilder in interface OpenTelemetryAccessLogConfigOrBuilder
      • hasAttributes

        public boolean hasAttributes()
         See 'attributes' in the LogResource proto for more details.
         Example: ``attributes { values { key: "user_agent" value { string_value: "%REQ(USER-AGENT)%" } } }``.
         
        .opentelemetry.proto.common.v1.KeyValueList attributes = 3;
        Specified by:
        hasAttributes in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        Whether the attributes field is set.
      • getAttributes

        public KeyValueList getAttributes()
         See 'attributes' in the LogResource proto for more details.
         Example: ``attributes { values { key: "user_agent" value { string_value: "%REQ(USER-AGENT)%" } } }``.
         
        .opentelemetry.proto.common.v1.KeyValueList attributes = 3;
        Specified by:
        getAttributes in interface OpenTelemetryAccessLogConfigOrBuilder
        Returns:
        The attributes.
      • 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 OpenTelemetryAccessLogConfig parseFrom​(ByteBuffer data)
                                                      throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

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

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

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

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

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

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

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

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

        public com.google.protobuf.Parser<OpenTelemetryAccessLogConfig> 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 OpenTelemetryAccessLogConfig getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder