envoyproxy/envoy

Structured application logging for xDS internals

Open

#40,089 opened on 2025年7月1日

GitHub で見る
 (2 comments) (0 reactions) (0 assignees)C++ (5,373 forks)batch import
area/xdsenhancementhelp wanted

Repository metrics

Stars
 (27,997 stars)
PR merge metrics
 (平均マージ 8d) (30d で 378 merged PRs)

説明

Emit application logs from Envoy to indicate when the xDS is effective. As was discussed early (#39891 ,https://github.com/envoyproxy/envoy/issues/35675, https://github.com/envoyproxy/envoy/issues/11396#issuecomment-3025014264), there is currently no reliable way to signal when Envoy effectively applied a given configuration without probing Envoy directly. To solve this, we propose to expose the internal workings of Envoy's xDS clients via OTLP event logging semantics. Concretely, we'd emit the following structured events via a configurable OTLP/stream endpoint (see log data model):

event_name: envoy.xds.applied
attributes:
  xds.type: listener | cluster
  xds.name: $(listener_name) | $(cluster_name) | ...
body: "Resource has been applied to all workers"

Note that we would emit xDS attributes as shared attributes rather than body per OTel semantic guidelines.

The work amounts to:

  • instrumenting the listener manager and the cluster manager with calls to log once the configuration is loaded onto all workers.
  • defining a new extension point for application event logs.
  • add log sinks to bootstrap and register common sinks such as Otel and stdout for dual use as an event log sink and an access log sink.

コントリビューターガイド