You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .chloggen/operator-resource-attributes.yaml
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -10,3 +10,4 @@ subtext: |
10
10
If you are using the file log receiver, you can now create the same resource attributes as traces (via OTLP) received
11
11
from an application instrumented with the OpenTelemetry Operator -
12
12
simply by adding the `extract: { operator_rules: { enabled: true } }` configuration to the `k8sattributesprocessor` processor.
13
+
See the [documentation](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/processor/k8sattributesprocessor/README.md#config-example) for more details.
Copy file name to clipboardExpand all lines: processor/k8sattributesprocessor/README.md
+13-4Lines changed: 13 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -272,10 +272,19 @@ k8sattributes/2:
272
272
- k8s.node.name
273
273
- k8s.pod.start_time
274
274
labels:
275
-
# This label extraction rule takes the value 'app.kubernetes.io/component' label and maps it to the 'app.label.component' attribute which will be added to the associated resources
276
-
- tag_name: app.label.component
277
-
key: app.kubernetes.io/component
278
-
from: pod
275
+
# This label extraction rule takes the value 'app.kubernetes.io/component' label and maps it to the 'app.label.component' attribute which will be added to the associated resources
276
+
- tag_name: app.label.component
277
+
key: app.kubernetes.io/component
278
+
from: pod
279
+
operator_rules:
280
+
# Apply the operator rules - see https://github.com/open-telemetry/opentelemetry-operator#configure-resource-attributes
281
+
enabled: true
282
+
# Also translate the following labels to the specified resource attributes:
283
+
# app.kubernetes.io/name => service.name
284
+
# app.kubernetes.io/version => service.version
285
+
# app.kubernetes.io/part-of => service.namespace
286
+
# This setting is ignored if 'enabled' is set to false
287
+
labels: true
279
288
pod_association:
280
289
- sources:
281
290
# This rule associates all resources containing the 'k8s.pod.ip' attribute with the matching pods. If this attribute is not present in the resource, this rule will not be able to find the matching pod.
0 commit comments