mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-02-15 22:31:29 +01:00
[STATS] frontend requests were not accounted for failed requests
But failed requests were accounted for, resulting in more failures than requests.
This commit is contained in:
parent
ae52678444
commit
3e1b6d1ed0
@ -2429,8 +2429,10 @@ int http_wait_for_request(struct session *s, struct buffer *req, int an_bit)
|
||||
/*
|
||||
* First, let's catch bad requests.
|
||||
*/
|
||||
if (unlikely(msg->msg_state == HTTP_MSG_ERROR))
|
||||
if (unlikely(msg->msg_state == HTTP_MSG_ERROR)) {
|
||||
proxy_inc_fe_req_ctr(s->fe);
|
||||
goto return_bad_req;
|
||||
}
|
||||
|
||||
/* 1: Since we are in header mode, if there's no space
|
||||
* left for headers, we won't be able to free more
|
||||
@ -2441,6 +2443,7 @@ int http_wait_for_request(struct session *s, struct buffer *req, int an_bit)
|
||||
/* FIXME: check if URI is set and return Status
|
||||
* 414 Request URI too long instead.
|
||||
*/
|
||||
proxy_inc_fe_req_ctr(s->fe);
|
||||
goto return_bad_req;
|
||||
}
|
||||
|
||||
@ -2458,6 +2461,7 @@ int http_wait_for_request(struct session *s, struct buffer *req, int an_bit)
|
||||
msg->msg_state = HTTP_MSG_ERROR;
|
||||
req->analysers = 0;
|
||||
|
||||
proxy_inc_fe_req_ctr(s->fe);
|
||||
s->fe->counters.failed_req++;
|
||||
if (s->listener->counters)
|
||||
s->listener->counters->failed_req++;
|
||||
@ -2483,6 +2487,7 @@ int http_wait_for_request(struct session *s, struct buffer *req, int an_bit)
|
||||
msg->msg_state = HTTP_MSG_ERROR;
|
||||
req->analysers = 0;
|
||||
|
||||
proxy_inc_fe_req_ctr(s->fe);
|
||||
s->fe->counters.failed_req++;
|
||||
if (s->listener->counters)
|
||||
s->listener->counters->failed_req++;
|
||||
@ -2507,6 +2512,7 @@ int http_wait_for_request(struct session *s, struct buffer *req, int an_bit)
|
||||
msg->msg_state = HTTP_MSG_ERROR;
|
||||
req->analysers = 0;
|
||||
|
||||
proxy_inc_fe_req_ctr(s->fe);
|
||||
s->fe->counters.failed_req++;
|
||||
if (s->listener->counters)
|
||||
s->listener->counters->failed_req++;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user