use prometheus::{register_int_counter, IntCounter};
lazy_static::lazy_static! {
pub static ref CONNECTIONS_ACCEPTED: IntCounter =
register_int_counter!(
"connections_accepted_total",
"Total number of accepted connections"
).expect("Failed to create connections_accepted_total counter");
pub static ref BYTES_TRANSMITTED_A: IntCounter =
register_int_counter!(
"bytes_transmitted_a_total",
"Total number of bytes transmitted for A"
).expect("Failed to create bytes_transmitted_a_total counter");
pub static ref BYTES_TRANSMITTED_B: IntCounter =
register_int_counter!(
"bytes_transmitted_b_total",
"Total number of bytes transmitted for B"
).expect("Failed to create bytes_transmitted_b_total counter");
pub static ref TCP_FORWARDING_ERRORS: IntCounter =
register_int_counter!(
"tcp_forwarding_errors_total",
"Total number of TCP forwarding errors encountered"
).expect("Failed to create tcp_forwarding_errors_total counter");
pub static ref KEEPALIVE_ERRORS: IntCounter =
register_int_counter!(
"keepalive_errors_total",
"Total number of errors in the keepalive loop"
).expect("Failed to create keepalive_errors_total counter");
pub static ref SERVER_CONNECTIONS_OPENED_TOTAL: IntCounter =
register_int_counter!(
"server_connections_opened_total",
"Total number of times the client connected to the server"
).expect("Failed to create server_connections_opened_total counter");
pub static ref SERVER_CONNECTIONS_GRACEFULLY_CLOSED_TOTAL: IntCounter =
register_int_counter!(
"server_connections_gracefully_closed_total",
"Total number of times the server connection was closed cleanly"
).expect("Failed to create server_connections_gracefully_closed_total counter");
}