Fix prometheus function signature to use strings instead of strs

This commit is contained in:
Kerollmops 2025-04-16 10:30:55 +02:00
parent bc5efa9a76
commit 1f1edd6e25
No known key found for this signature in database
GPG Key ID: F250A4C4E3AE5F5F

View File

@ -77,7 +77,9 @@ where
let res = fut.await?; let res = fut.await?;
crate::metrics::MEILISEARCH_HTTP_REQUESTS_TOTAL crate::metrics::MEILISEARCH_HTTP_REQUESTS_TOTAL
.with_label_values(&[&request_method, &metric_path, res.status().as_str()]) .with_label_values(
&[request_method, metric_path, res.status().as_str().to_string()][..],
)
.inc(); .inc();
if let Some(histogram_timer) = histogram_timer { if let Some(histogram_timer) = histogram_timer {