From bb5d3bb60abb3e85b51ee35e6430c0fde26a5ec2 Mon Sep 17 00:00:00 2001 From: Marylia Gutierrez Date: Tue, 14 May 2024 14:39:34 -0400 Subject: [PATCH] chore(instrumentation-bunyan): use strings exported for attributes (#2195) Refs: #2025 Signed-off-by: maryliag --- package-lock.json | 4 ++-- .../node/opentelemetry-instrumentation-bunyan/package.json | 2 +- .../opentelemetry-instrumentation-bunyan/test/bunyan.test.ts | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1ec8f3fbe4..f6d420fd7d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -37561,7 +37561,7 @@ "@opentelemetry/sdk-logs": "^0.51.0", "@opentelemetry/sdk-trace-base": "^1.8.0", "@opentelemetry/sdk-trace-node": "^1.8.0", - "@opentelemetry/semantic-conventions": "^1.0.0", + "@opentelemetry/semantic-conventions": "^1.23.0", "@types/mocha": "7.0.2", "@types/node": "18.6.5", "@types/sinon": "10.0.18", @@ -46302,7 +46302,7 @@ "@opentelemetry/sdk-logs": "^0.51.0", "@opentelemetry/sdk-trace-base": "^1.8.0", "@opentelemetry/sdk-trace-node": "^1.8.0", - "@opentelemetry/semantic-conventions": "^1.0.0", + "@opentelemetry/semantic-conventions": "^1.23.0", "@types/bunyan": "1.8.9", "@types/mocha": "7.0.2", "@types/node": "18.6.5", diff --git a/plugins/node/opentelemetry-instrumentation-bunyan/package.json b/plugins/node/opentelemetry-instrumentation-bunyan/package.json index 2392146e10..e9721696df 100644 --- a/plugins/node/opentelemetry-instrumentation-bunyan/package.json +++ b/plugins/node/opentelemetry-instrumentation-bunyan/package.json @@ -49,7 +49,7 @@ "@opentelemetry/sdk-logs": "^0.51.0", "@opentelemetry/sdk-trace-base": "^1.8.0", "@opentelemetry/sdk-trace-node": "^1.8.0", - "@opentelemetry/semantic-conventions": "^1.0.0", + "@opentelemetry/semantic-conventions": "^1.23.0", "@types/mocha": "7.0.2", "@types/node": "18.6.5", "@types/sinon": "10.0.18", diff --git a/plugins/node/opentelemetry-instrumentation-bunyan/test/bunyan.test.ts b/plugins/node/opentelemetry-instrumentation-bunyan/test/bunyan.test.ts index 13f2cf3356..deaf2fb1e7 100644 --- a/plugins/node/opentelemetry-instrumentation-bunyan/test/bunyan.test.ts +++ b/plugins/node/opentelemetry-instrumentation-bunyan/test/bunyan.test.ts @@ -28,7 +28,7 @@ import { import { NodeTracerProvider } from '@opentelemetry/sdk-trace-node'; import { isWrapped } from '@opentelemetry/instrumentation'; import { Resource } from '@opentelemetry/resources'; -import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; +import { SEMRESATTRS_SERVICE_NAME } from '@opentelemetry/semantic-conventions'; import * as assert from 'assert'; import * as sinon from 'sinon'; import { Writable } from 'stream'; @@ -48,7 +48,7 @@ tracerProvider.addSpanProcessor( const tracer = tracerProvider.getTracer('default'); const resource = new Resource({ - [SemanticResourceAttributes.SERVICE_NAME]: 'test-instrumentation-bunyan', + [SEMRESATTRS_SERVICE_NAME]: 'test-instrumentation-bunyan', }); const loggerProvider = new LoggerProvider({ resource }); const memExporter = new InMemoryLogRecordExporter();