PCA (Prometheus Certified Associate) sample exam question with answer 176
Question:
What is the difference between a histogram and a summary in Prometheus?
- A histogram is a set of observations that are counted in buckets, while a summary is a set of observations that are aggregated using percentiles
- A histogram is a set of observations that are aggregated using percentiles, while a summary is a set of observations that are counted in buckets
- A histogram and a summary are essentially the same thing, and can be used interchangeably in PromQL
- A histogram and a summary are different types of metrics that cannot be compared directly
Answer:
A - While histograms and summaries are both used to track distributions of data in Prometheus, they do so in slightly different ways. Histograms use pre-defined buckets to count the number of observations in each bucket, while summaries use quantiles to aggregate observations