From: Aurelien DARRAGON Date: Fri, 21 Mar 2025 12:54:48 +0000 (+0100) Subject: MINOR: stats-proxy: add alt name info to stat_cols_px where relevant X-Git-Tag: v3.2-dev8~4 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=276491dc226f9c483f5d6a467f0e1d445a5de934;p=thirdparty%2Fhaproxy.git MINOR: stats-proxy: add alt name info to stat_cols_px where relevant For all metrics defined under promex_st_metrics array, add the corresponding .alt_name field in the general purpose stat_cols_px array. --- diff --git a/src/stats-proxy.c b/src/stats-proxy.c index 1235e325b..c1e42facd 100644 --- a/src/stats-proxy.c +++ b/src/stats-proxy.c @@ -48,120 +48,120 @@ } const struct stat_col stat_cols_px[ST_I_PX_MAX] = { - [ST_I_PX_PXNAME] = { .name = "pxname", .desc = "Proxy name" }, - [ST_I_PX_SVNAME] = { .name = "svname", .desc = "Server name" }, - [ST_I_PX_QCUR] = { .name = "qcur", .desc = "Number of current queued connections", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_QMAX] = { .name = "qmax", .desc = "Highest value of queued connections encountered since process started", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_SCUR] = { .name = "scur", .desc = "Number of current sessions on the frontend, backend or server", .cap = STATS_PX_CAP_LFBS}, - [ST_I_PX_SMAX] = { .name = "smax", .desc = "Highest value of current sessions encountered since process started", .cap = STATS_PX_CAP_LFBS }, - [ST_I_PX_SLIM] = { .name = "slim", .desc = "Frontend/listener/server's maxconn, backend's fullconn", .cap = STATS_PX_CAP_LFBS }, - [ST_I_PX_STOT] = ME_NEW_PX("stot", NULL, FN_COUNTER, FF_U64, cum_sess, STATS_PX_CAP_LFBS, "Total number of sessions since process started"), - [ST_I_PX_BIN] = ME_NEW_PX("bin", NULL, FN_COUNTER, FF_U64, bytes_in, STATS_PX_CAP_LFBS, "Total number of request bytes since process started"), - [ST_I_PX_BOUT] = ME_NEW_PX("bout", NULL, FN_COUNTER, FF_U64, bytes_out, STATS_PX_CAP_LFBS, "Total number of response bytes since process started"), - [ST_I_PX_DREQ] = ME_NEW_PX("dreq", NULL, FN_COUNTER, FF_U64, denied_req, STATS_PX_CAP_LFB_, "Total number of denied requests since process started"), - [ST_I_PX_DRESP] = ME_NEW_PX("dresp", NULL, FN_COUNTER, FF_U64, denied_resp, STATS_PX_CAP_LFBS, "Total number of denied responses since process started"), - [ST_I_PX_EREQ] = ME_NEW_FE("ereq", NULL, FN_COUNTER, FF_U64, failed_req, STATS_PX_CAP_LF__, "Total number of invalid requests since process started"), - [ST_I_PX_ECON] = ME_NEW_BE("econ", NULL, FN_COUNTER, FF_U64, failed_conns, STATS_PX_CAP___BS, "Total number of failed connections to server since the worker process started"), - [ST_I_PX_ERESP] = ME_NEW_BE("eresp", NULL, FN_COUNTER, FF_U64, failed_resp, STATS_PX_CAP___BS, "Total number of invalid responses since the worker process started"), - [ST_I_PX_WRETR] = ME_NEW_BE("wretr", NULL, FN_COUNTER, FF_U64, retries, STATS_PX_CAP___BS, "Total number of server connection retries since the worker process started"), - [ST_I_PX_WREDIS] = ME_NEW_BE("wredis", NULL, FN_COUNTER, FF_U64, redispatches, STATS_PX_CAP___BS, "Total number of server redispatches due to connection failures since the worker process started"), - [ST_I_PX_STATUS] = { .name = "status", .desc = "Frontend/listen status: OPEN/WAITING/FULL/STOP; backend: UP/DOWN; server: last check status", .cap = STATS_PX_CAP_LFBS }, - [ST_I_PX_WEIGHT] = { .name = "weight", .desc = "Server's effective weight, or sum of active servers' effective weights for a backend", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_ACT] = { .name = "act", .desc = "Total number of active UP servers with a non-zero weight", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_BCK] = { .name = "bck", .desc = "Total number of backup UP servers with a non-zero weight", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_CHKFAIL] = ME_NEW_BE("chkfail", NULL, FN_COUNTER, FF_U64, failed_checks, STATS_PX_CAP____S, "Total number of failed individual health checks per server/backend, since the worker process started"), - [ST_I_PX_CHKDOWN] = ME_NEW_BE("chkdown", NULL, FN_COUNTER, FF_U64, down_trans, STATS_PX_CAP___BS, "Total number of failed checks causing UP to DOWN server transitions, per server/backend, since the worker process started"), - [ST_I_PX_LASTCHG] = ME_NEW_BE("lastchg", NULL, FN_AGE, FF_U32, last_change, STATS_PX_CAP___BS, "How long ago the last server state changed, in seconds"), - [ST_I_PX_DOWNTIME] = { .name = "downtime", .desc = "Total time spent in DOWN state, for server or backend", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_QLIMIT] = { .name = "qlimit", .desc = "Limit on the number of connections in queue, for servers only (maxqueue argument)", .cap = STATS_PX_CAP____S }, - [ST_I_PX_PID] = { .name = "pid", .desc = "Relative worker process number (1)" }, - [ST_I_PX_IID] = { .name = "iid", .desc = "Frontend or Backend numeric identifier ('id' setting)" }, - [ST_I_PX_SID] = { .name = "sid", .desc = "Server numeric identifier ('id' setting)" }, - [ST_I_PX_THROTTLE] = { .name = "throttle", .desc = "Throttling ratio applied to a server's maxconn and weight during the slowstart period (0 to 100%)", .cap = STATS_PX_CAP____S }, - [ST_I_PX_LBTOT] = ME_NEW_BE("lbtot", NULL, FN_COUNTER, FF_U64, cum_lbconn, STATS_PX_CAP___BS, "Total number of requests routed by load balancing since the worker process started (ignores queue pop and stickiness)"), - [ST_I_PX_TRACKED] = { .name = "tracked", .desc = "Name of the other server this server tracks for its state" }, - [ST_I_PX_TYPE] = { .name = "type", .desc = "Type of the object (Listener, Frontend, Backend, Server)" }, - [ST_I_PX_RATE] = ME_NEW_PX("rate", NULL, FN_RATE, FF_U32, sess_per_sec, STATS_PX_CAP__FBS, "Total number of sessions processed by this object over the last second (sessions for listeners/frontends, requests for backends/servers)"), - [ST_I_PX_RATE_LIM] = { .name = "rate_lim", .desc = "Limit on the number of sessions accepted in a second (frontend only, 'rate-limit sessions' setting)", .cap = STATS_PX_CAP__F__ }, - [ST_I_PX_RATE_MAX] = { .name = "rate_max", .desc = "Highest value of sessions per second observed since the worker process started", .cap = STATS_PX_CAP__FBS }, - [ST_I_PX_CHECK_STATUS] = { .name = "check_status", .desc = "Status report of the server's latest health check, prefixed with '*' if a check is currently in progress", .cap = STATS_PX_CAP____S }, - [ST_I_PX_CHECK_CODE] = { .name = "check_code", .desc = "HTTP/SMTP/LDAP status code reported by the latest server health check", .cap = STATS_PX_CAP____S }, - [ST_I_PX_CHECK_DURATION] = { .name = "check_duration", .desc = "Total duration of the latest server health check, in milliseconds", .cap = STATS_PX_CAP____S }, - [ST_I_PX_HRSP_1XX] = ME_NEW_PX("hrsp_1xx", NULL, FN_COUNTER, FF_U64, p.http.rsp[1], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 100-199 returned by this object since the worker process started"), - [ST_I_PX_HRSP_2XX] = ME_NEW_PX("hrsp_2xx", NULL, FN_COUNTER, FF_U64, p.http.rsp[2], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 200-299 returned by this object since the worker process started"), - [ST_I_PX_HRSP_3XX] = ME_NEW_PX("hrsp_3xx", NULL, FN_COUNTER, FF_U64, p.http.rsp[3], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 300-399 returned by this object since the worker process started"), - [ST_I_PX_HRSP_4XX] = ME_NEW_PX("hrsp_4xx", NULL, FN_COUNTER, FF_U64, p.http.rsp[4], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 400-499 returned by this object since the worker process started"), - [ST_I_PX_HRSP_5XX] = ME_NEW_PX("hrsp_5xx", NULL, FN_COUNTER, FF_U64, p.http.rsp[5], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 500-599 returned by this object since the worker process started"), - [ST_I_PX_HRSP_OTHER] = ME_NEW_PX("hrsp_other", NULL, FN_COUNTER, FF_U64, p.http.rsp[0], STATS_PX_CAP__FBS, "Total number of HTTP responses with status <100, >599 returned by this object since the worker process started (error -1 included)"), - [ST_I_PX_HANAFAIL] = ME_NEW_BE("hanafail", NULL, FN_COUNTER, FF_U64, failed_hana, STATS_PX_CAP____S, "Total number of failed checks caused by an 'on-error' directive after an 'observe' condition matched"), - [ST_I_PX_REQ_RATE] = ME_NEW_FE("req_rate", NULL, FN_RATE, FF_U32, req_per_sec, STATS_PX_CAP__F__, "Number of HTTP requests processed over the last second on this object"), - [ST_I_PX_REQ_RATE_MAX] = { .name = "req_rate_max", .desc = "Highest value of http requests observed since the worker process started", .cap = STATS_PX_CAP__F__ }, + [ST_I_PX_PXNAME] = { .name = "pxname", .alt_name = NULL, .desc = "Proxy name" }, + [ST_I_PX_SVNAME] = { .name = "svname", .alt_name = NULL, .desc = "Server name" }, + [ST_I_PX_QCUR] = { .name = "qcur", .alt_name = "current_queue", .desc = "Number of current queued connections", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_QMAX] = { .name = "qmax", .alt_name = "max_queue", .desc = "Highest value of queued connections encountered since process started", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_SCUR] = { .name = "scur", .alt_name = "current_sessions", .desc = "Number of current sessions on the frontend, backend or server", .cap = STATS_PX_CAP_LFBS}, + [ST_I_PX_SMAX] = { .name = "smax", .alt_name = "max_sessions", .desc = "Highest value of current sessions encountered since process started", .cap = STATS_PX_CAP_LFBS }, + [ST_I_PX_SLIM] = { .name = "slim", .alt_name = "limit_sessions", .desc = "Frontend/listener/server's maxconn, backend's fullconn", .cap = STATS_PX_CAP_LFBS }, + [ST_I_PX_STOT] = ME_NEW_PX("stot", "sessions_total", FN_COUNTER, FF_U64, cum_sess, STATS_PX_CAP_LFBS, "Total number of sessions since process started"), + [ST_I_PX_BIN] = ME_NEW_PX("bin", "bytes_in_total", FN_COUNTER, FF_U64, bytes_in, STATS_PX_CAP_LFBS, "Total number of request bytes since process started"), + [ST_I_PX_BOUT] = ME_NEW_PX("bout", "bytes_out_total", FN_COUNTER, FF_U64, bytes_out, STATS_PX_CAP_LFBS, "Total number of response bytes since process started"), + [ST_I_PX_DREQ] = ME_NEW_PX("dreq", "requests_denied_total", FN_COUNTER, FF_U64, denied_req, STATS_PX_CAP_LFB_, "Total number of denied requests since process started"), + [ST_I_PX_DRESP] = ME_NEW_PX("dresp", "responses_denied_total", FN_COUNTER, FF_U64, denied_resp, STATS_PX_CAP_LFBS, "Total number of denied responses since process started"), + [ST_I_PX_EREQ] = ME_NEW_FE("ereq", "request_errors_total", FN_COUNTER, FF_U64, failed_req, STATS_PX_CAP_LF__, "Total number of invalid requests since process started"), + [ST_I_PX_ECON] = ME_NEW_BE("econ", "connection_errors_total", FN_COUNTER, FF_U64, failed_conns, STATS_PX_CAP___BS, "Total number of failed connections to server since the worker process started"), + [ST_I_PX_ERESP] = ME_NEW_BE("eresp", "response_errors_total", FN_COUNTER, FF_U64, failed_resp, STATS_PX_CAP___BS, "Total number of invalid responses since the worker process started"), + [ST_I_PX_WRETR] = ME_NEW_BE("wretr", "retry_warnings_total", FN_COUNTER, FF_U64, retries, STATS_PX_CAP___BS, "Total number of server connection retries since the worker process started"), + [ST_I_PX_WREDIS] = ME_NEW_BE("wredis", "redispatch_warnings_total", FN_COUNTER, FF_U64, redispatches, STATS_PX_CAP___BS, "Total number of server redispatches due to connection failures since the worker process started"), + [ST_I_PX_STATUS] = { .name = "status", .alt_name = "status", .desc = "Frontend/listen status: OPEN/WAITING/FULL/STOP; backend: UP/DOWN; server: last check status", .cap = STATS_PX_CAP_LFBS }, + [ST_I_PX_WEIGHT] = { .name = "weight", .alt_name = "weight", .desc = "Server's effective weight, or sum of active servers' effective weights for a backend", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_ACT] = { .name = "act", .alt_name = "active_servers", .desc = "Total number of active UP servers with a non-zero weight", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_BCK] = { .name = "bck", .alt_name = "backup_servers", .desc = "Total number of backup UP servers with a non-zero weight", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_CHKFAIL] = ME_NEW_BE("chkfail", "check_failures_total", FN_COUNTER, FF_U64, failed_checks, STATS_PX_CAP____S, "Total number of failed individual health checks per server/backend, since the worker process started"), + [ST_I_PX_CHKDOWN] = ME_NEW_BE("chkdown", "check_up_down_total", FN_COUNTER, FF_U64, down_trans, STATS_PX_CAP___BS, "Total number of failed checks causing UP to DOWN server transitions, per server/backend, since the worker process started"), + [ST_I_PX_LASTCHG] = ME_NEW_BE("lastchg", "check_last_change_seconds", FN_AGE, FF_U32, last_change, STATS_PX_CAP___BS, "How long ago the last server state changed, in seconds"), + [ST_I_PX_DOWNTIME] = { .name = "downtime", .alt_name = "downtime_seconds_total", .desc = "Total time spent in DOWN state, for server or backend", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_QLIMIT] = { .name = "qlimit", .alt_name = "queue_limit", .desc = "Limit on the number of connections in queue, for servers only (maxqueue argument)", .cap = STATS_PX_CAP____S }, + [ST_I_PX_PID] = { .name = "pid", .alt_name = NULL, .desc = "Relative worker process number (1)" }, + [ST_I_PX_IID] = { .name = "iid", .alt_name = NULL, .desc = "Frontend or Backend numeric identifier ('id' setting)" }, + [ST_I_PX_SID] = { .name = "sid", .alt_name = NULL, .desc = "Server numeric identifier ('id' setting)" }, + [ST_I_PX_THROTTLE] = { .name = "throttle", .alt_name = "current_throttle", .desc = "Throttling ratio applied to a server's maxconn and weight during the slowstart period (0 to 100%)", .cap = STATS_PX_CAP____S }, + [ST_I_PX_LBTOT] = ME_NEW_BE("lbtot", "loadbalanced_total", FN_COUNTER, FF_U64, cum_lbconn, STATS_PX_CAP___BS, "Total number of requests routed by load balancing since the worker process started (ignores queue pop and stickiness)"), + [ST_I_PX_TRACKED] = { .name = "tracked", .alt_name = NULL, .desc = "Name of the other server this server tracks for its state" }, + [ST_I_PX_TYPE] = { .name = "type", .alt_name = NULL, .desc = "Type of the object (Listener, Frontend, Backend, Server)" }, + [ST_I_PX_RATE] = ME_NEW_PX("rate", NULL, FN_RATE, FF_U32, sess_per_sec, STATS_PX_CAP__FBS, "Total number of sessions processed by this object over the last second (sessions for listeners/frontends, requests for backends/servers)"), + [ST_I_PX_RATE_LIM] = { .name = "rate_lim", .alt_name = "limit_session_rate", .desc = "Limit on the number of sessions accepted in a second (frontend only, 'rate-limit sessions' setting)", .cap = STATS_PX_CAP__F__ }, + [ST_I_PX_RATE_MAX] = { .name = "rate_max", .alt_name = "max_session_rate", .desc = "Highest value of sessions per second observed since the worker process started", .cap = STATS_PX_CAP__FBS }, + [ST_I_PX_CHECK_STATUS] = { .name = "check_status", .alt_name = "check_status", .desc = "Status report of the server's latest health check, prefixed with '*' if a check is currently in progress", .cap = STATS_PX_CAP____S }, + [ST_I_PX_CHECK_CODE] = { .name = "check_code", .alt_name = "check_code", .desc = "HTTP/SMTP/LDAP status code reported by the latest server health check", .cap = STATS_PX_CAP____S }, + [ST_I_PX_CHECK_DURATION] = { .name = "check_duration", .alt_name = "check_duration_seconds", .desc = "Total duration of the latest server health check, in milliseconds", .cap = STATS_PX_CAP____S }, + [ST_I_PX_HRSP_1XX] = ME_NEW_PX("hrsp_1xx", "http_responses_total", FN_COUNTER, FF_U64, p.http.rsp[1], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 100-199 returned by this object since the worker process started"), + [ST_I_PX_HRSP_2XX] = ME_NEW_PX("hrsp_2xx", "http_responses_total", FN_COUNTER, FF_U64, p.http.rsp[2], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 200-299 returned by this object since the worker process started"), + [ST_I_PX_HRSP_3XX] = ME_NEW_PX("hrsp_3xx", "http_responses_total", FN_COUNTER, FF_U64, p.http.rsp[3], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 300-399 returned by this object since the worker process started"), + [ST_I_PX_HRSP_4XX] = ME_NEW_PX("hrsp_4xx", "http_responses_total", FN_COUNTER, FF_U64, p.http.rsp[4], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 400-499 returned by this object since the worker process started"), + [ST_I_PX_HRSP_5XX] = ME_NEW_PX("hrsp_5xx", "http_responses_total", FN_COUNTER, FF_U64, p.http.rsp[5], STATS_PX_CAP__FBS, "Total number of HTTP responses with status 500-599 returned by this object since the worker process started"), + [ST_I_PX_HRSP_OTHER] = ME_NEW_PX("hrsp_other", "http_responses_total", FN_COUNTER, FF_U64, p.http.rsp[0], STATS_PX_CAP__FBS, "Total number of HTTP responses with status <100, >599 returned by this object since the worker process started (error -1 included)"), + [ST_I_PX_HANAFAIL] = ME_NEW_BE("hanafail", NULL, FN_COUNTER, FF_U64, failed_hana, STATS_PX_CAP____S, "Total number of failed checks caused by an 'on-error' directive after an 'observe' condition matched"), + [ST_I_PX_REQ_RATE] = ME_NEW_FE("req_rate", NULL, FN_RATE, FF_U32, req_per_sec, STATS_PX_CAP__F__, "Number of HTTP requests processed over the last second on this object"), + [ST_I_PX_REQ_RATE_MAX] = { .name = "req_rate_max", .alt_name = "http_requests_rate_max", .desc = "Highest value of http requests observed since the worker process started", .cap = STATS_PX_CAP__F__ }, /* Note: ST_I_PX_REQ_TOT is also diplayed on frontend but does not uses a raw counter value, see me_generate_field() for details. */ - [ST_I_PX_REQ_TOT] = ME_NEW_BE("req_tot", NULL, FN_COUNTER, FF_U64, p.http.cum_req, STATS_PX_CAP__FBS, "Total number of HTTP requests processed by this object since the worker process started"), - [ST_I_PX_CLI_ABRT] = ME_NEW_BE("cli_abrt", NULL, FN_COUNTER, FF_U64, cli_aborts, STATS_PX_CAP___BS, "Total number of requests or connections aborted by the client since the worker process started"), - [ST_I_PX_SRV_ABRT] = ME_NEW_BE("srv_abrt", NULL, FN_COUNTER, FF_U64, srv_aborts, STATS_PX_CAP___BS, "Total number of requests or connections aborted by the server since the worker process started"), - [ST_I_PX_COMP_IN] = ME_NEW_PX("comp_in", NULL, FN_COUNTER, FF_U64, comp_in[COMP_DIR_RES], STATS_PX_CAP__FB_, "Total number of bytes submitted to the HTTP compressor for this object since the worker process started"), - [ST_I_PX_COMP_OUT] = ME_NEW_PX("comp_out", NULL, FN_COUNTER, FF_U64, comp_out[COMP_DIR_RES], STATS_PX_CAP__FB_, "Total number of bytes emitted by the HTTP compressor for this object since the worker process started"), - [ST_I_PX_COMP_BYP] = ME_NEW_PX("comp_byp", NULL, FN_COUNTER, FF_U64, comp_byp[COMP_DIR_RES], STATS_PX_CAP__FB_, "Total number of bytes that bypassed HTTP compression for this object since the worker process started (CPU/memory/bandwidth limitation)"), - [ST_I_PX_COMP_RSP] = ME_NEW_PX("comp_rsp", NULL, FN_COUNTER, FF_U64, p.http.comp_rsp, STATS_PX_CAP__FB_, "Total number of HTTP responses that were compressed for this object since the worker process started"), - [ST_I_PX_LASTSESS] = ME_NEW_BE("lastsess", NULL, FN_AGE, FF_S32, last_sess, STATS_PX_CAP___BS, "How long ago some traffic was seen on this object on this worker process, in seconds"), - [ST_I_PX_LAST_CHK] = { .name = "last_chk", .desc = "Short description of the latest health check report for this server (see also check_desc)" }, - [ST_I_PX_LAST_AGT] = { .name = "last_agt", .desc = "Short description of the latest agent check report for this server (see also agent_desc)" }, - [ST_I_PX_QTIME] = { .name = "qtime", .desc = "Time spent in the queue, in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_CTIME] = { .name = "ctime", .desc = "Time spent waiting for a connection to complete, in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_RTIME] = { .name = "rtime", .desc = "Time spent waiting for a server response, in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_TTIME] = { .name = "ttime", .desc = "Total request+response time (request+queue+connect+response+processing), in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_AGENT_STATUS] = { .name = "agent_status", .desc = "Status report of the server's latest agent check, prefixed with '*' if a check is currently in progress" }, - [ST_I_PX_AGENT_CODE] = { .name = "agent_code", .desc = "Status code reported by the latest server agent check" }, - [ST_I_PX_AGENT_DURATION] = { .name = "agent_duration", .desc = "Total duration of the latest server agent check, in milliseconds" }, - [ST_I_PX_CHECK_DESC] = { .name = "check_desc", .desc = "Textual description of the latest health check report for this server" }, - [ST_I_PX_AGENT_DESC] = { .name = "agent_desc", .desc = "Textual description of the latest agent check report for this server" }, - [ST_I_PX_CHECK_RISE] = { .name = "check_rise", .desc = "Number of successful health checks before declaring a server UP (server 'rise' setting)" }, - [ST_I_PX_CHECK_FALL] = { .name = "check_fall", .desc = "Number of failed health checks before declaring a server DOWN (server 'fall' setting)" }, - [ST_I_PX_CHECK_HEALTH] = { .name = "check_health", .desc = "Current server health check level (0..fall-1=DOWN, fall..rise-1=UP)" }, - [ST_I_PX_AGENT_RISE] = { .name = "agent_rise", .desc = "Number of successful agent checks before declaring a server UP (server 'rise' setting)" }, - [ST_I_PX_AGENT_FALL] = { .name = "agent_fall", .desc = "Number of failed agent checks before declaring a server DOWN (server 'fall' setting)" }, - [ST_I_PX_AGENT_HEALTH] = { .name = "agent_health", .desc = "Current server agent check level (0..fall-1=DOWN, fall..rise-1=UP)" }, - [ST_I_PX_ADDR] = { .name = "addr", .desc = "Server's address:port, shown only if show-legends is set, or at levels oper/admin for the CLI" }, - [ST_I_PX_COOKIE] = { .name = "cookie", .desc = "Backend's cookie name or Server's cookie value, shown only if show-legends is set, or at levels oper/admin for the CLI" }, - [ST_I_PX_MODE] = { .name = "mode", .desc = "'mode' setting (tcp/http/health/cli/spop)" }, - [ST_I_PX_ALGO] = { .name = "algo", .desc = "Backend's load balancing algorithm, shown only if show-legends is set, or at levels oper/admin for the CLI" }, - [ST_I_PX_CONN_RATE] = ME_NEW_FE("conn_rate", NULL, FN_RATE, FF_U32, conn_per_sec, STATS_PX_CAP__F__, "Number of new connections accepted over the last second on the frontend for this worker process"), - [ST_I_PX_CONN_RATE_MAX] = { .name = "conn_rate_max", .desc = "Highest value of connections per second observed since the worker process started", .cap = STATS_PX_CAP__F__ }, - [ST_I_PX_CONN_TOT] = ME_NEW_FE("conn_tot", NULL, FN_COUNTER, FF_U64, cum_conn, STATS_PX_CAP_LF__, "Total number of new connections accepted on this frontend since the worker process started"), - [ST_I_PX_INTERCEPTED] = ME_NEW_FE("intercepted", NULL, FN_COUNTER, FF_U64, intercepted_req, STATS_PX_CAP__F__, "Total number of HTTP requests intercepted on the frontend (redirects/stats/services) since the worker process started"), - [ST_I_PX_DCON] = ME_NEW_FE("dcon", NULL, FN_COUNTER, FF_U64, denied_conn, STATS_PX_CAP_LF__, "Total number of incoming connections blocked on a listener/frontend by a tcp-request connection rule since the worker process started"), - [ST_I_PX_DSES] = ME_NEW_FE("dses", NULL, FN_COUNTER, FF_U64, denied_sess, STATS_PX_CAP_LF__, "Total number of incoming sessions blocked on a listener/frontend by a tcp-request connection rule since the worker process started"), - [ST_I_PX_WREW] = ME_NEW_PX("wrew", NULL, FN_COUNTER, FF_U64, failed_rewrites, STATS_PX_CAP_LFBS, "Total number of failed HTTP header rewrites since the worker process started"), - [ST_I_PX_CONNECT] = ME_NEW_BE("connect", NULL, FN_COUNTER, FF_U64, connect, STATS_PX_CAP___BS, "Total number of outgoing connection attempts on this backend/server since the worker process started"), - [ST_I_PX_REUSE] = ME_NEW_BE("reuse", NULL, FN_COUNTER, FF_U64, reuse, STATS_PX_CAP___BS, "Total number of reused connection on this backend/server since the worker process started"), - [ST_I_PX_CACHE_LOOKUPS] = ME_NEW_PX("cache_lookups", NULL, FN_COUNTER, FF_U64, p.http.cache_lookups, STATS_PX_CAP__FB_, "Total number of HTTP requests looked up in the cache on this frontend/backend since the worker process started"), - [ST_I_PX_CACHE_HITS] = ME_NEW_PX("cache_hits", NULL, FN_COUNTER, FF_U64, p.http.cache_hits, STATS_PX_CAP__FB_, "Total number of HTTP requests not found in the cache on this frontend/backend since the worker process started"), - [ST_I_PX_SRV_ICUR] = { .name = "srv_icur", .desc = "Current number of idle connections available for reuse on this server", .cap = STATS_PX_CAP____S }, - [ST_I_PX_SRV_ILIM] = { .name = "src_ilim", .desc = "Limit on the number of available idle connections on this server (server 'pool_max_conn' directive)", .cap = STATS_PX_CAP____S }, - [ST_I_PX_QT_MAX] = { .name = "qtime_max", .desc = "Maximum observed time spent in the queue, in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_CT_MAX] = { .name = "ctime_max", .desc = "Maximum observed time spent waiting for a connection to complete, in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_RT_MAX] = { .name = "rtime_max", .desc = "Maximum observed time spent waiting for a server response, in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_TT_MAX] = { .name = "ttime_max", .desc = "Maximum observed total request+response time (request+queue+connect+response+processing), in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_EINT] = ME_NEW_PX("eint", NULL, FN_COUNTER, FF_U64, internal_errors, STATS_PX_CAP_LFBS, "Total number of internal errors since process started"), - [ST_I_PX_IDLE_CONN_CUR] = { .name = "idle_conn_cur", .desc = "Current number of unsafe idle connections", .cap = STATS_PX_CAP____S}, - [ST_I_PX_SAFE_CONN_CUR] = { .name = "safe_conn_cur", .desc = "Current number of safe idle connections", .cap = STATS_PX_CAP____S}, - [ST_I_PX_USED_CONN_CUR] = { .name = "used_conn_cur", .desc = "Current number of connections in use", .cap = STATS_PX_CAP____S}, - [ST_I_PX_NEED_CONN_EST] = { .name = "need_conn_est", .desc = "Estimated needed number of connections", .cap = STATS_PX_CAP____S}, - [ST_I_PX_UWEIGHT] = { .name = "uweight", .desc = "Server's user weight, or sum of active servers' user weights for a backend", .cap = STATS_PX_CAP___BS }, - [ST_I_PX_AGG_SRV_CHECK_STATUS] = { .name = "agg_server_check_status", .desc = "[DEPRECATED] Backend's aggregated gauge of servers' status", .cap = STATS_PX_CAP___B_ }, - [ST_I_PX_AGG_SRV_STATUS ] = { .name = "agg_server_status", .desc = "Backend's aggregated gauge of servers' status", .cap = STATS_PX_CAP___B_ }, - [ST_I_PX_AGG_CHECK_STATUS] = { .name = "agg_check_status", .desc = "Backend's aggregated gauge of servers' state check status", .cap = STATS_PX_CAP___B_ }, - [ST_I_PX_SRID] = { .name = "srid", .desc = "Server id revision, to prevent server id reuse mixups" }, - [ST_I_PX_SESS_OTHER] = { .name = "sess_other", .desc = "Total number of sessions other than HTTP since process started" }, - [ST_I_PX_H1SESS] = ME_NEW_FE("h1sess", NULL, FN_COUNTER, FF_U64, cum_sess_ver[0], STATS_PX_CAP__F__, "Total number of HTTP/1 sessions since process started"), - [ST_I_PX_H2SESS] = ME_NEW_FE("h2sess", NULL, FN_COUNTER, FF_U64, cum_sess_ver[1], STATS_PX_CAP__F__, "Total number of HTTP/2 sessions since process started"), - [ST_I_PX_H3SESS] = ME_NEW_FE("h3sess", NULL, FN_COUNTER, FF_U64, cum_sess_ver[2], STATS_PX_CAP__F__, "Total number of HTTP/3 sessions since process started"), - [ST_I_PX_REQ_OTHER] = ME_NEW_FE("req_other", NULL, FN_COUNTER, FF_U64, p.http.cum_req[0], STATS_PX_CAP__F__, "Total number of sessions other than HTTP processed by this object since the worker process started"), - [ST_I_PX_H1REQ] = ME_NEW_FE("h1req", NULL, FN_COUNTER, FF_U64, p.http.cum_req[1], STATS_PX_CAP__F__, "Total number of HTTP/1 sessions processed by this object since the worker process started"), - [ST_I_PX_H2REQ] = ME_NEW_FE("h2req", NULL, FN_COUNTER, FF_U64, p.http.cum_req[2], STATS_PX_CAP__F__, "Total number of hTTP/2 sessions processed by this object since the worker process started"), - [ST_I_PX_H3REQ] = ME_NEW_FE("h3req", NULL, FN_COUNTER, FF_U64, p.http.cum_req[3], STATS_PX_CAP__F__, "Total number of HTTP/3 sessions processed by this object since the worker process started"), - [ST_I_PX_PROTO] = { .name = "proto", .desc = "Protocol" }, + [ST_I_PX_REQ_TOT] = ME_NEW_BE("req_tot", "http_requests_total", FN_COUNTER, FF_U64, p.http.cum_req, STATS_PX_CAP__FBS, "Total number of HTTP requests processed by this object since the worker process started"), + [ST_I_PX_CLI_ABRT] = ME_NEW_BE("cli_abrt", "client_aborts_total", FN_COUNTER, FF_U64, cli_aborts, STATS_PX_CAP___BS, "Total number of requests or connections aborted by the client since the worker process started"), + [ST_I_PX_SRV_ABRT] = ME_NEW_BE("srv_abrt", "server_aborts_total", FN_COUNTER, FF_U64, srv_aborts, STATS_PX_CAP___BS, "Total number of requests or connections aborted by the server since the worker process started"), + [ST_I_PX_COMP_IN] = ME_NEW_PX("comp_in", "http_comp_bytes_in_total", FN_COUNTER, FF_U64, comp_in[COMP_DIR_RES], STATS_PX_CAP__FB_, "Total number of bytes submitted to the HTTP compressor for this object since the worker process started"), + [ST_I_PX_COMP_OUT] = ME_NEW_PX("comp_out", "http_comp_bytes_out_total", FN_COUNTER, FF_U64, comp_out[COMP_DIR_RES], STATS_PX_CAP__FB_, "Total number of bytes emitted by the HTTP compressor for this object since the worker process started"), + [ST_I_PX_COMP_BYP] = ME_NEW_PX("comp_byp", "http_comp_bytes_bypassed_total", FN_COUNTER, FF_U64, comp_byp[COMP_DIR_RES], STATS_PX_CAP__FB_, "Total number of bytes that bypassed HTTP compression for this object since the worker process started (CPU/memory/bandwidth limitation)"), + [ST_I_PX_COMP_RSP] = ME_NEW_PX("comp_rsp", "http_comp_responses_total", FN_COUNTER, FF_U64, p.http.comp_rsp, STATS_PX_CAP__FB_, "Total number of HTTP responses that were compressed for this object since the worker process started"), + [ST_I_PX_LASTSESS] = ME_NEW_BE("lastsess", "last_session_seconds", FN_AGE, FF_S32, last_sess, STATS_PX_CAP___BS, "How long ago some traffic was seen on this object on this worker process, in seconds"), + [ST_I_PX_LAST_CHK] = { .name = "last_chk", .alt_name = NULL, .desc = "Short description of the latest health check report for this server (see also check_desc)" }, + [ST_I_PX_LAST_AGT] = { .name = "last_agt", .alt_name = NULL, .desc = "Short description of the latest agent check report for this server (see also agent_desc)" }, + [ST_I_PX_QTIME] = { .name = "qtime", .alt_name = "queue_time_average_seconds", .desc = "Time spent in the queue, in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_CTIME] = { .name = "ctime", .alt_name = "connect_time_average_seconds", .desc = "Time spent waiting for a connection to complete, in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_RTIME] = { .name = "rtime", .alt_name = "response_time_average_seconds", .desc = "Time spent waiting for a server response, in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_TTIME] = { .name = "ttime", .alt_name = "total_time_average_seconds", .desc = "Total request+response time (request+queue+connect+response+processing), in milliseconds, averaged over the 1024 last requests (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_AGENT_STATUS] = { .name = "agent_status", .alt_name = NULL, .desc = "Status report of the server's latest agent check, prefixed with '*' if a check is currently in progress" }, + [ST_I_PX_AGENT_CODE] = { .name = "agent_code", .alt_name = NULL, .desc = "Status code reported by the latest server agent check" }, + [ST_I_PX_AGENT_DURATION] = { .name = "agent_duration", .alt_name = NULL, .desc = "Total duration of the latest server agent check, in milliseconds" }, + [ST_I_PX_CHECK_DESC] = { .name = "check_desc", .alt_name = NULL, .desc = "Textual description of the latest health check report for this server" }, + [ST_I_PX_AGENT_DESC] = { .name = "agent_desc", .alt_name = NULL, .desc = "Textual description of the latest agent check report for this server" }, + [ST_I_PX_CHECK_RISE] = { .name = "check_rise", .alt_name = NULL, .desc = "Number of successful health checks before declaring a server UP (server 'rise' setting)" }, + [ST_I_PX_CHECK_FALL] = { .name = "check_fall", .alt_name = NULL, .desc = "Number of failed health checks before declaring a server DOWN (server 'fall' setting)" }, + [ST_I_PX_CHECK_HEALTH] = { .name = "check_health", .alt_name = NULL, .desc = "Current server health check level (0..fall-1=DOWN, fall..rise-1=UP)" }, + [ST_I_PX_AGENT_RISE] = { .name = "agent_rise", .alt_name = NULL, .desc = "Number of successful agent checks before declaring a server UP (server 'rise' setting)" }, + [ST_I_PX_AGENT_FALL] = { .name = "agent_fall", .alt_name = NULL, .desc = "Number of failed agent checks before declaring a server DOWN (server 'fall' setting)" }, + [ST_I_PX_AGENT_HEALTH] = { .name = "agent_health", .alt_name = NULL, .desc = "Current server agent check level (0..fall-1=DOWN, fall..rise-1=UP)" }, + [ST_I_PX_ADDR] = { .name = "addr", .alt_name = NULL, .desc = "Server's address:port, shown only if show-legends is set, or at levels oper/admin for the CLI" }, + [ST_I_PX_COOKIE] = { .name = "cookie", .alt_name = NULL, .desc = "Backend's cookie name or Server's cookie value, shown only if show-legends is set, or at levels oper/admin for the CLI" }, + [ST_I_PX_MODE] = { .name = "mode", .alt_name = NULL, .desc = "'mode' setting (tcp/http/health/cli/spop)" }, + [ST_I_PX_ALGO] = { .name = "algo", .alt_name = NULL, .desc = "Backend's load balancing algorithm, shown only if show-legends is set, or at levels oper/admin for the CLI" }, + [ST_I_PX_CONN_RATE] = ME_NEW_FE("conn_rate", NULL, FN_RATE, FF_U32, conn_per_sec, STATS_PX_CAP__F__, "Number of new connections accepted over the last second on the frontend for this worker process"), + [ST_I_PX_CONN_RATE_MAX] = { .name = "conn_rate_max", .alt_name = "connections_rate_max", .desc = "Highest value of connections per second observed since the worker process started", .cap = STATS_PX_CAP__F__ }, + [ST_I_PX_CONN_TOT] = ME_NEW_FE("conn_tot", "connections_total", FN_COUNTER, FF_U64, cum_conn, STATS_PX_CAP_LF__, "Total number of new connections accepted on this frontend since the worker process started"), + [ST_I_PX_INTERCEPTED] = ME_NEW_FE("intercepted", "intercepted_requests_total", FN_COUNTER, FF_U64, intercepted_req, STATS_PX_CAP__F__, "Total number of HTTP requests intercepted on the frontend (redirects/stats/services) since the worker process started"), + [ST_I_PX_DCON] = ME_NEW_FE("dcon", "denied_connections_total", FN_COUNTER, FF_U64, denied_conn, STATS_PX_CAP_LF__, "Total number of incoming connections blocked on a listener/frontend by a tcp-request connection rule since the worker process started"), + [ST_I_PX_DSES] = ME_NEW_FE("dses", "denied_sessions_total", FN_COUNTER, FF_U64, denied_sess, STATS_PX_CAP_LF__, "Total number of incoming sessions blocked on a listener/frontend by a tcp-request connection rule since the worker process started"), + [ST_I_PX_WREW] = ME_NEW_PX("wrew", "failed_header_rewriting_total", FN_COUNTER, FF_U64, failed_rewrites, STATS_PX_CAP_LFBS, "Total number of failed HTTP header rewrites since the worker process started"), + [ST_I_PX_CONNECT] = ME_NEW_BE("connect", "connection_attempts_total", FN_COUNTER, FF_U64, connect, STATS_PX_CAP___BS, "Total number of outgoing connection attempts on this backend/server since the worker process started"), + [ST_I_PX_REUSE] = ME_NEW_BE("reuse", "connection_reuses_total", FN_COUNTER, FF_U64, reuse, STATS_PX_CAP___BS, "Total number of reused connection on this backend/server since the worker process started"), + [ST_I_PX_CACHE_LOOKUPS] = ME_NEW_PX("cache_lookups", "http_cache_lookups_total", FN_COUNTER, FF_U64, p.http.cache_lookups, STATS_PX_CAP__FB_, "Total number of HTTP requests looked up in the cache on this frontend/backend since the worker process started"), + [ST_I_PX_CACHE_HITS] = ME_NEW_PX("cache_hits", "http_cache_hits_total", FN_COUNTER, FF_U64, p.http.cache_hits, STATS_PX_CAP__FB_, "Total number of HTTP requests not found in the cache on this frontend/backend since the worker process started"), + [ST_I_PX_SRV_ICUR] = { .name = "srv_icur", .alt_name = "idle_connections_current", .desc = "Current number of idle connections available for reuse on this server", .cap = STATS_PX_CAP____S }, + [ST_I_PX_SRV_ILIM] = { .name = "src_ilim", .alt_name = "idle_connections_limit", .desc = "Limit on the number of available idle connections on this server (server 'pool_max_conn' directive)", .cap = STATS_PX_CAP____S }, + [ST_I_PX_QT_MAX] = { .name = "qtime_max", .alt_name = "max_queue_time_seconds", .desc = "Maximum observed time spent in the queue, in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_CT_MAX] = { .name = "ctime_max", .alt_name = "max_connect_time_seconds", .desc = "Maximum observed time spent waiting for a connection to complete, in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_RT_MAX] = { .name = "rtime_max", .alt_name = "max_response_time_seconds", .desc = "Maximum observed time spent waiting for a server response, in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_TT_MAX] = { .name = "ttime_max", .alt_name = "max_total_time_seconds", .desc = "Maximum observed total request+response time (request+queue+connect+response+processing), in milliseconds (backend/server)", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_EINT] = ME_NEW_PX("eint", "internal_errors_total", FN_COUNTER, FF_U64, internal_errors, STATS_PX_CAP_LFBS, "Total number of internal errors since process started"), + [ST_I_PX_IDLE_CONN_CUR] = { .name = "idle_conn_cur", .alt_name = "unsafe_idle_connections_current", .desc = "Current number of unsafe idle connections", .cap = STATS_PX_CAP____S}, + [ST_I_PX_SAFE_CONN_CUR] = { .name = "safe_conn_cur", .alt_name = "safe_idle_connections_current", .desc = "Current number of safe idle connections", .cap = STATS_PX_CAP____S}, + [ST_I_PX_USED_CONN_CUR] = { .name = "used_conn_cur", .alt_name = "used_connections_current", .desc = "Current number of connections in use", .cap = STATS_PX_CAP____S}, + [ST_I_PX_NEED_CONN_EST] = { .name = "need_conn_est", .alt_name = "need_connections_current", .desc = "Estimated needed number of connections", .cap = STATS_PX_CAP____S}, + [ST_I_PX_UWEIGHT] = { .name = "uweight", .alt_name = "uweight", .desc = "Server's user weight, or sum of active servers' user weights for a backend", .cap = STATS_PX_CAP___BS }, + [ST_I_PX_AGG_SRV_CHECK_STATUS] = { .name = "agg_server_check_status", .alt_name = "agg_server_check_status", .desc = "[DEPRECATED] Backend's aggregated gauge of servers' status", .cap = STATS_PX_CAP___B_ }, + [ST_I_PX_AGG_SRV_STATUS ] = { .name = "agg_server_status", .alt_name = "agg_server_status", .desc = "Backend's aggregated gauge of servers' status", .cap = STATS_PX_CAP___B_ }, + [ST_I_PX_AGG_CHECK_STATUS] = { .name = "agg_check_status", .alt_name = "agg_check_status", .desc = "Backend's aggregated gauge of servers' state check status", .cap = STATS_PX_CAP___B_ }, + [ST_I_PX_SRID] = { .name = "srid", .alt_name = NULL, .desc = "Server id revision, to prevent server id reuse mixups" }, + [ST_I_PX_SESS_OTHER] = { .name = "sess_other", .alt_name = NULL, .desc = "Total number of sessions other than HTTP since process started" }, + [ST_I_PX_H1SESS] = ME_NEW_FE("h1sess", NULL, FN_COUNTER, FF_U64, cum_sess_ver[0], STATS_PX_CAP__F__, "Total number of HTTP/1 sessions since process started"), + [ST_I_PX_H2SESS] = ME_NEW_FE("h2sess", NULL, FN_COUNTER, FF_U64, cum_sess_ver[1], STATS_PX_CAP__F__, "Total number of HTTP/2 sessions since process started"), + [ST_I_PX_H3SESS] = ME_NEW_FE("h3sess", NULL, FN_COUNTER, FF_U64, cum_sess_ver[2], STATS_PX_CAP__F__, "Total number of HTTP/3 sessions since process started"), + [ST_I_PX_REQ_OTHER] = ME_NEW_FE("req_other", NULL, FN_COUNTER, FF_U64, p.http.cum_req[0], STATS_PX_CAP__F__, "Total number of sessions other than HTTP processed by this object since the worker process started"), + [ST_I_PX_H1REQ] = ME_NEW_FE("h1req", NULL, FN_COUNTER, FF_U64, p.http.cum_req[1], STATS_PX_CAP__F__, "Total number of HTTP/1 sessions processed by this object since the worker process started"), + [ST_I_PX_H2REQ] = ME_NEW_FE("h2req", NULL, FN_COUNTER, FF_U64, p.http.cum_req[2], STATS_PX_CAP__F__, "Total number of hTTP/2 sessions processed by this object since the worker process started"), + [ST_I_PX_H3REQ] = ME_NEW_FE("h3req", NULL, FN_COUNTER, FF_U64, p.http.cum_req[3], STATS_PX_CAP__F__, "Total number of HTTP/3 sessions processed by this object since the worker process started"), + [ST_I_PX_PROTO] = { .name = "proto", .alt_name = NULL, .desc = "Protocol" }, }; /* Returns true if column at should be hidden.