File tree Expand file tree Collapse file tree 2 files changed +11
-4
lines changed
plugins/node/opentelemetry-instrumentation-aws-sdk Expand file tree Collapse file tree 2 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -159,5 +159,12 @@ export const GEN_AI_TOKEN_TYPE_VALUE_INPUT = 'input' as const;
159159 */
160160export const GEN_AI_TOKEN_TYPE_VALUE_OUTPUT = 'output' as const ;
161161
162- // Copied ATTR_AWS_SNS_TOPIC_ARN from '@opentelemetry/semantic-conventions/incubating'
162+ /**
163+ * Originally from '@opentelemetry/semantic-conventions/incubating'
164+ * https://github.com/open-telemetry/semantic-conventions/blob/main/docs/registry/attributes/aws.md#amazon-sns-attributes
165+ * The ARN of the AWS SNS Topic. An Amazon SNS [topic](https://docs.aws.amazon.com/sns/latest/dg/sns-create-topic.html)
166+ * is a logical access point that acts as a communication channel.
167+ * @example arn:aws:sns:us-east-1:123456789012:mystack-mytopic-NZJ5JSMVGFIE
168+ * @experimental This attribute is experimental and is subject to breaking changes in minor releases of `@opentelemetry/semantic-conventions`.
169+ */
163170export const ATTR_AWS_SNS_TOPIC_ARN = 'aws.sns.topic.arn' as const ;
Original file line number Diff line number Diff line change @@ -124,11 +124,11 @@ describe('SNS - v3', () => {
124124 await sns . createTopic ( {
125125 Name : topicName ,
126126 } ) ;
127- const publishSpans = getTestSpans ( ) . filter (
127+ const createTopicSpans = getTestSpans ( ) . filter (
128128 ( s : ReadableSpan ) => s . name === 'SNS CreateTopic'
129129 ) ;
130- expect ( publishSpans . length ) . toBe ( 1 ) ;
131- const publishSpan = publishSpans [ 0 ] ;
130+ expect ( createTopicSpans . length ) . toBe ( 1 ) ;
131+ const publishSpan = createTopicSpans [ 0 ] ;
132132 expect ( publishSpan . attributes [ ATTR_AWS_SNS_TOPIC_ARN ] ) . toBe ( topicArn ) ;
133133 expect ( publishSpan . kind ) . toBe ( SpanKind . CLIENT ) ;
134134 } ) ;
You can’t perform that action at this time.
0 commit comments