mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-03 11:57:07 +02:00
Add Prometheus metrics to measure task queue latency
This commit is contained in:
parent
b18cd9075d
commit
47827ca5c1
2 changed files with 33 additions and 11 deletions
|
@ -1,7 +1,7 @@
|
|||
use lazy_static::lazy_static;
|
||||
use prometheus::{
|
||||
opts, register_histogram_vec, register_int_counter_vec, register_int_gauge,
|
||||
register_int_gauge_vec, HistogramVec, IntCounterVec, IntGauge, IntGaugeVec,
|
||||
opts, register_gauge, register_histogram_vec, register_int_counter_vec, register_int_gauge,
|
||||
register_int_gauge_vec, Gauge, HistogramVec, IntCounterVec, IntGauge, IntGaugeVec,
|
||||
};
|
||||
|
||||
lazy_static! {
|
||||
|
@ -63,4 +63,9 @@ lazy_static! {
|
|||
"Meilisearch Searches Being Processed"
|
||||
))
|
||||
.expect("Can't create a metric");
|
||||
pub static ref MEILISEARCH_TASK_QUEUE_LATENCY_SECONDS: Gauge = register_gauge!(
|
||||
"meilisearch_task_queue_latency_seconds",
|
||||
"Meilisearch Task Queue Latency in Seconds",
|
||||
)
|
||||
.expect("Can't create a metric");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue