4.x agent span attributes and resources
The OpenTelemetry Specification defines the attributes and resources that each plugin type must include in the spans it generates. However, to manage the volume of reported data, the Application Real-Time Monitoring Service (ARMS) agent does not record all of these attributes by default. If you enable the Record OTel Spec conventional attributes switch on the Custom Configuration page, the corresponding attributes are added to the spans for each framework.
Common attributes
Attribute name | Description | Example | Notes |
rpc.type | The call type of the current span. | 0, 40, 60 | This field is for internal use by ARMS and may change in the future. You can ignore this field. |
serviceType | The service type of the current span. | 1000, 1010 | This field is for internal use by ARMS and may change in the future. You can ignore this field. |
ali.trace.flag | An identifier for Alibaba Cloud observability products. It indicates which product collected and reported the trace data:
| arms | This field is for internal use by ARMS and may change in the future. You can ignore this field. |
component.name | The name of the component corresponding to the current span. | mysql, http | For all possible values, see Application monitoring metrics. |
hasInternalSpan | Indicates whether the current span has an associated span with a `spanKind` of `Internal`. | 1 | This attribute is included only in the LocalRootSpan. |
otel.scope.name | The name of the plugin that generated the current span. | io.opentelemetry.jdbc | - |
otel.scope.version | The version number of the plugin that generated the current span. | 1.28.0-SNAPSHOT | - |
root.service.id | The ID of the first ARMS application that the trace passed through. | aokcd***@b57c445****** | - |
sample.service.id | Determine the application ID for which to sample and report traces. | aokcd***@b57c445****** | ARMS supports various sampling methods. The application that decides to sample is not necessarily the entry point application. For more information, see Trace sampling modes (for agent versions 3.2.8 and later). |
sample.reason | The sampling policy that was hit when the decision to sample the trace was made. | s4 | For more information, see Sampling flags. |
ppid | The ID of the upstream application. | aokcd***@b57c445****** | - |
thread.name | The thread name. | http-nio-8080-exec-162 | - |
thread.id | The thread ID. | 12783 | - |
trace.protocol.type | Specifies the trace context propagation protocol for the current link. | EagleEye, W3C | This attribute is included only in the LocalRootSpan. |
Common resources
Resource name | Description | Example | Notes |
host.name | The hostname where the application is running. | mall-gateway-54c647a51d-db78a | Added in version 4.5.0. |
agentVersion | Probe Version | 4.5.0_3d5f5f7 | - |
acs.arms.service.id | The ARMS service ID. | gauui7wh2@8a8763fbd23c898cd52*** | This field is for internal use by ARMS and may change in the future. You can ignore this field. |
acs.arms.workspace | The ARMS workspace name. | default-cms-1324351***-cn-hangzhou | This field is for internal use by ARMS and may change in the future. You can ignore this field. |
arms.appId | The ARMS application ID. | gauui7wh2@8a8763fbd23c898cd52*** | This field is for internal use by ARMS and may change in the future. You can ignore this field. |
clusterId | The ACK cluster ID. | c98cd52967df89a8e9*** | Exists only in ACK environments. It is obtained from the `KUBERNETES_CLUSTER_ID` environment variable. |
ipv4 | The IP address of the application. | 127.0.0.1 | - |
namespace | The cluster namespace. | default | Exists only in Kubernetes environments. It is obtained from the `KUBERNETES_POD_NAMESPACE` environment variable. |
workloadKind | The workload type. | Deployment | Exists only in Kubernetes environments. It is obtained from the `ARMS_WORKLOADKIND` environment variable. |
workloadName | The workload name. | mall-gateway | Exists only in Kubernetes environments. It is obtained from the `ARMS_WORKLOADNAME` environment variable. |
Attributes specific to HTTP spans
Attribute type | Attribute name | Description | Example |
Common attribute | http.method | The HTTP method name. | GET, POST |
http.status_code | The HTTP status code. | 200, 404, 500 | |
status | The converged HTTP status code. | 200, 4xx, 5xx | |
HTTP server-side span attribute | http.path | The path of the HTTP request. | /api/v1/user |
http.route | The route of the HTTP request. | /api/v1/user `http.route` is different from `http.path`. For example, in SpringMVC, if an HTTP interface is declared with a path parameter, such as `/api/v1/{userId}`, `http.route` records `/api/v1/{userId}` and `http.path` records the actual request path. | |
http.params | The parameters of the HTTP request. This is the content after the | userId=123 | |
HTTP client-side span attribute | destId | The domain name and port number of the HTTP request. | 127.0.0.1 |
endpoint | The path of the HTTP request. | /api/v1/user |
Attributes specific to RPC calls
Attribute type | Attribute name | Description | Example |
Common attribute | rpc.system | The RPC framework. | Dubbo, gRPC |
rpc.service | The service name of the RPC call. | com.test.TestService | |
rpc.method | The method name of the RPC call. | sayHello | |
destId | The peer address. | 127.0.0.1:20880 |
Attributes specific to scheduled task calls
Attribute type | Attribute name | Description | Example |
Common attribute | job.system | The scheduled task framework. | ShchedulerX, XXLJob |
job.id | The task ID. | 2847 | |
job.name | The task name. | testJob | |
job.result.status | The task execution status. | success |
Attributes specific to messaging calls
Attribute type | Attribute name | Description | Example |
Common attribute | messaging.system | The messaging framework. | RocketMQ, Kafka |
messaging.operation | The message processing action. | publish, receive, process | |
messaging.message.payload_size_bytes | The message size. | 137 | |
messaging.destination.name | The message topic. | user_order | |
destId | The address of the message broker. | rmq-********-vpc.cn-beijing.rmq.aliyuncs.com:8080 | |
endpoint | ${destId} + @ + ${messaging.destination.name} | rmq-********-vpc.cn-beijing.rmq.aliyuncs.com:8080@user_order | |
Attributes specific to RocketMQ | messaging.consume.delay_ms | The message consumption delay (supported only by RocketMQ). | 128 |
Attributes specific to Kafka | messaging.kafka.destination.partition | The partition where the Kafka message is located. | 5 |
messaging.kafka.message.offset | The offset of the Kafka message within its partition. | 42 | |
messaging.kafka.message.key | The key of the Kafka message. | mykey |
Database and NoSQL attributes
Attribute type | Attribute name | Description | Example |
Common attribute | db.name | The database name. This is parsed from the full connection string parameters. If the connection string does not contain this information, the field is empty. | test |
net.peer.name | The domain name and port part of the database connection string. | *****.mysql.rds.aliyuncs.com:3306 | |
sql | The database statement. | SELECT * FROM user WHERE user_id=? | |
db.statement.id | A 16-character encoded ID for the database statement. | 5a620e8cf06156a5 | |
destId | The database name. The content is the same as `db.name`. This is redundant to ensure compatibility with different query scenarios and will be removed in the future. | test | |
endpoint | The database connection string. The content is the same as `net.peer.name`. This is redundant to ensure compatibility with different query scenarios and will be removed in the future. | *****.mysql.rds.aliyuncs.com:3306 | |
out.ids | The database connection string. The content is the same as `net.peer.name`. This is redundant to ensure compatibility with different query scenarios and will be removed in the future. | *****.mysql.rds.aliyuncs.com:3306 | |
opType | The database operation type. | SELECT | |
response.size | The size of the database query response in bytes. | 54 | |
MongoDB Attribute | db.mongodb.collection | The name of the collection for the MongoDB operation. | user |
Redis Attribute | redis.command.key | The key accessed in Redis. | key |