Skip to content

Commit 908f4ab

Browse files
Copilottrask
andcommitted
Remove experimental flag requirement for spec'd AWS attributes
Response attributes defined in AwsSdkRequestType (like aws.secretsmanager.secret.arn, aws.sns.topic.arn, etc.) are documented in semantic-conventions as incubating attributes and should always be extracted, regardless of the experimental flag setting. Co-authored-by: trask <[email protected]>
1 parent ffafd35 commit 908f4ab

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

instrumentation/aws-sdk/aws-sdk-2.2/library/src/main/java/io/opentelemetry/instrumentation/awssdk/v2_2/internal/TracingExecutionInterceptor.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -401,11 +401,9 @@ private void onSdkResponse(
401401
BedrockRuntimeAccess.recordResponseEvents(
402402
otelContext, eventLogger, executionAttributes, response, genAiCaptureMessageContent);
403403
}
404-
if (captureExperimentalSpanAttributes) {
405-
AwsSdkRequest sdkRequest = executionAttributes.getAttribute(AWS_SDK_REQUEST_ATTRIBUTE);
406-
if (sdkRequest != null) {
407-
fieldMapper.mapToAttributes(response, sdkRequest, span);
408-
}
404+
AwsSdkRequest sdkRequest = executionAttributes.getAttribute(AWS_SDK_REQUEST_ATTRIBUTE);
405+
if (sdkRequest != null) {
406+
fieldMapper.mapToAttributes(response, sdkRequest, span);
409407
}
410408
}
411409

0 commit comments

Comments
 (0)