Interface DbClientAttributesGetter<REQUEST,RESPONSE>
- All Superinterfaces:
io.opentelemetry.instrumentation.api.semconv.network.NetworkAttributesGetter<REQUEST,,RESPONSE> io.opentelemetry.instrumentation.api.semconv.network.ServerAttributesGetter<REQUEST>
- All Known Subinterfaces:
SqlClientAttributesGetter<REQUEST,RESPONSE>
public interface DbClientAttributesGetter<REQUEST,RESPONSE>
extends io.opentelemetry.instrumentation.api.semconv.network.NetworkAttributesGetter<REQUEST,RESPONSE>, io.opentelemetry.instrumentation.api.semconv.network.ServerAttributesGetter<REQUEST>
An interface for getting database client attributes.
Instrumentation authors will create implementations of this interface for their specific
library/framework. It will be used by the DbClientAttributesExtractor to obtain the
various database client attributes in a type-generic way.
If an attribute is not available in this library, it is appropriate to return null
from the attribute methods, but implement as many as possible for best compliance with the
OpenTelemetry specification.
-
Method Summary
Modifier and TypeMethodDescriptiondefault StringgetConnectionString(REQUEST request) Deprecated.There is no replacement at this time.getDbNamespace(REQUEST request) default LonggetDbOperationBatchSize(REQUEST request) getDbOperationName(REQUEST request) getDbQueryParameters(REQUEST request) default StringgetDbQuerySummary(REQUEST request) getDbQueryText(REQUEST request) default StringgetDbResponseStatusCode(RESPONSE response, Throwable error) getDbSystemName(REQUEST request) default StringDeprecated.There is no replacement at this time.Methods inherited from interface io.opentelemetry.instrumentation.api.semconv.network.NetworkAttributesGetter
getNetworkLocalAddress, getNetworkLocalInetSocketAddress, getNetworkLocalPort, getNetworkPeerAddress, getNetworkPeerInetSocketAddress, getNetworkPeerPort, getNetworkProtocolName, getNetworkProtocolVersion, getNetworkTransport, getNetworkTypeMethods inherited from interface io.opentelemetry.instrumentation.api.semconv.network.ServerAttributesGetter
getServerAddress, getServerPort
-
Method Details
-
getDbQueryText
-
getDbQuerySummary
-
getDbOperationName
-
getDbSystemName
-
getDbNamespace
-
getUser
Deprecated.There is no replacement at this time.Returns the database user name. This is only used for old semantic conventions. -
getConnectionString
Deprecated.There is no replacement at this time.Returns the database connection string. This is only used for old semantic conventions. -
getDbResponseStatusCode
-
getDbOperationBatchSize
-
getDbQueryParameters
-