From 02a9fdb60ce9cb05f77bb431811cd40b348c45f1 Mon Sep 17 00:00:00 2001 From: Onur Temizkan Date: Fri, 4 Oct 2024 11:57:09 +0300 Subject: [PATCH] feat(instrumentation-fastify): Enable Fastify v5 (#2460) Co-authored-by: David Luna --- plugins/node/opentelemetry-instrumentation-fastify/.tav.yml | 4 ++++ .../src/instrumentation.ts | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/node/opentelemetry-instrumentation-fastify/.tav.yml b/plugins/node/opentelemetry-instrumentation-fastify/.tav.yml index 48410d0903..6f23da47eb 100644 --- a/plugins/node/opentelemetry-instrumentation-fastify/.tav.yml +++ b/plugins/node/opentelemetry-instrumentation-fastify/.tav.yml @@ -3,6 +3,10 @@ # releases. - versions: "4.0.0 || >=4.24.3 <5" commands: npm run test + - versions: ">=5 <6" + commands: npm run test + peerDependencies: "@fastify/express@4.0.1" + node: '>=20' # Fastify versions after 4.18.0 require a typescript greater than 4.4.4. "typescript": diff --git a/plugins/node/opentelemetry-instrumentation-fastify/src/instrumentation.ts b/plugins/node/opentelemetry-instrumentation-fastify/src/instrumentation.ts index e7014c5365..b03032d465 100644 --- a/plugins/node/opentelemetry-instrumentation-fastify/src/instrumentation.ts +++ b/plugins/node/opentelemetry-instrumentation-fastify/src/instrumentation.ts @@ -55,7 +55,7 @@ export class FastifyInstrumentation extends InstrumentationBase=3.0.0 <5'], + ['>=3.0.0 <6'], moduleExports => { return this._patchConstructor(moduleExports); }