Skip to content

Commit 2721add

Browse files
committed
fix 'bytes' unit by using 'By'
1 parent 11f4960 commit 2721add

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

jmx-scraper/src/integrationTest/java/io/opentelemetry/contrib/jmxscraper/target_systems/JvmIntegrationTest.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -78,95 +78,95 @@ protected MetricsVerifier createMetricsVerifier() {
7878
metric ->
7979
metric
8080
.hasDescription("current heap usage")
81-
.hasUnit("by")
81+
.hasUnit("By")
8282
.isGauge()
8383
.hasDataPointsWithoutAttributes())
8484
.add(
8585
"jvm.memory.heap.init",
8686
metric ->
8787
metric
8888
.hasDescription("current heap usage")
89-
.hasUnit("by")
89+
.hasUnit("By")
9090
.isGauge()
9191
.hasDataPointsWithoutAttributes())
9292
.add(
9393
"jvm.memory.heap.max",
9494
metric ->
9595
metric
9696
.hasDescription("current heap usage")
97-
.hasUnit("by")
97+
.hasUnit("By")
9898
.isGauge()
9999
.hasDataPointsWithoutAttributes())
100100
.add(
101101
"jvm.memory.heap.used",
102102
metric ->
103103
metric
104104
.hasDescription("current heap usage")
105-
.hasUnit("by")
105+
.hasUnit("By")
106106
.isGauge()
107107
.hasDataPointsWithoutAttributes())
108108
.add(
109109
"jvm.memory.nonheap.committed",
110110
metric ->
111111
metric
112112
.hasDescription("current non-heap usage")
113-
.hasUnit("by")
113+
.hasUnit("By")
114114
.isGauge()
115115
.hasDataPointsWithoutAttributes())
116116
.add(
117117
"jvm.memory.nonheap.init",
118118
metric ->
119119
metric
120120
.hasDescription("current non-heap usage")
121-
.hasUnit("by")
121+
.hasUnit("By")
122122
.isGauge()
123123
.hasDataPointsWithoutAttributes())
124124
.add(
125125
"jvm.memory.nonheap.max",
126126
metric ->
127127
metric
128128
.hasDescription("current non-heap usage")
129-
.hasUnit("by")
129+
.hasUnit("By")
130130
.isGauge()
131131
.hasDataPointsWithoutAttributes())
132132
.add(
133133
"jvm.memory.nonheap.used",
134134
metric ->
135135
metric
136136
.hasDescription("current non-heap usage")
137-
.hasUnit("by")
137+
.hasUnit("By")
138138
.isGauge()
139139
.hasDataPointsWithoutAttributes())
140140
.add(
141141
"jvm.memory.pool.committed",
142142
metric ->
143143
metric
144144
.hasDescription("current memory pool usage")
145-
.hasUnit("by")
145+
.hasUnit("By")
146146
.isGauge()
147147
.hasDataPointsWithAttributes(memoryAttributes))
148148
.add(
149149
"jvm.memory.pool.init",
150150
metric ->
151151
metric
152152
.hasDescription("current memory pool usage")
153-
.hasUnit("by")
153+
.hasUnit("By")
154154
.isGauge()
155155
.hasDataPointsWithAttributes(memoryAttributes))
156156
.add(
157157
"jvm.memory.pool.max",
158158
metric ->
159159
metric
160160
.hasDescription("current memory pool usage")
161-
.hasUnit("by")
161+
.hasUnit("By")
162162
.isGauge()
163163
.hasDataPointsWithAttributes(memoryAttributes))
164164
.add(
165165
"jvm.memory.pool.used",
166166
metric ->
167167
metric
168168
.hasDescription("current memory pool usage")
169-
.hasUnit("by")
169+
.hasUnit("By")
170170
.isGauge()
171171
.hasDataPointsWithAttributes(memoryAttributes))
172172
.add(

jmx-scraper/src/main/resources/jvm.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ rules:
2828
name: param(name)
2929

3030
- bean: java.lang:type=Memory
31-
unit: by
31+
unit: By
3232
prefix: jvm.memory.
3333
mapping:
3434
HeapMemoryUsage.committed:
@@ -66,7 +66,7 @@ rules:
6666

6767
- bean: java.lang:type=MemoryPool,name=*
6868
type: gauge
69-
unit: by
69+
unit: By
7070
metricAttribute:
7171
name: param(name)
7272
mapping:

0 commit comments

Comments
 (0)