Skip to content

Commit a79f813

Browse files
[kubernetes] Remove deprecated fields, add missing status.last_terminated_reason metric (elastic#9736)
* remove deprecated fields Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co> * Update changelog.yml * add missing metric: last_terminated_reason; update description of the status.reason field Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co> --------- Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co>
1 parent b1627a3 commit a79f813

4 files changed

Lines changed: 15 additions & 16 deletions

File tree

packages/kubernetes/changelog.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
# newer versions go on top
2+
- version: 1.61.0
3+
changes:
4+
- description: Remove deprecated fields and add missing status.last_terminated_reason metric
5+
type: enhancement
6+
link: https://github.com/elastic/integrations/pull/9736
27
- version: 1.60.0
38
changes:
49
- description: Updating `Memory used vs total memory` and `Cores used vs total cores` visualisations in Cluster Overview Dashboard

packages/kubernetes/data_stream/state_container/fields/fields.yml

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,13 @@
2525
- name: reason
2626
dimension: true
2727
type: keyword
28-
description: |
29-
Waiting (ContainerCreating, CrashLoopBackoff, ErrImagePull, ImagePullBackoff) or termination (Completed, ContainerCannotRun, Error, OOMKilled) reason.
28+
description: >
29+
The reason the container is currently in waiting (ContainerCreating, CrashLoopBackoff, ErrImagePull,
30+
ImagePullBackoff) or terminated (Completed, ContainerCannotRun, Error, OOMKilled) state.
31+
- name: last_terminated_reason
32+
type: keyword
33+
description: >
34+
The last reason the container was in terminated state (Completed, ContainerCannotRun, Error or OOMKilled).
3035
- name: cpu
3136
type: group
3237
fields:
@@ -40,16 +45,6 @@
4045
metric_type: gauge
4146
description: |
4247
Container CPU requested cores
43-
- name: limit.nanocores
44-
type: long
45-
metric_type: gauge
46-
description: |
47-
Container CPU nanocores limit
48-
- name: request.nanocores
49-
type: long
50-
metric_type: gauge
51-
description: |
52-
Container CPU requested nanocores
5348
- name: memory
5449
type: group
5550
fields:

packages/kubernetes/docs/kube-state-metrics.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -193,16 +193,15 @@ An example event for `state_container` looks as following:
193193
| host.type | Type of host. For Cloud providers this can be the machine type like `t2.medium`. If vm, this could be the container, for example, or other information meaningful in your environment. | keyword | | |
194194
| kubernetes.annotations.\* | Kubernetes annotations map | object | | |
195195
| kubernetes.container.cpu.limit.cores | Container CPU cores limit | float | | gauge |
196-
| kubernetes.container.cpu.limit.nanocores | Container CPU nanocores limit | long | | gauge |
197196
| kubernetes.container.cpu.request.cores | Container CPU requested cores | float | | gauge |
198-
| kubernetes.container.cpu.request.nanocores | Container CPU requested nanocores | long | | gauge |
199197
| kubernetes.container.id | Container id | keyword | | |
200198
| kubernetes.container.memory.limit.bytes | Container memory limit in bytes | long | byte | gauge |
201199
| kubernetes.container.memory.request.bytes | Container requested memory in bytes | long | byte | gauge |
202200
| kubernetes.container.name | Kubernetes container name | keyword | | |
201+
| kubernetes.container.status.last_terminated_reason | The last reason the container was in terminated state (Completed, ContainerCannotRun, Error or OOMKilled). | keyword | | |
203202
| kubernetes.container.status.phase | Container phase (running, waiting, terminated) | keyword | | |
204203
| kubernetes.container.status.ready | Container ready status | boolean | | |
205-
| kubernetes.container.status.reason | Waiting (ContainerCreating, CrashLoopBackoff, ErrImagePull, ImagePullBackoff) or termination (Completed, ContainerCannotRun, Error, OOMKilled) reason. | keyword | | |
204+
| kubernetes.container.status.reason | The reason the container is currently in waiting (ContainerCreating, CrashLoopBackoff, ErrImagePull, ImagePullBackoff) or terminated (Completed, ContainerCannotRun, Error, OOMKilled) state. | keyword | | |
206205
| kubernetes.container.status.restarts | Container restarts count | integer | | counter |
207206
| kubernetes.cronjob.name | Name of the CronJob to which the Pod belongs | keyword | | |
208207
| kubernetes.daemonset.name | Kubernetes daemonset name | keyword | | |

packages/kubernetes/manifest.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
format_version: 3.1.2
22
name: kubernetes
33
title: Kubernetes
4-
version: 1.60.0
4+
version: 1.61.0
55
description: Collect logs and metrics from Kubernetes clusters with Elastic Agent.
66
type: integration
77
categories:

0 commit comments

Comments
 (0)