Skip to content

Commit

Permalink
Remove dynamo db.name attribute (#4208)
Browse files Browse the repository at this point in the history
  • Loading branch information
trask authored Sep 28, 2021
1 parent 8c522a1 commit 6aaf5ef
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

import static io.opentelemetry.instrumentation.awssdk.v2_2.FieldMapping.request;

import io.opentelemetry.semconv.trace.attributes.SemanticAttributes;
import java.util.Collections;
import java.util.List;
import java.util.Map;
Expand All @@ -16,9 +15,7 @@ enum AwsSdkRequestType {
S3(request("aws.bucket.name", "Bucket")),
SQS(request("aws.queue.url", "QueueUrl"), request("aws.queue.name", "QueueName")),
Kinesis(request("aws.stream.name", "StreamName")),
DynamoDB(
request("aws.table.name", "TableName"),
request(SemanticAttributes.DB_NAME.getKey(), "TableName"));
DynamoDB(request("aws.table.name", "TableName"));

// Wrapping in unmodifiableMap
@SuppressWarnings("ImmutableEnumChecker")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@ abstract class AbstractAws2ClientTest extends InstrumentationSpecification {
"aws.requestId" "$requestId"
"aws.table.name" "sometable"
"${SemanticAttributes.DB_SYSTEM.key}" "dynamodb"
"${SemanticAttributes.DB_NAME.key}" "sometable"
"${SemanticAttributes.DB_OPERATION.key}" "CreateTable"
"aws.dynamodb.global_secondary_indexes" "[{\"IndexName\":\"globalIndex\",\"KeySchema\":[{\"AttributeName\":\"attribute\"}],\"ProvisionedThroughput\":{\"ReadCapacityUnits\":10,\"WriteCapacityUnits\":12}},{\"IndexName\":\"globalIndexSecondary\",\"KeySchema\":[{\"AttributeName\":\"attributeSecondary\"}],\"ProvisionedThroughput\":{\"ReadCapacityUnits\":7,\"WriteCapacityUnits\":8}}]"
"aws.dynamodb.provisioned_throughput.read_capacity_units" "1"
Expand Down Expand Up @@ -206,7 +205,6 @@ abstract class AbstractAws2ClientTest extends InstrumentationSpecification {
"aws.requestId" "$requestId"
"aws.table.name" "sometable"
"${SemanticAttributes.DB_SYSTEM.key}" "dynamodb"
"${SemanticAttributes.DB_NAME.key}" "sometable"
"${SemanticAttributes.DB_OPERATION.key}" "Query"
"aws.dynamodb.limit" "10"
"aws.dynamodb.select" "ALL_ATTRIBUTES"
Expand Down Expand Up @@ -241,7 +239,6 @@ abstract class AbstractAws2ClientTest extends InstrumentationSpecification {
"aws.requestId" "$requestId"
"aws.table.name" "sometable"
"${SemanticAttributes.DB_SYSTEM.key}" "dynamodb"
"${SemanticAttributes.DB_NAME.key}" "sometable"
"${SemanticAttributes.DB_OPERATION.key}" "${operation}"
}
}
Expand Down

0 comments on commit 6aaf5ef

Please sign in to comment.