Enum Class Telemetry.Protocol

java.lang.Object
java.lang.Enum<Telemetry.Protocol>
org.microproxy.otel.Telemetry.Protocol
All Implemented Interfaces:
Serializable, Comparable<Telemetry.Protocol>, Constable
Enclosing class:
Telemetry

public static enum Telemetry.Protocol extends Enum<Telemetry.Protocol>
How OTLP is sent: http/protobuf or http/json.
  • Enum Constant Details

    • HTTP_PROTOBUF

      public static final Telemetry.Protocol HTTP_PROTOBUF
      OTLP/HTTP with application/x-protobuf bodies.
    • HTTP_JSON

      public static final Telemetry.Protocol HTTP_JSON
      OTLP/HTTP with application/json bodies, ids in hex.
  • Method Details

    • values

      public static Telemetry.Protocol[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Telemetry.Protocol valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • id

      public String id()
      Returns the name OTEL_EXPORTER_OTLP_PROTOCOL uses.
      Returns:
      the name OTEL_EXPORTER_OTLP_PROTOCOL uses
    • contentType

      public String contentType()
      Returns the content type of the requests.
      Returns:
      the content type of the requests
    • of

      public static Telemetry.Protocol of(String name)
      The protocol named name.
      Parameters:
      name - http/protobuf or http/json
      Returns:
      the protocol
      Throws:
      IllegalArgumentException - for another name (grpc is not supported)