1
0
Fork 0

Fix deprecated OTEL API

This commit is contained in:
Chocobozzz 2024-02-21 16:24:21 +01:00
parent d7edb2f8fe
commit 971077bccd
No known key found for this signature in database
GPG key ID: 583A612D890159BE

View file

@ -51,13 +51,14 @@ class OpenTelemetryMetrics {
const provider = new MeterProvider({
views: [
...NodeJSObserversBuilder.getViews()
]
})
provider.addMetricReader(new PrometheusExporter({
],
readers: [
new PrometheusExporter({
host: CONFIG.OPEN_TELEMETRY.METRICS.PROMETHEUS_EXPORTER.HOSTNAME,
port: CONFIG.OPEN_TELEMETRY.METRICS.PROMETHEUS_EXPORTER.PORT
}))
})
]
})
metrics.setGlobalMeterProvider(provider)