@opentelemetry/instrumentation-aws-sdk doesn't work with NextJS
Unanswered
Aleksandr Cherednichenko posted this in #help-forum
Here is my setup in
I see expected trace spans recorded both manually and by NextJS, but I don't see spans for AWS SDK v3 calls (SQS, DynamoDB).
I've tried to pass
Does anybody have this working already?
Here is the link to the github issue with more details
https://github.com/open-telemetry/opentelemetry-js-contrib/issues/2734
instrumentation.node.ts
const sdk = new NodeSDK({
resource: new Resource({}),
instrumentations: [
new FetchInstrumentation(),
new HttpInstrumentation(),
new AwsInstrumentation({
suppressInternalInstrumentation: true,
}),
],
spanProcessors: [
new BatchSpanProcessor(new OTLPTraceExporter(), {
exportTimeoutMillis: 15000,
}),
],
metricReader: new PeriodicExportingMetricReader({
exporter: new OTLPMetricExporter(),
}),
sampler: new ParentBasedSampler({
root: new NextJSSampler({
base: new AlwaysOnSampler(),
// base: new TraceIdRatioBasedSampler(0.1),
}),
}),
});
sdk.start();
I see expected trace spans recorded both manually and by NextJS, but I don't see spans for AWS SDK v3 calls (SQS, DynamoDB).
I've tried to pass
instrumentation
array to @vercel/otel
registerOtel
fn config - same result.Does anybody have this working already?
Here is the link to the github issue with more details
https://github.com/open-telemetry/opentelemetry-js-contrib/issues/2734