diff --git a/specification/api-tracing.md b/specification/api-tracing.md index 4834dfa895c..adaa7c28e23 100644 --- a/specification/api-tracing.md +++ b/specification/api-tracing.md @@ -344,8 +344,10 @@ A `Span` MUST have the ability to set attributes associated with it. An `Attribute` is defined by the following properties: - (Required) The attribute key, which must be a string. -- (Required) The attribute value, which must be either a string, a boolean - value, or a numeric type. +- (Required) The attribute value, which is either: + - A primitive type: string, boolean or numeric. + - An array of primitive type values. The array MUST be homogeneous, + i.e. it MUST NOT contain values of different types. The Span interface MUST provide: diff --git a/specification/data-semantic-conventions.md b/specification/data-semantic-conventions.md index cfda1326b78..627de6c59fc 100644 --- a/specification/data-semantic-conventions.md +++ b/specification/data-semantic-conventions.md @@ -6,6 +6,11 @@ Span attributes. * [Resource Conventions](data-resource-semantic-conventions.md) * [Span Conventions](#span-conventions) +The type of the attribute SHOULD be specified in the semantic convention +for that attribute. Array values are allowed for attributes. For +protocols that do not natively support array values such values MUST be +represented as JSON strings. + ## Span Conventions In OpenTelemetry spans can be created freely and it’s up to the implementor to