Fix comment on explicit_bounds (#313)

* Fix comment on explicit_bounds

* Update metrics.proto

* Define explicit_bounds using size(explicit_bounds)

* Fix bug when i == size(explicit_bounds)

Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
pull/321/head
Victor Lu 4 years ago committed by GitHub
parent f3b0ee0861
commit bc8ee79d8e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 14
      opentelemetry/proto/metrics/v1/metrics.proto

@ -413,12 +413,11 @@ message HistogramDataPoint {
// explicit_bounds specifies buckets with explicitly defined bounds for values.
//
// This defines size(explicit_bounds) + 1 (= N) buckets. The boundaries for
// bucket at index i are:
// The boundaries for bucket at index i are:
//
// (-infinity, explicit_bounds[i]] for i == 0
// (explicit_bounds[i-1], explicit_bounds[i]] for 0 < i < N-1
// (explicit_bounds[i], +infinity) for i == N-1
// (explicit_bounds[i-1], explicit_bounds[i]] for 0 < i < size(explicit_bounds)
// (explicit_bounds[i-1], +infinity) for i == size(explicit_bounds)
//
// The values in the explicit_bounds array must be strictly increasing.
//
@ -641,12 +640,11 @@ message IntHistogramDataPoint {
// explicit_bounds specifies buckets with explicitly defined bounds for values.
//
// This defines size(explicit_bounds) + 1 (= N) buckets. The boundaries for
// bucket at index i are:
// The boundaries for bucket at index i are:
//
// (-infinity, explicit_bounds[i]] for i == 0
// (explicit_bounds[i-1], explicit_bounds[i]] for 0 < i < N-1
// (explicit_bounds[i], +infinity) for i == N-1
// (explicit_bounds[i-1], explicit_bounds[i]] for 0 < i < size(explicit_bounds)
// (explicit_bounds[i-1], +infinity) for i == size(explicit_bounds)
//
// The values in the explicit_bounds array must be strictly increasing.
//

Loading…
Cancel
Save