This repository has been archived by the owner on Nov 5, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for specifying distributions through protobuf and modify …
…probe config proto to provide an option to use distributions for latency. ORIGINAL_AUTHOR=Manu Garg <manugarg@gmail.com> PiperOrigin-RevId: 175631204
- Loading branch information
Showing
6 changed files
with
102 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
syntax = "proto2"; | ||
|
||
package cloudprober.metrics; | ||
|
||
message Distribution { | ||
oneof buckets { | ||
// Comma-separated list of lower bounds, where each lower bound is a float | ||
// value. Example: 0.5,1,2,4,8. | ||
string explicit_buckets = 1; | ||
// Exponential buckets are not supported yet. | ||
// TODO: Implement support for exponential buckets. | ||
ExponentialBuckets exponential_buckets = 2; | ||
} | ||
} | ||
|
||
// ExponentialBucket defines a set of num_buckets+2 buckets: | ||
// bucket[0] covers (−Inf, 0) | ||
// bucket[1] covers [0, scale_factor) | ||
// bucket[i] covers [scale_factor*base^(i−2), scale_factor*base^(i−1)) for i > 1 and i <= num_buckets | ||
// bucket[num_buckets+1] covers [scale_factor*base^(num_buckets−1), +Inf) | ||
// base must be at least 1.01. | ||
message ExponentialBuckets { | ||
optional float scale_factor = 1 [default = 1.0]; | ||
optional float base = 2 [default = 2]; | ||
optional uint32 num_buckets = 3 [default = 20]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters