mirror of
https://github.com/postgresml/pgcat.git
synced 2026-03-27 18:56:30 +00:00
Log not implemented messages as debug in prometheus metrics. (#477)
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
use hyper::service::{make_service_fn, service_fn};
|
use hyper::service::{make_service_fn, service_fn};
|
||||||
use hyper::{Body, Method, Request, Response, Server, StatusCode};
|
use hyper::{Body, Method, Request, Response, Server, StatusCode};
|
||||||
use log::{error, info, warn};
|
use log::{error, info, debug};
|
||||||
use phf::phf_map;
|
use phf::phf_map;
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
use std::fmt;
|
use std::fmt;
|
||||||
@@ -275,7 +275,7 @@ fn push_address_stats(lines: &mut Vec<String>) {
|
|||||||
{
|
{
|
||||||
lines.push(prometheus_metric.to_string());
|
lines.push(prometheus_metric.to_string());
|
||||||
} else {
|
} else {
|
||||||
warn!("Metric {} not implemented for {}", key, address.name());
|
debug!("Metric {} not implemented for {}", key, address.name());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -293,7 +293,7 @@ fn push_pool_stats(lines: &mut Vec<String>) {
|
|||||||
{
|
{
|
||||||
lines.push(prometheus_metric.to_string());
|
lines.push(prometheus_metric.to_string());
|
||||||
} else {
|
} else {
|
||||||
warn!("Metric {} not implemented for ({})", name, *pool_id);
|
debug!("Metric {} not implemented for ({})", name, *pool_id);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -318,7 +318,7 @@ fn push_database_stats(lines: &mut Vec<String>) {
|
|||||||
{
|
{
|
||||||
lines.push(prometheus_metric.to_string());
|
lines.push(prometheus_metric.to_string());
|
||||||
} else {
|
} else {
|
||||||
warn!("Metric {} not implemented for {}", key, address.name());
|
debug!("Metric {} not implemented for {}", key, address.name());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user