Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expanding k8s.pod resource to include pod labels #494

Merged
merged 21 commits into from
Nov 27, 2023
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ release.

### Features

- Adds `labels` attribute to `k8s.pod` resource
([#494](https://github.com/open-telemetry/semantic-conventions/pull/494))
- Add `code.stacktrace` attribute
([#435](https://github.com/open-telemetry/semantic-conventions/pull/435))
- Add `http.flavor` and `http.user_agent` to list of deprecated attributes
Expand Down
1 change: 1 addition & 0 deletions docs/resource/k8s.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ containers on your cluster.
<!-- semconv k8s.pod -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `k8s.pod.labels.<key>` | string | The labels placed on the Pod, the `<key>` being the label name, the value being the label value. | `k8s.pod.labels.app=my-app,k8s.pod.labels.mycompany.io/arch=x64,k8s.pod.labels.data=` | Recommended |
| [`k8s.pod.name`](../attributes-registry/k8s.md) | string | The name of the Pod. | `opentelemetry-pod-autoconf` | Recommended |
| [`k8s.pod.uid`](../attributes-registry/k8s.md) | string | The UID of the Pod. | `275ecb36-5aa8-4c2a-9c47-d8bb681b9aff` | Recommended |
<!-- endsemconv -->
Expand Down
5 changes: 5 additions & 0 deletions model/resource/k8s.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ groups:
attributes:
- ref: k8s.pod.uid
- ref: k8s.pod.name
- id: labels
type: template[string]
brief: >
The labels placed on the Pod, the `<key>` being the label name, the value being the label value.
examples: ['k8s.pod.labels.app=my-app,k8s.pod.labels.mycompany.io/arch=x64,k8s.pod.labels.data=']
AlexanderWert marked this conversation as resolved.
Show resolved Hide resolved

- id: k8s.container
prefix: k8s.container
Expand Down
Loading