OpenTelemetry PHP

RpcAttributes

Semantic attributes and corresponding values for rpc.

Tags
see
https://opentelemetry.io/docs/specs/semconv/registry/attributes/rpc/

Table of Contents

Constants

RPC_METHOD  : mixed = 'rpc.method'
The fully-qualified logical name of the method from the RPC interface perspective.
RPC_METHOD_ORIGINAL  : mixed = 'rpc.method_original'
The original name of the method used by the client.
RPC_STATUS_CODE  : mixed = 'rpc.status_code'
Status code of the RPC returned by the RPC server or generated by the client Usually it represents an error code, but may also represent partial success, warning, or differentiate between various types of successful outcomes.
RPC_SYSTEM_NAME  : mixed = 'rpc.system.name'
The Remote Procedure Call (RPC) system.
RPC_SYSTEM_NAME_VALUE_DUBBO  : mixed = 'dubbo'
[Apache Dubbo](https://dubbo.apache.org/)
RPC_SYSTEM_NAME_VALUE_GRPC  : mixed = 'grpc'
[gRPC](https://grpc.io/)

Constants

RPC_METHOD

The fully-qualified logical name of the method from the RPC interface perspective.

public mixed RPC_METHOD = 'rpc.method'

The method name MAY have unbounded cardinality in edge or error cases.

Some RPC frameworks or libraries provide a fixed set of recognized methods for client stubs and server implementations. Instrumentations for such frameworks MUST set this attribute to the original method name only when the method is recognized by the framework or library.

When the method is not recognized, for example, when the server receives a request for a method that is not predefined on the server, or when instrumentation is not able to reliably detect if the method is predefined, the attribute MUST be set to _OTHER.

If the RPC instrumentation could end up converting valid RPC methods to _OTHER, then it SHOULD provide a way to configure the list of recognized RPC methods.

The rpc.method can be different from the name of any implementing method/function. The code.function.name attribute may be used to record the fully-qualified method actually executing the call on the server side, or the RPC client stub method on the client side.

Tags
stable

RPC_METHOD_ORIGINAL

The original name of the method used by the client.

public mixed RPC_METHOD_ORIGINAL = 'rpc.method_original'
Tags
stable

RPC_STATUS_CODE

Status code of the RPC returned by the RPC server or generated by the client Usually it represents an error code, but may also represent partial success, warning, or differentiate between various types of successful outcomes.

public mixed RPC_STATUS_CODE = 'rpc.status_code'

The value MAY use a standardized string representation of a numeric status code, if one exists, instead of the numeric code. The value MAY be a synthetic status provided by the client library rather than returned by the remote service. Semantic conventions for individual RPC frameworks SHOULD document what rpc.status_code means in the context of that system and which values are considered to represent errors.

Tags
stable

RPC_SYSTEM_NAME

The Remote Procedure Call (RPC) system.

public mixed RPC_SYSTEM_NAME = 'rpc.system.name'

The client and server RPC systems may differ for the same RPC interaction. For example, a client may use Apache Dubbo or Connect RPC to communicate with a server that uses gRPC since both protocols provide compatibility with gRPC.

Tags
stable

RPC_SYSTEM_NAME_VALUE_DUBBO

[Apache Dubbo](https://dubbo.apache.org/)

public mixed RPC_SYSTEM_NAME_VALUE_DUBBO = 'dubbo'
Tags
stable

RPC_SYSTEM_NAME_VALUE_GRPC

[gRPC](https://grpc.io/)

public mixed RPC_SYSTEM_NAME_VALUE_GRPC = 'grpc'
Tags
stable
On this page

Search results