Class RpcIncubatingAttributes
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classValues forRPC_CONNECT_RPC_ERROR_CODE.static final classValues forRPC_GRPC_STATUS_CODE.static final classValues forRPC_MESSAGE_TYPE.static final classValues forRPC_SYSTEM. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final io.opentelemetry.api.common.AttributeKey<String>The error codes of the Connect request.Connect request metadata,<key>being the normalized Connect Metadata key (lowercase), the value being the metadata values.Connect response metadata,<key>being the normalized Connect Metadata key (lowercase), the value being the metadata values.gRPC request metadata,<key>being the normalized gRPC Metadata key (lowercase), the value being the metadata values.gRPC response metadata,<key>being the normalized gRPC Metadata key (lowercase), the value being the metadata values.static final io.opentelemetry.api.common.AttributeKey<Long>The numeric status code of the gRPC request.static final io.opentelemetry.api.common.AttributeKey<Long>error.codeproperty of response if it is an error response.static final io.opentelemetry.api.common.AttributeKey<String>error.messageproperty of response if it is an error response.static final io.opentelemetry.api.common.AttributeKey<String>idproperty of request or response.static final io.opentelemetry.api.common.AttributeKey<String>Protocol version as injsonrpcproperty of request/response.static final io.opentelemetry.api.common.AttributeKey<Long>Compressed size of the message in bytes.static final io.opentelemetry.api.common.AttributeKey<Long>MUST be calculated as two different counters starting from1one for sent messages and one for received message.static final io.opentelemetry.api.common.AttributeKey<String>Whether this is a received or sent message.static final io.opentelemetry.api.common.AttributeKey<Long>Uncompressed size of the message in bytes.static final io.opentelemetry.api.common.AttributeKey<String>The name of the (logical) method being called, must be equal to the $method part in the span name.static final io.opentelemetry.api.common.AttributeKey<String>The full (logical) name of the service being called, including its package name, if applicable.static final io.opentelemetry.api.common.AttributeKey<String>A string identifying the remoting system. -
Method Summary
-
Field Details
-
RPC_CONNECT_RPC_ERROR_CODE
The error codes of the Connect request. Error codes are always string values. -
RPC_CONNECT_RPC_REQUEST_METADATA
public static final io.opentelemetry.semconv.AttributeKeyTemplate<List<String>> RPC_CONNECT_RPC_REQUEST_METADATAConnect request metadata,<key>being the normalized Connect Metadata key (lowercase), the value being the metadata values.Notes:
Instrumentations SHOULD require an explicit configuration of which metadata values are to be captured. Including all request metadata values can be a security risk - explicit configuration helps avoid leaking sensitive information.
For example, a property
my-custom-keywith value["1.2.3.4", "1.2.3.5"]SHOULD be recorded as therpc.connect_rpc.request.metadata.my-custom-keyattribute with value["1.2.3.4", "1.2.3.5"] -
RPC_CONNECT_RPC_RESPONSE_METADATA
public static final io.opentelemetry.semconv.AttributeKeyTemplate<List<String>> RPC_CONNECT_RPC_RESPONSE_METADATAConnect response metadata,<key>being the normalized Connect Metadata key (lowercase), the value being the metadata values.Notes:
Instrumentations SHOULD require an explicit configuration of which metadata values are to be captured. Including all response metadata values can be a security risk - explicit configuration helps avoid leaking sensitive information.
For example, a property
my-custom-keywith value"attribute_value"SHOULD be recorded as therpc.connect_rpc.response.metadata.my-custom-keyattribute with value["attribute_value"] -
RPC_GRPC_REQUEST_METADATA
public static final io.opentelemetry.semconv.AttributeKeyTemplate<List<String>> RPC_GRPC_REQUEST_METADATAgRPC request metadata,<key>being the normalized gRPC Metadata key (lowercase), the value being the metadata values.Notes:
Instrumentations SHOULD require an explicit configuration of which metadata values are to be captured. Including all request metadata values can be a security risk - explicit configuration helps avoid leaking sensitive information.
For example, a property
my-custom-keywith value["1.2.3.4", "1.2.3.5"]SHOULD be recorded asrpc.grpc.request.metadata.my-custom-keyattribute with value["1.2.3.4", "1.2.3.5"] -
RPC_GRPC_RESPONSE_METADATA
public static final io.opentelemetry.semconv.AttributeKeyTemplate<List<String>> RPC_GRPC_RESPONSE_METADATAgRPC response metadata,<key>being the normalized gRPC Metadata key (lowercase), the value being the metadata values.Notes:
Instrumentations SHOULD require an explicit configuration of which metadata values are to be captured. Including all response metadata values can be a security risk - explicit configuration helps avoid leaking sensitive information.
For example, a property
my-custom-keywith value["attribute_value"]SHOULD be recorded as therpc.grpc.response.metadata.my-custom-keyattribute with value["attribute_value"] -
RPC_GRPC_STATUS_CODE
The numeric status code of the gRPC request. -
RPC_JSONRPC_ERROR_CODE
error.codeproperty of response if it is an error response. -
RPC_JSONRPC_ERROR_MESSAGE
error.messageproperty of response if it is an error response. -
RPC_JSONRPC_REQUEST_ID
idproperty of request or response. Since protocol allows id to be int, string,nullor missing (for notifications), value is expected to be cast to string for simplicity. Use empty string in case ofnullvalue. Omit entirely if this is a notification. -
RPC_JSONRPC_VERSION
Protocol version as injsonrpcproperty of request/response. Since JSON-RPC 1.0 doesn't specify this, the value can be omitted. -
RPC_MESSAGE_COMPRESSED_SIZE
Compressed size of the message in bytes. -
RPC_MESSAGE_ID
MUST be calculated as two different counters starting from1one for sent messages and one for received message.Notes:
This way we guarantee that the values will be consistent between different implementations.
-
RPC_MESSAGE_TYPE
Whether this is a received or sent message. -
RPC_MESSAGE_UNCOMPRESSED_SIZE
Uncompressed size of the message in bytes. -
RPC_METHOD
The name of the (logical) method being called, must be equal to the $method part in the span name.Notes:
This is the logical name of the method from the RPC interface perspective, which can be different from the name of any implementing method/function. The
code.function.nameattribute may be used to store the latter (e.g., method actually executing the call on the server side, RPC client stub method on the client side). -
RPC_SERVICE
The full (logical) name of the service being called, including its package name, if applicable.Notes:
This is the logical name of the service from the RPC interface perspective, which can be different from the name of any implementing class. The
code.namespaceattribute may be used to store the latter (despite the attribute name, it may include a class name; e.g., class with method actually executing the call on the server side, RPC client stub class on the client side). -
RPC_SYSTEM
A string identifying the remoting system. See below for a list of well-known identifiers.
-