Skip to content

Commit 25623ab

Browse files
authored
[k8sattributes] rename internal telemetry (open-telemetry#45940)
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description This PR applies the renaming of the internal telemetry metrics in order to use dots instead of underscores in alignment with open-telemetry/opentelemetry-collector#12909 and OTel SemConv. This will happen through a feature gate pair: - `processor.k8sattributes.telemetry.disableOldFormatMetrics` - `processor.k8sattributes.telemetry.enableNewFormatMetrics` My suggestion will be to keep these gates in alpha for 3 releases, then promote them to beta for another 3 before making them stable. The renames are the following: ``` otelsvc_k8s_daemonset_added -> otelcol.k8s.watcher.daemonset.added otelsvc_k8s_daemonset_deleted -> otelcol.k8s.watcher.daemonset.deleted otelsvc_k8s_daemonset_updated -> otelcol.k8s.watcher.daemonset.updated otelsvc_k8s_deployment_added -> otelcol.k8s.watcher.deployment.added otelsvc_k8s_deployment_deleted -> otelcol.k8s.watcher.deployment.deleted otelsvc_k8s_deployment_updated -> otelcol.k8s.watcher.deployment.updated otelsvc_k8s_job_added -> otelcol.k8s.watcher.job.added otelsvc_k8s_job_deleted -> otelcol.k8s.watcher.job.deleted otelsvc_k8s_job_updated -> otelcol.k8s.watcher.job.updated otelsvc_k8s_namespace_added -> otelcol.k8s.watcher.namespace.added otelsvc_k8s_namespace_deleted -> otelcol.k8s.watcher.namespace.deleted otelsvc_k8s_namespace_updated -> otelcol.k8s.watcher.namespace.updated otelsvc_k8s_node_added -> otelcol.k8s.watcher.node.added otelsvc_k8s_node_deleted -> otelcol.k8s.watcher.node.deleted otelsvc_k8s_node_updated -> otelcol.k8s.watcher.node.updated otelsvc_k8s_pod_added -> otelcol.k8s.watcher.pod.added otelsvc_k8s_pod_deleted -> otelcol.k8s.watcher.pod.deleted otelsvc_k8s_pod_updated -> otelcol.k8s.watcher.pod.updated otelsvc_k8s_pod_table_size -> otelcol.k8s.watcher.pod_cache.size otelsvc_k8s_replicaset_added -> otelcol.k8s.watcher.replicaset.added otelsvc_k8s_replicaset_deleted -> otelcol.k8s.watcher.replicaset.deleted otelsvc_k8s_replicaset_updated -> otelcol.k8s.watcher.replicaset.updated otelsvc_k8s_statefulset_added -> otelcol.k8s.watcher.statefulset.added otelsvc_k8s_statefulset_deleted -> otelcol.k8s.watcher.statefulset.deleted otelsvc_k8s_statefulset_updated -> otelcol.k8s.watcher.statefulset.updated ``` `otelcol_otelsvc_k8s_ip_lookup_miss` -> [DEPRECATED] Number of times pod by IP lookup failed > **Deprecated since 0.146.0** > Use otelcol.k8s.pod.association instead <!-- Issue number (e.g. open-telemetry#1234) or full URL to issue, if applicable. --> #### Link to tracking issue Fixes open-telemetry#45871 <!--Describe what testing was performed and which tests were added.--> #### Testing ~ <!--Describe the documentation added.--> #### Documentation Updated <!--Please delete paragraphs that you did not use before submitting.--> Signed-off-by: ChrsMark <chrismarkou92@gmail.com>
1 parent 22166e6 commit 25623ab

9 files changed

Lines changed: 1304 additions & 47 deletions

File tree

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Use this changelog template to create an entry for release notes.
2+
3+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
4+
change_type: deprecation
5+
6+
# The name of the component, or a single word describing the area of concern, (e.g. receiver/filelog)
7+
component: processor/k8s_attributes
8+
9+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
10+
note: Rename internal telemetry metrics to use dots instead of underscores
11+
12+
# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
13+
issues: [45871]
14+
15+
# (Optional) One or more lines of additional information to render under the primary note.
16+
# These lines will be padded with 2 spaces and then inserted directly into the document.
17+
# Use pipe (|) for multiline entries.
18+
subtext:
19+
20+
# If your change doesn't affect end users or the exported elements of any package,
21+
# you should instead start your pull request title with [chore] or use the "Skip Changelog" label.
22+
# Optional: The change log or logs in which this entry should be included.
23+
# e.g. '[user]' or '[user, api]'
24+
# Include 'user' if the change is relevant to end users.
25+
# Include 'api' if there is a change to a library API.
26+
# Default: '[user]'
27+
change_logs: [user]

processor/k8sattributesprocessor/documentation.md

Lines changed: 161 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,171 @@
4242

4343
The following telemetry is emitted by this component.
4444

45-
### otelcol_otelsvc_k8s_ip_lookup_miss
45+
### otelcol.k8s.watcher.job.added
4646

47-
Number of times pod by IP lookup failed.
47+
Number of job add events received
4848

4949
| Unit | Metric Type | Value Type | Monotonic | Stability |
5050
| ---- | ----------- | ---------- | --------- | --------- |
5151
| 1 | Sum | Int | true | Development |
5252

53+
### otelcol.k8s.watcher.job.deleted
54+
55+
Number of job delete events received
56+
57+
| Unit | Metric Type | Value Type | Monotonic | Stability |
58+
| ---- | ----------- | ---------- | --------- | --------- |
59+
| 1 | Sum | Int | true | Development |
60+
61+
### otelcol.k8s.watcher.job.updated
62+
63+
Number of job update events received
64+
65+
| Unit | Metric Type | Value Type | Monotonic | Stability |
66+
| ---- | ----------- | ---------- | --------- | --------- |
67+
| 1 | Sum | Int | true | Development |
68+
69+
### otelcol.k8s.watcher.namespace.added
70+
71+
Number of namespace add events received
72+
73+
| Unit | Metric Type | Value Type | Monotonic | Stability |
74+
| ---- | ----------- | ---------- | --------- | --------- |
75+
| 1 | Sum | Int | true | Development |
76+
77+
### otelcol.k8s.watcher.namespace.deleted
78+
79+
Number of namespace delete events received
80+
81+
| Unit | Metric Type | Value Type | Monotonic | Stability |
82+
| ---- | ----------- | ---------- | --------- | --------- |
83+
| 1 | Sum | Int | true | Development |
84+
85+
### otelcol.k8s.watcher.namespace.updated
86+
87+
Number of namespace update events received
88+
89+
| Unit | Metric Type | Value Type | Monotonic | Stability |
90+
| ---- | ----------- | ---------- | --------- | --------- |
91+
| 1 | Sum | Int | true | Development |
92+
93+
### otelcol.k8s.watcher.node.added
94+
95+
Number of node add events received
96+
97+
| Unit | Metric Type | Value Type | Monotonic | Stability |
98+
| ---- | ----------- | ---------- | --------- | --------- |
99+
| 1 | Sum | Int | true | Development |
100+
101+
### otelcol.k8s.watcher.node.deleted
102+
103+
Number of node delete events received
104+
105+
| Unit | Metric Type | Value Type | Monotonic | Stability |
106+
| ---- | ----------- | ---------- | --------- | --------- |
107+
| 1 | Sum | Int | true | Development |
108+
109+
### otelcol.k8s.watcher.node.updated
110+
111+
Number of node update events received
112+
113+
| Unit | Metric Type | Value Type | Monotonic | Stability |
114+
| ---- | ----------- | ---------- | --------- | --------- |
115+
| 1 | Sum | Int | true | Development |
116+
117+
### otelcol.k8s.watcher.pod.added
118+
119+
Number of pod add events received
120+
121+
| Unit | Metric Type | Value Type | Monotonic | Stability |
122+
| ---- | ----------- | ---------- | --------- | --------- |
123+
| 1 | Sum | Int | true | Development |
124+
125+
### otelcol.k8s.watcher.pod.deleted
126+
127+
Number of pod delete events received
128+
129+
| Unit | Metric Type | Value Type | Monotonic | Stability |
130+
| ---- | ----------- | ---------- | --------- | --------- |
131+
| 1 | Sum | Int | true | Development |
132+
133+
### otelcol.k8s.watcher.pod.updated
134+
135+
Number of pod update events received
136+
137+
| Unit | Metric Type | Value Type | Monotonic | Stability |
138+
| ---- | ----------- | ---------- | --------- | --------- |
139+
| 1 | Sum | Int | true | Development |
140+
141+
### otelcol.k8s.watcher.pod_cache.size
142+
143+
Size of cache table containing pod info
144+
145+
| Unit | Metric Type | Value Type | Stability |
146+
| ---- | ----------- | ---------- | --------- |
147+
| 1 | Gauge | Int | Development |
148+
149+
### otelcol.k8s.watcher.replicaset.added
150+
151+
Number of ReplicaSet add events received
152+
153+
| Unit | Metric Type | Value Type | Monotonic | Stability |
154+
| ---- | ----------- | ---------- | --------- | --------- |
155+
| 1 | Sum | Int | true | Development |
156+
157+
### otelcol.k8s.watcher.replicaset.deleted
158+
159+
Number of ReplicaSet delete events received
160+
161+
| Unit | Metric Type | Value Type | Monotonic | Stability |
162+
| ---- | ----------- | ---------- | --------- | --------- |
163+
| 1 | Sum | Int | true | Development |
164+
165+
### otelcol.k8s.watcher.replicaset.updated
166+
167+
Number of ReplicaSet update events received
168+
169+
| Unit | Metric Type | Value Type | Monotonic | Stability |
170+
| ---- | ----------- | ---------- | --------- | --------- |
171+
| 1 | Sum | Int | true | Development |
172+
173+
### otelcol.k8s.watcher.statefulset.added
174+
175+
Number of statefulset add events received
176+
177+
| Unit | Metric Type | Value Type | Monotonic | Stability |
178+
| ---- | ----------- | ---------- | --------- | --------- |
179+
| 1 | Sum | Int | true | Development |
180+
181+
### otelcol.k8s.watcher.statefulset.deleted
182+
183+
Number of statefulset delete events received
184+
185+
| Unit | Metric Type | Value Type | Monotonic | Stability |
186+
| ---- | ----------- | ---------- | --------- | --------- |
187+
| 1 | Sum | Int | true | Development |
188+
189+
### otelcol.k8s.watcher.statefulset.updated
190+
191+
Number of statefulset update events received
192+
193+
| Unit | Metric Type | Value Type | Monotonic | Stability |
194+
| ---- | ----------- | ---------- | --------- | --------- |
195+
| 1 | Sum | Int | true | Development |
196+
197+
### otelcol_otelsvc_k8s_ip_lookup_miss
198+
199+
[DEPRECATED] Number of times pod by IP lookup failed
200+
201+
> **Deprecated since 0.146.0**
202+
> Use otelcol.k8s.pod.association instead
203+
204+
| Unit | Metric Type | Value Type | Monotonic | Stability |
205+
| ---- | ----------- | ---------- | --------- | --------- |
206+
| 1 | Sum | Int | true | Deprecated since 0.146.0 |
207+
208+
**Deprecation note**: Use otelcol.k8s.pod.association instead
209+
53210
### otelcol_otelsvc_k8s_namespace_added
54211

55212
Number of namespace add events received
@@ -163,5 +320,7 @@ This component has the following feature gates:
163320
| `k8sattr.labelsAnnotationsSingular.allow` | deprecated | When enabled, default k8s label and annotation resource attribute keys will be singular, instead of plural | v0.125.0 | v0.145.0 | [Link](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/39774) |
164321
| `processor.k8sattributes.DontEmitV0K8sConventions` | alpha | When enabled, semconv legacy attributes are disabled. | v0.145.0 | N/A | [Link](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/44589) |
165322
| `processor.k8sattributes.EmitV1K8sConventions` | alpha | When enabled, semconv stable attributes are enabled. | v0.145.0 | N/A | [Link](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/44589) |
323+
| `processor.k8sattributes.telemetry.disableOldFormatMetrics` | alpha | When enabled, old formatted internal telemetry metrics are disabled. | v0.146.0 | N/A | [Link](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/45871) |
324+
| `processor.k8sattributes.telemetry.enableNewFormatMetrics` | alpha | When enabled, new formatted internal telemetry metrics are enabled. | v0.146.0 | N/A | [Link](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/45871) |
166325

167326
For more information about feature gates, see the [Feature Gates](https://github.com/open-telemetry/opentelemetry-collector/blob/main/featuregate/README.md) documentation.

0 commit comments

Comments
 (0)