Skip to content

Commit 3350583

Browse files
fix(instrumentation-runtime-node): use the correct unit for eventloop.utilization (#2631)
Co-authored-by: Marc Pichler <[email protected]>
1 parent 4cfcc59 commit 3350583

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

plugins/node/instrumentation-runtime-node/src/metrics/eventLoopUtilizationCollector.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export class EventLoopUtilizationCollector extends BaseCollector {
3838
`${this.namePrefix}.${ATTR_NODEJS_EVENT_LOOP_UTILIZATION}`,
3939
{
4040
description: 'Event loop utilization',
41-
unit: 's',
41+
unit: '1',
4242
}
4343
)
4444
.addCallback(async observableResult => {

plugins/node/instrumentation-runtime-node/test/event_loop_utilization.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ describe(`${ConventionalNamePrefix.NodeJs}.${ATTR_NODEJS_EVENT_LOOP_UTILIZATION}
9090

9191
assert.strictEqual(
9292
utilizationMetric!.descriptor.unit,
93-
's',
93+
'1',
9494
'expected default unit'
9595
);
9696

0 commit comments

Comments
 (0)