Skip to content

Commit 6d7e69c

Browse files
WilliamTomWilliam Tom
andauthored
[YUNIKORN-970] Add queue metrics with queue names as labels (#365)
Co-authored-by: William Tom <will@pinterest.com>
1 parent 96faa56 commit 6d7e69c

File tree

1 file changed

+54
-7
lines changed

1 file changed

+54
-7
lines changed

docs/metrics/queue.md

Lines changed: 54 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,37 @@ specific language governing permissions and limitations
2222
under the License.
2323
-->
2424

25-
## Queue
26-
### Application
27-
Eech queue has a `<queue_name> queue_app` metric to trace the applications in the queue.
25+
## Application
26+
Each queue has a `<queue_name> queue_app` metric to trace the applications in the queue.
2827
`<queue_name> queue_app` metrics records the number of applications in different states.
2928
These application states include `running`, `accepted`, `rejected`, `failed` and `completed`.
30-
`<queue_name> queue_app` metrics record container states including `released`, `allocated`.
31-
**Metric Type**: `guage`
29+
`<queue_name> queue_app` metrics record container states including `released`, `allocated`.
30+
31+
Prior to `1.5.0` queue metrics were pushed to a separate subsystem for each queue. In `1.5.0`
32+
fixed metrics with `<queue name>` labels were introduced. Metrics using `<queue name>` subsystems
33+
will be **deprecated in `1.6.0` and removed in `1.7.0`** in favor of a `<queue name>` label based approach.
34+
35+
### Label
36+
(Introduced in `1.5.0`)
37+
38+
**Metric Type**: `gauge`
39+
40+
**Namespace**: `yunikorn`
41+
42+
**Label**: `queue: <queue name>`
43+
44+
**TYPE**: `yunikorn_queue_app`
45+
46+
```json
47+
yunikorn_queue_app{queue="root.default",state="accepted"} 3
48+
yunikorn_queue_app{queue="root.default",state="running"} 3
49+
```
50+
51+
### Subsystem
52+
|:exclamation: To be deprecated in `1.6.0` and removed in `1.7.0`|
53+
|----------------------------------------------------------------|
54+
55+
**Metric Type**: `gauge`
3256

3357
**Namespace**: `yunikorn`
3458

@@ -41,11 +65,34 @@ yunikorn_root_default_queue_app{state="accepted"} 3
4165
yunikorn_root_default_queue_app{state="running"} 3
4266
```
4367

44-
### Resource
68+
## Resource
4569
The `<queue_name> queue_resource` metric to trace the resource in the queue.
4670
These resource states include `guaranteed`, `max`, `allocated`, `pending`, `preempting`.
71+
### Label
72+
(Introduced in `1.5.0`)
73+
74+
**Metric Type**: `gauge`
75+
76+
**Namespace**: `yunikorn`
77+
78+
**Label**: `queue: <queue name>`
79+
80+
**TYPE**: `yunikorn_queue_resource`
81+
82+
```json
83+
yunikorn_queue_resource{queue="root",resource="ephemeral-storage",state="max"} 9.41009558e+10
84+
yunikorn_queue_resource{queue="root",resource="hugepages-1Gi",state="max"} 0
85+
yunikorn_queue_resource{queue="root",resource="hugepages-2Mi",state="max"} 0
86+
yunikorn_queue_resource{queue="root",resource="memory",state="max"} 1.6223076352e+10
87+
yunikorn_queue_resource{queue="root",resource="pods",state="max"} 110
88+
yunikorn_queue_resource{queue="root",resource="vcore",state="max"} 8000
89+
```
90+
91+
### Subsystem
92+
|:exclamation: To be deprecated in `1.6.0` and removed in `1.7.0`|
93+
|----------------------------------------------------------------|
4794

48-
**Metric Type**: `guage`
95+
**Metric Type**: `gauge`
4996

5097
**Namespace**: `yunikorn`
5198

0 commit comments

Comments
 (0)