This module provides automatic instrumentation for mssql
There are two variations
This is the recomended variation. The source code can be found here
In Progress
TODO
TODO
This variation would be depreciated soon. The source code can be found here
npm install --save opentelemetry-plugin-mssql
import {LogLevel} from '@opentelemetry/core'
import {NodeTracerProvider} from '@opentelemetry/node'
import {registerInstrumentations} from '@opentelemetry/instrumentation'
// Enable OpenTelemetry exporters to export traces to Grafan Tempo.
const provider = new NodeTracerProvider ({
plugins: {
mssql: {
enabled: true,
// You may use a package name or absolute path to the file.
path: "opentelemetry-plugin-mssql",
},
},
logLevel: LogLevel.ERROR,
});
registerInstrumentations({
tracerProvider: provider
});
Supported
Request.queryConnectionPool.query
Future
Request.executeRequest.batchRequest.bulkConnectionPool.batch
