diff -Nur haproxy-1.3.12.2-orig/include/types/proxy.h haproxy-1.3.12.2-tst/include/types/proxy.h --- haproxy-1.3.12.2-orig/include/types/proxy.h 2007-09-20 08:47:17.000000000 +0200 +++ haproxy-1.3.12.2-tst/include/types/proxy.h 2007-09-23 14:41:22.000000000 +0200 @@ -123,6 +123,7 @@ unsigned int fullconn; /* #conns on backend above which servers are used at full load */ struct in_addr except_net, except_mask; /* don't x-forward-for for this address. FIXME: should support IPv6 */ unsigned failed_conns, failed_resp; /* failed connect() and responses */ + unsigned retries, redispatches; /* retried and redispatched connections */ unsigned denied_req, denied_resp; /* blocked requests/responses because of security concerns */ unsigned failed_req; /* failed requests (eg: invalid or timeout) */ long long bytes_in; /* number of bytes transferred from the client to the server */ diff -Nur haproxy-1.3.12.2-orig/include/types/server.h haproxy-1.3.12.2-tst/include/types/server.h --- haproxy-1.3.12.2-orig/include/types/server.h 2007-09-20 08:47:17.000000000 +0200 +++ haproxy-1.3.12.2-tst/include/types/server.h 2007-09-23 14:39:04.000000000 +0200 @@ -87,6 +87,7 @@ unsigned failed_checks, down_trans; /* failed checks and up-down transitions */ unsigned failed_conns, failed_resp; /* failed connect() and responses */ + unsigned retries; /* retried connections */ unsigned failed_secu; /* blocked responses because of security concerns */ unsigned cum_sess; /* cumulated number of sessions really sent to this server */ long long bytes_in; /* number of bytes transferred from the client to the server */ diff -Nur haproxy-1.3.12.2-orig/src/backend.c haproxy-1.3.12.2-tst/src/backend.c --- haproxy-1.3.12.2-orig/src/backend.c 2007-09-20 08:47:17.000000000 +0200 +++ haproxy-1.3.12.2-tst/src/backend.c 2007-09-23 14:38:25.000000000 +0200 @@ -568,6 +568,10 @@ { /* we are in front of a retryable error */ t->conn_retries--; + if (t->srv) + t->srv->retries++; + t->be->retries++; + if (t->conn_retries < 0) { /* if not retryable anymore, let's abort */ tv_eternity(&t->req->cex); @@ -638,7 +642,7 @@ if (t->srv) t->srv->failed_conns++; - t->be->failed_conns++; + t->be->redispatches++; t->flags &= ~(SN_DIRECT | SN_ASSIGNED | SN_ADDR_SET); t->srv = NULL; /* it's left to the dispatcher to choose a server */ diff -Nur haproxy-1.3.12.2-orig/src/proto_http.c haproxy-1.3.12.2-tst/src/proto_http.c --- haproxy-1.3.12.2-orig/src/proto_http.c 2007-09-20 08:47:17.000000000 +0200 +++ haproxy-1.3.12.2-tst/src/proto_http.c 2007-09-23 14:53:22.000000000 +0200 @@ -2529,7 +2529,7 @@ if (t->srv) t->srv->failed_conns++; - t->be->failed_conns++; + t->be->redispatches++; t->flags &= ~(SN_DIRECT | SN_ASSIGNED | SN_ADDR_SET); t->srv = NULL; /* it's left to the dispatcher to choose a server */ @@ -3771,15 +3771,18 @@ "" "QueueSessions" "BytesDenied" - "ErrorsServer" + "ErrorsWarnings" + "Server" "\n" "" "CurMaxCurMax" "LimitCumulInOut" - "ReqRespReqConn" - "RespStatusWeightAct" - "BckCheckDown\n" - "", + "ReqResp" + "ReqConnResp" + "RetrRedis" + "StatusWeightAct" + "BckCheckDown" + "\n", px->id); if (buffer_write_chunk(rep, &msg) != 0) @@ -3800,8 +3803,10 @@ "%lld%lld" /* denied: req, resp */ "%d%d" - /* errors : request, connect, response */ + /* errors: request, connect, response */ "%d" + /* warnings: retreies, redispaches */ + "" /* server status : reflect backend status */ "%s" /* rest of server: nothing */ @@ -3862,15 +3867,19 @@ /* denied: req, resp */ "%d" /* errors : request, connect, response */ - "%d%d\n" - "", + "%d%d" + /* warnings: retreies, redispaches */ + "%d" + "\n", (sv->state & SRV_BACKUP) ? "backup" : "active", sv_state, sv->id, sv->nbpend, sv->nbpend_max, sv->cur_sess, sv->cur_sess_max, sv->maxconn ? ultoa(sv->maxconn) : "-", sv->cum_sess, sv->bytes_in, sv->bytes_out, sv->failed_secu, - sv->failed_conns, sv->failed_resp); + sv->failed_conns, sv->failed_resp, + sv->retries + ); /* status */ chunk_printf(&msg, sizeof(trash), ""); @@ -3935,6 +3944,8 @@ "%d%d" /* errors : request, connect, response */ "%d%d\n" + /* warnings: retreies, redispaches */ + "%d%d" /* server status : reflect backend status (up/down) : we display UP * if the backend has known working servers or if it has no server at * all (eg: for stats). Tthen we display the total weight, number of @@ -3949,6 +3960,7 @@ px->bytes_in, px->bytes_out, px->denied_req, px->denied_resp, px->failed_conns, px->failed_resp, + px->retries, px->redispatches, (px->srv_map_sz > 0 || !px->srv) ? "UP" : "DOWN", px->srv_map_sz * gcd, px->srv_act, px->srv_bck);