Prometheus: Difference between revisions
(Created page with "== Overview == 모니터링 관리 툴 Prometheus 내용 정리. == See also == * https://prometheus.io/docs/introduction/overview/ category:system") |
|||
(2 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
== Overview == | == Overview == | ||
모니터링 관리 툴 Prometheus 내용 정리. | 모니터링 관리 툴 Prometheus 내용 정리. | ||
== Metric types == | |||
* https://prometheus.io/docs/concepts/metric_types/ | |||
=== Counter === | |||
A counter is a cumulative metric that represents a single monotonically increasing counter whose value can only increase or be reset to zero on restart. For example, you can use a counter to represent the number of requests served, tasks completed, or errors. | |||
Do not use a counter to expose a value that can decrease. For example, do not use a counter for the number of currently running processes; instead, use a gauge. | |||
=== Guage === | |||
A gauge is a metric that represents a single numerical value that can arbitrarily go up and down. | |||
Gauges are typically used for measured values like temperatures or current memory usage, but also "counts" that can go up and down, like the number of concurrent requests. | |||
=== Histogram === | |||
A histogram samples observations (usually things like request durations or response sizes) and counts them in configurable buckets. It also provides a sum of all observed values. | |||
A histogram with a base metric name of <basename> exposes multiple time series during a scrape: | |||
* cumulative counters for the observation buckets, exposed as <basename>_bucket{le="<upper inclusive bound>"} | |||
* the total sum of all observed values, exposed as <basename>_sum | |||
* the count of events that have been observed, exposed ad <basename>_count (identical to <basename>_bucket{le="+Inf"} above) | |||
Uthe the histogram_quantile() function to calculate quantiles from histograms or even aggregations of histograms. A histogram is also suitable to calculate an Apdex score. When operating on bucket, remember that the histogram is cumulative. See histograms and summaries for details of histogram usage and differences to summaries. | |||
Useful site for using the histogram. | |||
* https://www.robustperception.io/how-does-a-prometheus-histogram-work | |||
== Query == | |||
=== Operator === | |||
* https://prometheus.io/docs/prometheus/latest/querying/operators/ | |||
== See also == | == See also == |
Latest revision as of 17:35, 11 March 2021
Overview
모니터링 관리 툴 Prometheus 내용 정리.
Metric types
Counter
A counter is a cumulative metric that represents a single monotonically increasing counter whose value can only increase or be reset to zero on restart. For example, you can use a counter to represent the number of requests served, tasks completed, or errors.
Do not use a counter to expose a value that can decrease. For example, do not use a counter for the number of currently running processes; instead, use a gauge.
Guage
A gauge is a metric that represents a single numerical value that can arbitrarily go up and down.
Gauges are typically used for measured values like temperatures or current memory usage, but also "counts" that can go up and down, like the number of concurrent requests.
Histogram
A histogram samples observations (usually things like request durations or response sizes) and counts them in configurable buckets. It also provides a sum of all observed values.
A histogram with a base metric name of <basename> exposes multiple time series during a scrape:
- cumulative counters for the observation buckets, exposed as <basename>_bucket{le="<upper inclusive bound>"}
- the total sum of all observed values, exposed as <basename>_sum
- the count of events that have been observed, exposed ad <basename>_count (identical to <basename>_bucket{le="+Inf"} above)
Uthe the histogram_quantile() function to calculate quantiles from histograms or even aggregations of histograms. A histogram is also suitable to calculate an Apdex score. When operating on bucket, remember that the histogram is cumulative. See histograms and summaries for details of histogram usage and differences to summaries.
Useful site for using the histogram.