]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
[MINOR] swapped the queued and active sessions in the logs
authorwilly tarreau <willy@wtap.(none)>
Mon, 8 May 2006 09:52:55 +0000 (11:52 +0200)
committerwilly tarreau <willy@wtap.(none)>
Mon, 8 May 2006 09:52:55 +0000 (11:52 +0200)
It was not natural to read sess/pend/lsess/psess in the logs, so before
the feature became official, I've swapped them to read :

   pend/sess/lsess/psess

Where <pend> is the overall number of pending connections on this instance,
including all the servers queues, <sess> is the number of sessions remaining
active on the server when the log was emitted (after the end of the session,
or after parsing the request), <lsess> and <psess> are the number of active
sessions on the listener and on the process respectively.

haproxy.c

index aadd89835a10efe3e2d9201ededcbd908f34264e..3532055e9f1fc2908bfd498796df65008f83e046 100644 (file)
--- a/haproxy.c
+++ b/haproxy.c
@@ -2996,7 +2996,7 @@ void sess_log(struct session *s) {
                 sess_fin_state[(s->flags & SN_FINST_MASK) >> SN_FINST_SHIFT],
                 (p->options & PR_O_COOK_ANY) ? sess_cookie[(s->flags & SN_CK_MASK) >> SN_CK_SHIFT] : '-',
                 (p->options & PR_O_COOK_ANY) ? sess_set_cookie[(s->flags & SN_SCK_MASK) >> SN_SCK_SHIFT] : '-',
-                s->srv ? s->srv->cur_sess : 0, s->logs.queue_size,
+                s->logs.queue_size, s->srv ? s->srv->cur_sess : 0,
                 p->nbconn, actconn, tmpline);
     }
     else {
@@ -3013,7 +3013,7 @@ void sess_log(struct session *s) {
                 (p->to_log & LW_BYTES) ? "" : "+", s->logs.bytes,
                 sess_term_cond[(s->flags & SN_ERR_MASK) >> SN_ERR_SHIFT],
                 sess_fin_state[(s->flags & SN_FINST_MASK) >> SN_FINST_SHIFT],
-                s->srv ? s->srv->cur_sess : 0, s->logs.queue_size,
+                s->logs.queue_size, s->srv ? s->srv->cur_sess : 0,
                 p->nbconn, actconn);
     }