Skip to content

Commit 0da3265

Browse files
committed
Explain Span layout better
Signed-off-by: beorn7 <[email protected]>
1 parent 8171e83 commit 0da3265

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

io/prometheus/client/metrics.proto

+6
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,12 @@ message Bucket {
9090
}
9191

9292
message SparseBuckets {
93+
// A Span is a given number of consecutive buckets at a given
94+
// offset. Logically, it would be more straightforward to include
95+
// the bucket counts in the Span. However, the protobuf
96+
// representation is more compact in the way the data is structured
97+
// here (with all the buckets in a single array separate from the
98+
// Spans).
9399
message Span {
94100
optional sint32 offset = 1; // Gap to previous span, or starting point for 1st span (which can be negative).
95101
optional uint32 length = 2; // Length of consecutive buckets.

0 commit comments

Comments
 (0)