function Span::getAttributes
attributes is a collection of key/value pairs. Note, global attributes like server name can be set using the resource API. Examples of attributes: "/http/user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" "/http/server_latency": 300 "example.com/myattribute": true "example.com/score": 10.239 The OpenTelemetry API specification further restricts the allowed value types: https://github.com/open-telemetry/opentelemetry-specification/blob/main… Attribute keys MUST be unique (it is not allowed to have more than one attribute with the same key).
Generated from protobuf field <code>repeated .opentelemetry.proto.common.v1.KeyValue attributes = 9;</code>
Return value
\Google\Protobuf\Internal\RepeatedField
File
-
vendor/
open-telemetry/ gen-otlp-protobuf/ Opentelemetry/ Proto/ Trace/ V1/ Span.php, line 612
Class
- Span
- A Span represents a single operation performed by a single component of the system. The next available field id is 17.
Namespace
Opentelemetry\Proto\Trace\V1Code
public function getAttributes() {
return $this->attributes;
}