From d0797f74cd17014238906f66c6d780ed0d77ff99 Mon Sep 17 00:00:00 2001 From: Siim Kallas Date: Tue, 12 Dec 2023 19:56:30 +0200 Subject: [PATCH] add TELEMETRY_SDK_VERSION to profiling payloads --- src/profiling/OTLPProfilingExporter.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/profiling/OTLPProfilingExporter.ts b/src/profiling/OTLPProfilingExporter.ts index d2771d21..f9d87f4f 100644 --- a/src/profiling/OTLPProfilingExporter.ts +++ b/src/profiling/OTLPProfilingExporter.ts @@ -19,6 +19,7 @@ import * as path from 'path'; import { CpuProfile, HeapProfile, ProfilingExporter } from './types'; import { diag } from '@opentelemetry/api'; import { Resource } from '@opentelemetry/resources'; +import { VERSION } from '@opentelemetry/core'; import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; import { parseEndpoint, @@ -104,6 +105,7 @@ export class OTLPProfilingExporter implements ProfilingExporter { const resource = new Resource({ [SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE]: 'node', + [SemanticResourceAttributes.TELEMETRY_SDK_VERSION]: VERSION, }).merge(options.resource); this._resourceAttributes = [];