Skip to content

Commit

Permalink
fix: Don't log health request (#50)
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalezzfelipe authored Apr 9, 2024
1 parent 7a8107e commit 253e14e
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions proxy/src/proxy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,16 +165,16 @@ impl ProxyHttp for KupoProxy {
_e: Option<&pingora::Error>,
ctx: &mut Self::CTX,
) {
let response_code = session
.response_written()
.map_or(0, |resp| resp.status.as_u16());
if !ctx.is_health_request {
let response_code = session
.response_written()
.map_or(0, |resp| resp.status.as_u16());

info!(
"{} response code: {response_code}",
self.request_summary(session, ctx)
);
info!(
"{} response code: {response_code}",
self.request_summary(session, ctx)
);

if !ctx.is_health_request {
self.state.metrics.inc_http_total_request(
&ctx.consumer,
&self.config.proxy_namespace,
Expand Down

0 comments on commit 253e14e

Please sign in to comment.