play more

Signed-off-by: beorn7 <beorn@grafana.com>
This commit is contained in:
beorn7 2024-06-26 19:17:45 +02:00
parent 9c344085f9
commit 90efb4ee97
1 changed files with 2 additions and 4 deletions

View File

@ -116,11 +116,9 @@ func main() {
m.rpcDurationsHistogram.(prometheus.ExemplarObserver).ObserveWithExemplar( m.rpcDurationsHistogram.(prometheus.ExemplarObserver).ObserveWithExemplar(
0, prometheus.Labels{"dummyID": fmt.Sprint(rand.Intn(100000))}, 0, prometheus.Labels{"dummyID": fmt.Sprint(rand.Intn(100000))},
) )
m.rpcDurationsHistogram.(prometheus.ExemplarObserver).ObserveWithExemplar(
0.01, prometheus.Labels{"dummyID": fmt.Sprint(rand.Intn(100000))},
)
for { for {
v := (rand.NormFloat64() * *normDomain) + *normMean v := math.Abs((rand.NormFloat64() * *normDomain) + *normMean)
m.rpcDurations.WithLabelValues("normal").Observe(v) m.rpcDurations.WithLabelValues("normal").Observe(v)
// Demonstrate exemplar support with a dummy ID. This // Demonstrate exemplar support with a dummy ID. This
// would be something like a trace ID in a real // would be something like a trace ID in a real