-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Closed
Labels
Accepted ComponentNew component has been sponsoredNew component has been sponsored
Description
The purpose and use-cases of the new component
The purpose of this processor component is to extract logs from recorded exceptions from spans
This will generate a log line with the following format:
{
"severity": "ERROR",
"attributes": {
"exception.message": "division by zero",
"exception.stacktrace": "Traceback (most recent call last):\n File \"/usr/local/lib/python3.10/site-packages/opentelemetry/trace/__init__.py\", line 541, in use_span\n yield span\n File \"/usr/local/lib/python3.10/site-packages/django/core/handlers/exception.py\", line 55, in inner\n response = get_response(request)\n File \"/usr/local/lib/python3.10/site-packages/django/core/handlers/base.py\", line 197, in _get_response\n response = wrapped_callback(request, *callback_args, **callback_kwargs)\n File \"/code/./example/views.py\", line 24, in index\n random.choice([f0, f1, f2, f3])()\n File \"/code/./example/views.py\", line 7, in f0\n a = 1/0\nZeroDivisionError: division by zero\n",
"exception.type": "ZeroDivisionError",
"http.flavor": "1.1",
"http.host": "127.0.0.1:8000",
"http.method": "GET",
"http.scheme": "http",
"http.server_name": "644f31ce42a5",
"http.status_code": "",
"http.target": "/",
"http.user_agent": "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:107.0) Gecko/20100101 Firefox/107.0",
"service.name": "faulty"
}
}
Example configuration for the component
receivers:
jaeger:
protocols:
thrift_http:
endpoint: "0.0.0.0:14278"
# Dummy receiver that's never used, because a pipeline is required to have one.
otlp/exceptionlogs:
protocols:
grpc:
endpoint: "localhost:12345"
otlp:
protocols:
grpc:
endpoint: "localhost:55677"
processors:
batch:
exceptionlogs:
logs_exporter: loki
exporters:
jaeger:
endpoint: localhost:14250
loki:
endpoint: "http://loki:3100/loki/api/v1/push"
service:
pipelines:
traces:
receivers: [jaeger]
processors: [exceptionlogs, batch]
exporters: [jaeger]
logs:
receivers: [otlp/exceptionlogs]
exporters: [loki]
Telemetry data types supported
traces
Is this a vendor-specific component?
- This is a vendor-specific component
- If this is a vendor-specific component, I am proposing to contribute this as a representative of the vendor.
Sponsor (optional)
Additional context
No response
Metadata
Metadata
Assignees
Labels
Accepted ComponentNew component has been sponsoredNew component has been sponsored