Skip to content

Commit b1e2d78

Browse files
committed
Internal telemetry config options for OTLP export
Signed-off-by: Swapnil Kulkarni <[email protected]>
1 parent bd801c6 commit b1e2d78

File tree

1 file changed

+63
-0
lines changed

1 file changed

+63
-0
lines changed

content/en/docs/collector/internal-telemetry.md

+63
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,69 @@ Note that the `tracer_provider` section there corresponds to `traces` here.
168168
[kitchen-sink-config]:
169169
https://github.com/open-telemetry/opentelemetry-configuration/blob/main/examples/kitchen-sink.yaml
170170

171+
### Self-monitoring
172+
173+
The Collector can be configured to push its own telemetry to an
174+
[OTLP receiver](https://github.com/open-telemetry/opentelemetry-collector/tree/main/receiver/otlpreceiver)
175+
and send the data through configured pipelines. In the following example, the
176+
Collector is configured to push metrics, traces, and logs every 10s using OTLP
177+
gRPC to `localhost:14317`:
178+
179+
```yaml
180+
receivers:
181+
otlp/internal:
182+
protocols:
183+
grpc:
184+
endpoint: localhost:14317
185+
exporters:
186+
debug:
187+
service:
188+
pipelines:
189+
metrics:
190+
receivers: [otlp/internal]
191+
exporters: [debug]
192+
traces:
193+
receivers: [otlp/internal]
194+
exporters: [debug]
195+
telemetry:
196+
metrics:
197+
readers:
198+
- periodic:
199+
interval: 10000
200+
exporter:
201+
otlp:
202+
protocol: grpc/protobuf
203+
endpoint: http://localhost:14317
204+
traces:
205+
processors:
206+
- batch:
207+
exporter:
208+
otlp:
209+
protocol: grpc/protobuf
210+
endpoint: http://localhost:14317
211+
logs:
212+
processors:
213+
- batch:
214+
exporter:
215+
otlp:
216+
protocol: grpc/protobuf
217+
endpoint: http://localhost:14317
218+
```
219+
220+
{{% alert title="Caution" color="warning" %}}
221+
222+
When self-monitoring, the Collector collects its own telemetry and sends it to
223+
the desired backend for analysis. This can be a risky practice. If the Collector
224+
is underperforming, its self-monitoring capability could be impacted. As a
225+
result, the self-monitored telemetry might not reach the backend in time for
226+
critical analysis.
227+
228+
Moreover, sending internal telemetry through the Collector's own pipelines can
229+
create a continuous loop of spans, metric points, or logs, putting undue strain
230+
on the Collector's performance. This setup should not be used in production.
231+
232+
{{% /alert %}}
233+
171234
## Types of internal telemetry
172235

173236
The OpenTelemetry Collector aims to be a model of observable service by clearly

0 commit comments

Comments
 (0)