Skip to content

Commit df17995

Browse files
committed
ref(develop/spans): Clarify span attribute units
1 parent a28a03a commit df17995

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

develop-docs/sdk/telemetry/spans/span-protocol.mdx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,11 @@ The envelope item payload must contain an `items` array with span one and up to
9191
"http.response.status_code": {
9292
"type": "integer",
9393
"value": 200
94+
},
95+
"session.duration": {
96+
"type": "integer",
97+
"value": 164,
98+
"unit": "second"
9499
}
95100
},
96101
"links": [
@@ -158,9 +163,9 @@ Attributes are stored as key-value pairs where each value is an object with type
158163

159164
| Property | Type | Required | Description |
160165
|----------|------|----------|-------------|
161-
| `type` | string | Yes | The data type of the attribute value. Values: `"string"`, `"integer"`, `"double"`, `"boolean"` |
166+
| `type` | string | Yes | The data type of the attribute value. Values: `"string"`, `"integer"`, `"double"`, `"boolean", `"string[]"`, `"integer[]"`, `"double[]"`, `"boolean[]"` |
162167
| `value` | any | Yes | The actual attribute value, must match the specified type |
163-
| `unit` | string | No | The unit of the attribute value. Example values: `"ms"`, `"s"`, `"bytes"`, `"count"`, `"percent"` |
168+
| `unit` | string | No | The unit of the attribute value. Example values: `"millisecond"`, `"second"`, `"byte"`, `"ratio"`. Units MUST be one of the [MetricUnit](https://getsentry.github.io/relay/relay_metrics/enum.MetricUnit.html)s supported by Relay, excluding `""`, `"none"` or custom units. |
164169

165170
#### Common Attribute Keys
166171

0 commit comments

Comments
 (0)