feat(core-shared): IMetrics interface + NoopMetrics impl
This commit is contained in:
21
packages/core-shared/src/instrumentation/noop-metrics.ts
Normal file
21
packages/core-shared/src/instrumentation/noop-metrics.ts
Normal file
@@ -0,0 +1,21 @@
|
||||
import type { IMetrics, MetricAttributeValue } from "./metrics.interface";
|
||||
|
||||
export class NoopMetrics implements IMetrics {
|
||||
counter(
|
||||
_name: string,
|
||||
_value?: number,
|
||||
_attributes?: Record<string, MetricAttributeValue>,
|
||||
): void {}
|
||||
|
||||
histogram(
|
||||
_name: string,
|
||||
_value: number,
|
||||
_attributes?: Record<string, MetricAttributeValue>,
|
||||
): void {}
|
||||
|
||||
gauge(
|
||||
_name: string,
|
||||
_value: number,
|
||||
_attributes?: Record<string, MetricAttributeValue>,
|
||||
): void {}
|
||||
}
|
||||
Reference in New Issue
Block a user