File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed
packages/instrumentation-mysql/src Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ import {
4444} from './utils' ;
4545/** @knipignore */
4646import { PACKAGE_NAME , PACKAGE_VERSION } from './version' ;
47- import { UpDownCounter , MeterProvider } from '@opentelemetry/api' ;
47+ import { UpDownCounter } from '@opentelemetry/api' ;
4848
4949type getConnectionCallbackType = (
5050 err : mysqlTypes . MysqlError ,
@@ -59,15 +59,9 @@ export class MySQLInstrumentation extends InstrumentationBase<MySQLInstrumentati
5959
6060 constructor ( config : MySQLInstrumentationConfig = { } ) {
6161 super ( PACKAGE_NAME , PACKAGE_VERSION , config ) ;
62- this . _setMetricInstruments ( ) ;
6362 }
6463
65- override setMeterProvider ( meterProvider : MeterProvider ) {
66- super . setMeterProvider ( meterProvider ) ;
67- this . _setMetricInstruments ( ) ;
68- }
69-
70- private _setMetricInstruments ( ) {
64+ protected override _updateMetricInstruments ( ) {
7165 this . _connectionsUsage = this . meter . createUpDownCounter (
7266 'db.client.connections.usage' , //TODO:: use semantic convention
7367 {
You can’t perform that action at this time.
0 commit comments