tracing: Make collection of opentelemetry traces optional (#24792)

This commit marks the `grpc_service` of the opentelemtry configuration as optional and if the resulting field is empty, the plugin will abstain from sending the trace data to any collection service.

This means that the opentelemetry plugin will still generate and propagate trace headers, but they will no longer be sent to the collector.

Signed-off-by: Ashish Banerjee <ashish.banerjee@solo.io>

Mirrored from https://github.com/envoyproxy/envoy @ c424ab9b0165357b715866ee2906cf3fc717e4e8
pull/626/head
data-plane-api(Azure Pipelines) 2 years ago
parent 93b8f9b0c7
commit e68d2fe628
  1. 4
      envoy/config/trace/v3/opentelemetry.proto
  2. 2
      envoy/extensions/load_balancing_policies/client_side_weighted_round_robin/v3/client_side_weighted_round_robin.proto

@ -5,7 +5,6 @@ package envoy.config.trace.v3;
import "envoy/config/core/v3/grpc_service.proto";
import "udpa/annotations/status.proto";
import "validate/validate.proto";
option java_package = "io.envoyproxy.envoy.config.trace.v3";
option java_outer_classname = "OpentelemetryProto";
@ -20,7 +19,8 @@ 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.
core.v3.GrpcService grpc_service = 1 [(validate.rules).message = {required: true}];
// This field can be left empty to disable reporting traces to the collector.
core.v3.GrpcService grpc_service = 1;
// 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".

@ -54,6 +54,6 @@ message ClientSideWeightedRoundRobin {
// blackout_period applies. Defaults to 3 minutes.
google.protobuf.Duration weight_expiration_period = 4;
// How often endpoint weights are recalculated. Default is 1 second.
// How often endpoint weights are recalculated. Default is 1 second.
google.protobuf.Duration weight_update_period = 5;
}

Loading…
Cancel
Save