diff --git a/docs/semantic-conventions.md b/docs/semantic-conventions.md index fca189d3cc30..e261ce43531f 100644 --- a/docs/semantic-conventions.md +++ b/docs/semantic-conventions.md @@ -72,3 +72,20 @@ not values defined by spec. | `rpc.system` | Y | + | | `rpc.service` | N | + | | `rpc.method` | N | + | + +## Database + +| Attribute | Required | Implemented? | +| -------------- | :---: | :---: | +| `db.system` | Y | + | +| `db.connection_string` | N | only set for Redis, JDBC and MongoDB | +| `db.user` | N | only set for JDBC| +| `db.jdbc.driver_classname` | N | - | +| `db.mssql.instance_name` | N | - | +| `db.name` | N | only set of JDBC, Mongo, Geode and MongoDB | +| `db.statement` | N | +, except for ElasticSearch and Memcached, see `db.operation` | +| `db.operation` | N | only set of ElasticSearch and Memcached | +| `db.cassandra.keyspace` | Y | + | +| `db.hbase` | Y | -, HBase is not supported | +| `db.redis.database_index` | N | only set for Lettuce driver, not for Jedis | +| `db.mongodb.collection` | Y | - | diff --git a/instrumentation-api/src/main/java/io/opentelemetry/instrumentation/api/tracer/DatabaseClientTracer.java b/instrumentation-api/src/main/java/io/opentelemetry/instrumentation/api/tracer/DatabaseClientTracer.java index 9e0c68a66a5a..22fb89a67716 100644 --- a/instrumentation-api/src/main/java/io/opentelemetry/instrumentation/api/tracer/DatabaseClientTracer.java +++ b/instrumentation-api/src/main/java/io/opentelemetry/instrumentation/api/tracer/DatabaseClientTracer.java @@ -46,14 +46,14 @@ public Span startSpan(CONNECTION connection, QUERY query) { Span span = tracer - .spanBuilder(spanName(normalizedQuery)) + .spanBuilder(spanName(normalizedQuery, connection)) .setSpanKind(CLIENT) .setAttribute(SemanticAttributes.DB_SYSTEM, dbSystem(connection)) .startSpan(); if (connection != null) { onConnection(span, connection); - onPeerConnection(span, connection); + setNetSemanticConvention(span, connection); } onStatement(span, normalizedQuery); @@ -111,7 +111,7 @@ protected void onError(Span span, Throwable throwable) { } } - protected void onPeerConnection(Span span, CONNECTION connection) { + protected void setNetSemanticConvention(Span span, CONNECTION connection) { NetPeerUtils.setNetPeer(span, peerAddress(connection)); } @@ -119,24 +119,33 @@ protected void onStatement(Span span, String statement) { span.setAttribute(SemanticAttributes.DB_STATEMENT, statement); } - // TODO: "When it's impossible to get any meaningful representation of the span name, it can be - // populated using the same value as db.name" (c) spec - protected String spanName(String query) { - return query == null ? DB_QUERY : query; - } - protected abstract String normalizeQuery(QUERY query); protected abstract String dbSystem(CONNECTION connection); - protected abstract String dbUser(CONNECTION connection); + protected String dbUser(CONNECTION connection) { + return null; + } - protected abstract String dbName(CONNECTION connection); + protected String dbName(CONNECTION connection) { + return null; + } - // TODO make abstract after implementing in all subclasses protected String dbConnectionString(CONNECTION connection) { return null; } protected abstract InetSocketAddress peerAddress(CONNECTION connection); + + private String spanName(String query, CONNECTION connection) { + if (query != null) { + return query; + } + + String result = null; + if (connection != null) { + result = dbName(connection); + } + return result == null ? DB_QUERY : result; + } } diff --git a/instrumentation/cassandra/cassandra-3.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v3_0/CassandraDatabaseClientTracer.java b/instrumentation/cassandra/cassandra-3.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v3_0/CassandraDatabaseClientTracer.java index 8feaf11d2266..c0627b21f6c9 100644 --- a/instrumentation/cassandra/cassandra-3.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v3_0/CassandraDatabaseClientTracer.java +++ b/instrumentation/cassandra/cassandra-3.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v3_0/CassandraDatabaseClientTracer.java @@ -23,6 +23,7 @@ import io.opentelemetry.instrumentation.api.tracer.utils.NetPeerUtils; import io.opentelemetry.instrumentation.auto.api.jdbc.DbSystem; import io.opentelemetry.trace.Span; +import io.opentelemetry.trace.attributes.SemanticAttributes; import java.net.InetSocketAddress; public class CassandraDatabaseClientTracer extends DatabaseClientTracer { @@ -44,13 +45,14 @@ protected String dbSystem(Session session) { } @Override - protected String dbUser(Session session) { - return null; + protected String dbName(Session session) { + return session.getLoggedKeyspace(); } @Override - protected String dbName(Session session) { - return session.getLoggedKeyspace(); + protected Span onConnection(Span span, Session session) { + span.setAttribute(SemanticAttributes.CASSANDRA_KEYSPACE, session.getLoggedKeyspace()); + return super.onConnection(span, session); } @Override diff --git a/instrumentation/cassandra/cassandra-3.0/src/test/groovy/CassandraClientTest.groovy b/instrumentation/cassandra/cassandra-3.0/src/test/groovy/CassandraClientTest.groovy index f1863359601e..43657fa5f661 100644 --- a/instrumentation/cassandra/cassandra-3.0/src/test/groovy/CassandraClientTest.groovy +++ b/instrumentation/cassandra/cassandra-3.0/src/test/groovy/CassandraClientTest.groovy @@ -144,6 +144,7 @@ class CassandraClientTest extends AgentTestRunner { "${SemanticAttributes.DB_SYSTEM.key()}" "cassandra" "${SemanticAttributes.DB_NAME.key()}" keyspace "${SemanticAttributes.DB_STATEMENT.key()}" statement + "${SemanticAttributes.CASSANDRA_KEYSPACE.key()}" keyspace } } } diff --git a/instrumentation/cassandra/cassandra-4.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v4_0/CassandraDatabaseClientTracer.java b/instrumentation/cassandra/cassandra-4.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v4_0/CassandraDatabaseClientTracer.java index 3267d40e7433..28bacba41e38 100644 --- a/instrumentation/cassandra/cassandra-4.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v4_0/CassandraDatabaseClientTracer.java +++ b/instrumentation/cassandra/cassandra-4.0/src/main/java/io/opentelemetry/instrumentation/auto/cassandra/v4_0/CassandraDatabaseClientTracer.java @@ -45,11 +45,6 @@ protected String dbSystem(CqlSession session) { return DbSystem.CASSANDRA; } - @Override - protected String dbUser(CqlSession session) { - return null; - } - @Override protected String dbName(CqlSession session) { return session.getKeyspace().map(CqlIdentifier::toString).orElse(null); diff --git a/instrumentation/couchbase/couchbase-2.0/src/main/java/io/opentelemetry/instrumentation/auto/couchbase/v2_0/CouchbaseClientTracer.java b/instrumentation/couchbase/couchbase-2.0/src/main/java/io/opentelemetry/instrumentation/auto/couchbase/v2_0/CouchbaseClientTracer.java index 71db420801bc..ec98ff902c30 100644 --- a/instrumentation/couchbase/couchbase-2.0/src/main/java/io/opentelemetry/instrumentation/auto/couchbase/v2_0/CouchbaseClientTracer.java +++ b/instrumentation/couchbase/couchbase-2.0/src/main/java/io/opentelemetry/instrumentation/auto/couchbase/v2_0/CouchbaseClientTracer.java @@ -37,16 +37,6 @@ protected String dbSystem(Void connection) { return DbSystem.COUCHBASE; } - @Override - protected String dbUser(Void connection) { - return null; - } - - @Override - protected String dbName(Void connection) { - return null; - } - @Override protected InetSocketAddress peerAddress(Void connection) { return null; diff --git a/instrumentation/elasticsearch/elasticsearch-rest-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/rest/ElasticsearchRestClientTracer.java b/instrumentation/elasticsearch/elasticsearch-rest-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/rest/ElasticsearchRestClientTracer.java index 1c00ee960bf4..3f8ab3b27daa 100644 --- a/instrumentation/elasticsearch/elasticsearch-rest-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/rest/ElasticsearchRestClientTracer.java +++ b/instrumentation/elasticsearch/elasticsearch-rest-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/rest/ElasticsearchRestClientTracer.java @@ -55,16 +55,6 @@ protected String dbSystem(Void connection) { return "elasticsearch"; } - @Override - protected String dbUser(Void connection) { - return null; - } - - @Override - protected String dbName(Void connection) { - return null; - } - @Override protected InetSocketAddress peerAddress(Void connection) { return null; diff --git a/instrumentation/elasticsearch/elasticsearch-transport-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/transport/ElasticsearchTransportClientTracer.java b/instrumentation/elasticsearch/elasticsearch-transport-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/transport/ElasticsearchTransportClientTracer.java index 864f9ca406e3..a482f8eef12d 100644 --- a/instrumentation/elasticsearch/elasticsearch-transport-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/transport/ElasticsearchTransportClientTracer.java +++ b/instrumentation/elasticsearch/elasticsearch-transport-common/src/main/java/io/opentelemetry/instrumentation/auto/elasticsearch/transport/ElasticsearchTransportClientTracer.java @@ -43,16 +43,6 @@ protected String dbSystem(Void connection) { return "elasticsearch"; } - @Override - protected String dbUser(Void connection) { - return null; - } - - @Override - protected String dbName(Void connection) { - return null; - } - @Override protected InetSocketAddress peerAddress(Void connection) { return null; diff --git a/instrumentation/geode-1.4/src/main/java/io/opentelemetry/instrumentation/auto/geode/GeodeTracer.java b/instrumentation/geode-1.4/src/main/java/io/opentelemetry/instrumentation/auto/geode/GeodeTracer.java index 6e8d6d373f0d..c93d11271cb8 100644 --- a/instrumentation/geode-1.4/src/main/java/io/opentelemetry/instrumentation/auto/geode/GeodeTracer.java +++ b/instrumentation/geode-1.4/src/main/java/io/opentelemetry/instrumentation/auto/geode/GeodeTracer.java @@ -40,7 +40,7 @@ public Span startSpan(String operation, Region connection, String query) { .startSpan(); onConnection(span, connection); - onPeerConnection(span, connection); + setNetSemanticConvention(span, connection); onStatement(span, normalizedQuery); return span; @@ -56,11 +56,6 @@ protected String dbSystem(Region region) { return DbSystem.GEODE; } - @Override - protected String dbUser(Region region) { - return null; - } - @Override protected String dbName(Region region) { return region.getName(); diff --git a/instrumentation/jedis/jedis-1.4/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v1_4/JedisClientTracer.java b/instrumentation/jedis/jedis-1.4/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v1_4/JedisClientTracer.java index b4af4aaf090b..c67e518915cf 100644 --- a/instrumentation/jedis/jedis-1.4/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v1_4/JedisClientTracer.java +++ b/instrumentation/jedis/jedis-1.4/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v1_4/JedisClientTracer.java @@ -35,16 +35,6 @@ protected String dbSystem(Connection connection) { return DbSystem.REDIS; } - @Override - protected String dbUser(Connection connection) { - return null; - } - - @Override - protected String dbName(Connection connection) { - return null; - } - @Override protected String dbConnectionString(Connection connection) { return connection.getHost() + ":" + connection.getPort(); diff --git a/instrumentation/jedis/jedis-3.0/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v3_0/JedisClientTracer.java b/instrumentation/jedis/jedis-3.0/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v3_0/JedisClientTracer.java index 112dad7372ef..376772fd0e6d 100644 --- a/instrumentation/jedis/jedis-3.0/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v3_0/JedisClientTracer.java +++ b/instrumentation/jedis/jedis-3.0/src/main/java/io/opentelemetry/instrumentation/auto/jedis/v3_0/JedisClientTracer.java @@ -43,16 +43,6 @@ protected String dbSystem(Connection connection) { return DbSystem.REDIS; } - @Override - protected String dbUser(Connection connection) { - return null; - } - - @Override - protected String dbName(Connection connection) { - return null; - } - @Override protected String dbConnectionString(Connection connection) { return connection.getHost() + ":" + connection.getPort(); diff --git a/instrumentation/lettuce/lettuce-4.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v4_0/LettuceAbstractDatabaseClientTracer.java b/instrumentation/lettuce/lettuce-4.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v4_0/LettuceAbstractDatabaseClientTracer.java index bf470044de44..4b7bdb630f9c 100644 --- a/instrumentation/lettuce/lettuce-4.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v4_0/LettuceAbstractDatabaseClientTracer.java +++ b/instrumentation/lettuce/lettuce-4.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v4_0/LettuceAbstractDatabaseClientTracer.java @@ -18,9 +18,9 @@ import com.lambdaworks.redis.RedisURI; import io.opentelemetry.instrumentation.api.tracer.DatabaseClientTracer; -import io.opentelemetry.instrumentation.api.tracer.utils.NetPeerUtils; import io.opentelemetry.instrumentation.auto.api.jdbc.DbSystem; import io.opentelemetry.trace.Span; +import io.opentelemetry.trace.attributes.SemanticAttributes; import java.net.InetSocketAddress; public abstract class LettuceAbstractDatabaseClientTracer @@ -31,26 +31,16 @@ protected String dbSystem(RedisURI connection) { return DbSystem.REDIS; } - @Override - protected String dbUser(RedisURI connection) { - return null; - } - - @Override - protected String dbName(RedisURI connection) { - return null; - } - @Override protected InetSocketAddress peerAddress(RedisURI redisURI) { - return null; + return new InetSocketAddress(redisURI.getHost(), redisURI.getPort()); } @Override public Span onConnection(Span span, RedisURI connection) { - if (connection != null) { - NetPeerUtils.setNetPeer(span, connection.getHost(), connection.getPort()); - span.setAttribute("db.redis.dbIndex", connection.getDatabase()); + if (connection != null && connection.getDatabase() != 0) { + span.setAttribute( + SemanticAttributes.REDIS_DATABASE_INDEX, String.valueOf(connection.getDatabase())); } return super.onConnection(span, connection); } diff --git a/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceAsyncClientTest.groovy b/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceAsyncClientTest.groovy index 7095a3b8d798..9a7433cd8bb5 100644 --- a/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceAsyncClientTest.groovy +++ b/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceAsyncClientTest.groovy @@ -135,7 +135,6 @@ class LettuceAsyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" port "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } @@ -170,7 +169,6 @@ class LettuceAsyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" incorrectPort "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } diff --git a/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceSyncClientTest.groovy b/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceSyncClientTest.groovy index f362cda9b154..2befa5a685ea 100644 --- a/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceSyncClientTest.groovy +++ b/instrumentation/lettuce/lettuce-4.0/src/test/groovy/LettuceSyncClientTest.groovy @@ -117,7 +117,6 @@ class LettuceSyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" port "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } @@ -150,7 +149,6 @@ class LettuceSyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" incorrectPort "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } diff --git a/instrumentation/lettuce/lettuce-5.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v5_0/LettuceAbstractDatabaseClientTracer.java b/instrumentation/lettuce/lettuce-5.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v5_0/LettuceAbstractDatabaseClientTracer.java index c54bc1bb97aa..72be5c2e032b 100644 --- a/instrumentation/lettuce/lettuce-5.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v5_0/LettuceAbstractDatabaseClientTracer.java +++ b/instrumentation/lettuce/lettuce-5.0/src/main/java/io/opentelemetry/instrumentation/auto/lettuce/v5_0/LettuceAbstractDatabaseClientTracer.java @@ -20,6 +20,7 @@ import io.opentelemetry.instrumentation.api.tracer.DatabaseClientTracer; import io.opentelemetry.instrumentation.auto.api.jdbc.DbSystem; import io.opentelemetry.trace.Span; +import io.opentelemetry.trace.attributes.SemanticAttributes; import java.net.InetSocketAddress; public abstract class LettuceAbstractDatabaseClientTracer @@ -34,16 +35,6 @@ protected String dbSystem(RedisURI connection) { return DbSystem.REDIS; } - @Override - protected String dbUser(RedisURI connection) { - return null; - } - - @Override - protected String dbName(RedisURI connection) { - return null; - } - @Override protected InetSocketAddress peerAddress(RedisURI redisURI) { return new InetSocketAddress(redisURI.getHost(), redisURI.getPort()); @@ -51,8 +42,9 @@ protected InetSocketAddress peerAddress(RedisURI redisURI) { @Override public Span onConnection(Span span, RedisURI connection) { - if (connection != null) { - span.setAttribute("db.redis.dbIndex", connection.getDatabase()); + if (connection != null && connection.getDatabase() != 0) { + span.setAttribute( + SemanticAttributes.REDIS_DATABASE_INDEX, String.valueOf(connection.getDatabase())); } return super.onConnection(span, connection); } diff --git a/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceAsyncClientTest.groovy b/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceAsyncClientTest.groovy index 4ecb644374b0..a66a0709f7c6 100644 --- a/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceAsyncClientTest.groovy +++ b/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceAsyncClientTest.groovy @@ -139,7 +139,6 @@ class LettuceAsyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" port "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } @@ -175,7 +174,6 @@ class LettuceAsyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" incorrectPort "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } diff --git a/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceSyncClientTest.groovy b/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceSyncClientTest.groovy index ddd0a7c102cb..8d0b1f3343d5 100644 --- a/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceSyncClientTest.groovy +++ b/instrumentation/lettuce/lettuce-5.0/src/test/groovy/LettuceSyncClientTest.groovy @@ -119,7 +119,6 @@ class LettuceSyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" port "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } @@ -152,7 +151,6 @@ class LettuceSyncClientTest extends AgentTestRunner { "${SemanticAttributes.NET_PEER_PORT.key()}" incorrectPort "${SemanticAttributes.DB_SYSTEM.key()}" "redis" "${SemanticAttributes.DB_STATEMENT.key()}" "CONNECT" - "db.redis.dbIndex" 0 } } } diff --git a/instrumentation/mongo/mongo-common/src/main/java/io/opentelemetry/instrumentation/auto/mongo/MongoClientTracer.java b/instrumentation/mongo/mongo-common/src/main/java/io/opentelemetry/instrumentation/auto/mongo/MongoClientTracer.java index 0f1d5773df04..f73ee4c74b7c 100644 --- a/instrumentation/mongo/mongo-common/src/main/java/io/opentelemetry/instrumentation/auto/mongo/MongoClientTracer.java +++ b/instrumentation/mongo/mongo-common/src/main/java/io/opentelemetry/instrumentation/auto/mongo/MongoClientTracer.java @@ -47,11 +47,6 @@ protected String dbSystem(CommandStartedEvent event) { return DbSystem.MONGODB; } - @Override - protected String dbUser(CommandStartedEvent event) { - return null; - } - @Override protected String dbName(CommandStartedEvent event) { // Use description if set. diff --git a/instrumentation/rediscala-1.8/src/main/java/io/opentelemetry/instrumentation/auto/rediscala/RediscalaClientTracer.java b/instrumentation/rediscala-1.8/src/main/java/io/opentelemetry/instrumentation/auto/rediscala/RediscalaClientTracer.java index 91879757db7d..4ba1e1d2df54 100644 --- a/instrumentation/rediscala-1.8/src/main/java/io/opentelemetry/instrumentation/auto/rediscala/RediscalaClientTracer.java +++ b/instrumentation/rediscala-1.8/src/main/java/io/opentelemetry/instrumentation/auto/rediscala/RediscalaClientTracer.java @@ -26,16 +26,6 @@ public class RediscalaClientTracer public static final RediscalaClientTracer TRACER = new RediscalaClientTracer(); - @Override - protected String dbUser(RedisCommand command) { - return null; - } - - @Override - protected String dbName(RedisCommand command) { - return null; - } - @Override protected String normalizeQuery(RedisCommand redisCommand) { return spanNameForClass(redisCommand.getClass()); diff --git a/instrumentation/redisson-3.0/src/main/java/io/opentelemetry/instrumentation/auto/redisson/RedissonClientTracer.java b/instrumentation/redisson-3.0/src/main/java/io/opentelemetry/instrumentation/auto/redisson/RedissonClientTracer.java index 85e02dd8e558..01591848d0f9 100644 --- a/instrumentation/redisson-3.0/src/main/java/io/opentelemetry/instrumentation/auto/redisson/RedissonClientTracer.java +++ b/instrumentation/redisson-3.0/src/main/java/io/opentelemetry/instrumentation/auto/redisson/RedissonClientTracer.java @@ -58,16 +58,6 @@ protected String dbSystem(RedisConnection connection) { return DbSystem.REDIS; } - @Override - protected String dbUser(RedisConnection o) { - return null; - } - - @Override - protected String dbName(RedisConnection o) { - return null; - } - @Override protected InetSocketAddress peerAddress(RedisConnection connection) { Channel channel = connection.getChannel(); diff --git a/instrumentation/spymemcached-2.12/src/main/java/io/opentelemetry/instrumentation/auto/spymemcached/MemcacheClientTracer.java b/instrumentation/spymemcached-2.12/src/main/java/io/opentelemetry/instrumentation/auto/spymemcached/MemcacheClientTracer.java index ec2cb05abc16..97b903f09898 100644 --- a/instrumentation/spymemcached-2.12/src/main/java/io/opentelemetry/instrumentation/auto/spymemcached/MemcacheClientTracer.java +++ b/instrumentation/spymemcached-2.12/src/main/java/io/opentelemetry/instrumentation/auto/spymemcached/MemcacheClientTracer.java @@ -30,16 +30,6 @@ protected String dbSystem(MemcachedConnection memcachedConnection) { return "memcached"; } - @Override - protected String dbUser(MemcachedConnection session) { - return null; - } - - @Override - protected String dbName(MemcachedConnection connection) { - return null; - } - @Override protected InetSocketAddress peerAddress(MemcachedConnection memcachedConnection) { return null;