v0.25.5
This commit is contained in:
1 parent
1dea7f55c8
commit
c819f0a335
151 files changed
+7610
-4264
No files matched your search
@@ -26,7 +26,9 @@ impl Lease {
|
||||
|| !self.passive_health.count_slow_responses)
|
||||
{
|
||||
if is_slow {
|
||||
self.member.state.record_passive_observation("slow_response");
|
||||
self.member
|
||||
.state
|
||||
.record_passive_observation("slow_response");
|
||||
}
|
||||
"http_5xx"
|
||||
} else if is_slow {
|
||||
@@ -62,7 +64,10 @@ impl Lease {
|
||||
self.member.state.record_failure(class, detail);
|
||||
let passive_reason = match class {
|
||||
"connect" | "dns" | "tls" => "connect_error",
|
||||
"timeout" | "body_timeout" | "response_header_timeout" | "read_timeout"
|
||||
"timeout"
|
||||
| "body_timeout"
|
||||
| "response_header_timeout"
|
||||
| "read_timeout"
|
||||
| "send_timeout" => "timeout",
|
||||
_ => "io_error",
|
||||
};
|
||||
@@ -147,33 +152,102 @@ impl Pool {
|
||||
let _ = writeln!(text, "rust_proxy_backend_{metric}{{{labels}}} {value}");
|
||||
}
|
||||
for (metric, value) in [
|
||||
("active_health_failures_total", state.active_health_failures_total.load(Ordering::Relaxed)),
|
||||
("passive_health_failures_total", state.passive_health_failures_total.load(Ordering::Relaxed)),
|
||||
("http_5xx_total", state.http_5xx_total.load(Ordering::Relaxed)),
|
||||
("passive_http_5xx_total", state.http_5xx_total.load(Ordering::Relaxed)),
|
||||
("timeouts_total", state.timeouts_total.load(Ordering::Relaxed)),
|
||||
("passive_timeouts_total", state.timeouts_total.load(Ordering::Relaxed)),
|
||||
("connect_errors_total", state.connect_errors_total.load(Ordering::Relaxed)),
|
||||
("passive_connect_errors_total", state.connect_errors_total.load(Ordering::Relaxed)),
|
||||
("io_errors_total", state.io_errors_total.load(Ordering::Relaxed)),
|
||||
("passive_io_errors_total", state.io_errors_total.load(Ordering::Relaxed)),
|
||||
("slow_responses_total", state.slow_responses_total.load(Ordering::Relaxed)),
|
||||
("passive_slow_total", state.slow_responses_total.load(Ordering::Relaxed)),
|
||||
("retry_attempts_total", state.retry_attempts_total.load(Ordering::Relaxed)),
|
||||
("retry_successes_total", state.retry_successes_total.load(Ordering::Relaxed)),
|
||||
("capacity_rejections_total", state.capacity_rejections_total.load(Ordering::Relaxed)),
|
||||
("queue_timeouts_total", state.queue_timeouts_total.load(Ordering::Relaxed)),
|
||||
("dns_errors_total", state.dns_errors_total.load(Ordering::Relaxed)),
|
||||
("tls_errors_total", state.tls_errors_total.load(Ordering::Relaxed)),
|
||||
("response_header_timeouts_total", state.response_header_timeouts_total.load(Ordering::Relaxed)),
|
||||
("read_timeouts_total", state.read_timeouts_total.load(Ordering::Relaxed)),
|
||||
("send_timeouts_total", state.send_timeouts_total.load(Ordering::Relaxed)),
|
||||
(
|
||||
"active_health_failures_total",
|
||||
state.active_health_failures_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"passive_health_failures_total",
|
||||
state.passive_health_failures_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"http_5xx_total",
|
||||
state.http_5xx_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"passive_http_5xx_total",
|
||||
state.http_5xx_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"timeouts_total",
|
||||
state.timeouts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"passive_timeouts_total",
|
||||
state.timeouts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"connect_errors_total",
|
||||
state.connect_errors_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"passive_connect_errors_total",
|
||||
state.connect_errors_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"io_errors_total",
|
||||
state.io_errors_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"passive_io_errors_total",
|
||||
state.io_errors_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"slow_responses_total",
|
||||
state.slow_responses_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"passive_slow_total",
|
||||
state.slow_responses_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"retry_attempts_total",
|
||||
state.retry_attempts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"retry_successes_total",
|
||||
state.retry_successes_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"capacity_rejections_total",
|
||||
state.capacity_rejections_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"queue_timeouts_total",
|
||||
state.queue_timeouts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"dns_errors_total",
|
||||
state.dns_errors_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"tls_errors_total",
|
||||
state.tls_errors_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"response_header_timeouts_total",
|
||||
state.response_header_timeouts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"read_timeouts_total",
|
||||
state.read_timeouts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"send_timeouts_total",
|
||||
state.send_timeouts_total.load(Ordering::Relaxed),
|
||||
),
|
||||
] {
|
||||
let _ = writeln!(text, "rust_proxy_backend_{metric}{{{labels}}} {value}");
|
||||
}
|
||||
for (metric, value) in [
|
||||
("last_ejected_timestamp_milliseconds", state.last_ejected_ms.load(Ordering::Relaxed)),
|
||||
("last_recovered_timestamp_milliseconds", state.last_recovered_ms.load(Ordering::Relaxed)),
|
||||
(
|
||||
"last_ejected_timestamp_milliseconds",
|
||||
state.last_ejected_ms.load(Ordering::Relaxed),
|
||||
),
|
||||
(
|
||||
"last_recovered_timestamp_milliseconds",
|
||||
state.last_recovered_ms.load(Ordering::Relaxed),
|
||||
),
|
||||
] {
|
||||
let _ = writeln!(text, "rust_proxy_backend_{metric}{{{labels}}} {value}");
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user