diff --git a/envoy/config/core/v3/http_service.proto b/envoy/config/core/v3/http_service.proto new file mode 100644 index 00000000..426994c0 --- /dev/null +++ b/envoy/config/core/v3/http_service.proto @@ -0,0 +1,35 @@ +syntax = "proto3"; + +package envoy.config.core.v3; + +import "envoy/config/core/v3/base.proto"; +import "envoy/config/core/v3/http_uri.proto"; + +import "udpa/annotations/status.proto"; +import "validate/validate.proto"; + +option java_package = "io.envoyproxy.envoy.config.core.v3"; +option java_outer_classname = "HttpServiceProto"; +option java_multiple_files = true; +option go_package = "github.com/envoyproxy/go-control-plane/envoy/config/core/v3;corev3"; +option (udpa.annotations.file_status).package_version_status = ACTIVE; + +// [#protodoc-title: HTTP services] + +// HTTP service configuration. +message HttpService { + // The service's HTTP URI. For example: + // + // .. code-block:: yaml + // + // http_uri: + // uri: https://www.myserviceapi.com/v1/data + // cluster: www.myserviceapi.com|443 + // + HttpUri http_uri = 1; + + // Specifies a list of HTTP headers that should be added to each request + // handled by this virtual host. + repeated HeaderValueOption request_headers_to_add = 2 + [(validate.rules).repeated = {max_items: 1000}]; +} diff --git a/envoy/config/trace/v3/opentelemetry.proto b/envoy/config/trace/v3/opentelemetry.proto index e9c7430d..7ae6a964 100644 --- a/envoy/config/trace/v3/opentelemetry.proto +++ b/envoy/config/trace/v3/opentelemetry.proto @@ -3,7 +3,9 @@ syntax = "proto3"; package envoy.config.trace.v3; import "envoy/config/core/v3/grpc_service.proto"; +import "envoy/config/core/v3/http_service.proto"; +import "udpa/annotations/migrate.proto"; import "udpa/annotations/status.proto"; option java_package = "io.envoyproxy.envoy.config.trace.v3"; @@ -19,8 +21,24 @@ option (udpa.annotations.file_status).package_version_status = ACTIVE; message OpenTelemetryConfig { // The upstream gRPC cluster that will receive OTLP traces. // Note that the tracer drops traces if the server does not read data fast enough. - // This field can be left empty to disable reporting traces to the collector. - core.v3.GrpcService grpc_service = 1; + // This field can be left empty to disable reporting traces to the gRPC service. + // Only one of ``grpc_service``, ``http_service`` may be used. + core.v3.GrpcService grpc_service = 1 + [(udpa.annotations.field_migrate).oneof_promotion = "otlp_exporter"]; + + // The upstream HTTP cluster that will receive OTLP traces. + // This field can be left empty to disable reporting traces to the HTTP service. + // Only one of ``grpc_service``, ``http_service`` may be used. + // + // .. note:: + // + // Note: The ``request_headers_to_add`` property in the OTLP HTTP exporter service + // does not support the :ref:`format specifier ` as used for + // :ref:`HTTP access logging `. + // The values configured are added as HTTP headers on the OTLP export request + // without any formatting applied. + core.v3.HttpService http_service = 3 + [(udpa.annotations.field_migrate).oneof_promotion = "otlp_exporter"]; // The name for the service. This will be populated in the ResourceSpan Resource attributes. // If it is not provided, it will default to "unknown_service:envoy".