diff --git a/dev-packages/e2e-tests/test-applications/nestjs-fastify/tests/transactions.test.ts b/dev-packages/e2e-tests/test-applications/nestjs-fastify/tests/transactions.test.ts index d1c86bac4dfa..b7a8dd5839bd 100644 --- a/dev-packages/e2e-tests/test-applications/nestjs-fastify/tests/transactions.test.ts +++ b/dev-packages/e2e-tests/test-applications/nestjs-fastify/tests/transactions.test.ts @@ -80,7 +80,7 @@ test('Sends an API route transaction', async ({ baseURL }) => { trace_id: expect.stringMatching(/[a-f0-9]{32}/), data: { 'sentry.origin': 'auto.http.otel.fastify', - 'sentry.op': 'request-handler.fastify', + 'sentry.op': 'request_handler.fastify', 'service.name': 'fastify', 'hook.name': 'fastify -> @fastify/otel -> @fastify/middie - route-handler', 'fastify.type': 'request-handler', @@ -88,7 +88,7 @@ test('Sends an API route transaction', async ({ baseURL }) => { 'hook.callback.name': 'anonymous', }, description: '@fastify/middie - route-handler', - op: 'request-handler.fastify', + op: 'request_handler.fastify', parent_span_id: expect.stringMatching(/[a-f0-9]{16}/), start_timestamp: expect.any(Number), timestamp: expect.any(Number), diff --git a/packages/node/src/integrations/tracing/fastify/index.ts b/packages/node/src/integrations/tracing/fastify/index.ts index 02f9a2adde4b..b84875b906e8 100644 --- a/packages/node/src/integrations/tracing/fastify/index.ts +++ b/packages/node/src/integrations/tracing/fastify/index.ts @@ -282,7 +282,7 @@ function addFastifySpanAttributes(span: Span): void { return; } - const opPrefix = isHook ? 'hook' : isHandler ? 'middleware' : isRequestHandler ? 'request-handler' : ''; + const opPrefix = isHook ? 'hook' : isHandler ? 'middleware' : isRequestHandler ? 'request_handler' : ''; span.setAttributes({ [SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN]: 'auto.http.otel.fastify',