]> err.no Git - varnish/commitdiff
Remove the SessionReuse shmem tag, we have little or no benefit from
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 15 Sep 2006 16:10:15 +0000 (16:10 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 15 Sep 2006 16:10:15 +0000 (16:10 +0000)
knowing this at the end of a request.

Instead put the address + port in the ReqStart shmtag where it does
a lot of good.

git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@994 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishd/cache_center.c
varnish-cache/bin/varnishncsa/varnishncsa.c
varnish-cache/include/shmlog_tags.h

index db4617ad147def4db4e6f398a9d0418a3cb5e915..875a706d33571061db347cc4e87ebed56365a418 100644 (file)
@@ -163,19 +163,16 @@ cnt_done(struct sess *sp)
 
        if (http_RecvPrepAgain(sp->http)) {
                VSL_stats->sess_pipeline++;
-               VSL(SLT_SessionReuse, sp->fd, "%s %s", sp->addr, sp->port);
                sp->step = STP_RECV;
                return (0);
        }
        if (sp->http->t < sp->http->v) {
                VSL_stats->sess_readahead++;
-               VSL(SLT_SessionReuse, sp->fd, "%s %s", sp->addr, sp->port);
                sp->step = STP_AGAIN;
                return (0);
        }
        if (params->session_grace == 0) {
                VSL_stats->sess_herd++;
-               VSL(SLT_SessionReuse, sp->fd, "%s %s", sp->addr, sp->port);
                sp->wrk->idle = sp->t_open.tv_sec;
                vca_return_session(sp);
                return (1);
@@ -189,11 +186,9 @@ cnt_done(struct sess *sp)
                vca_close_session(sp, "EOF");
        } else if (i == 1 && (fds[0].revents & POLLIN)) {
                VSL_stats->sess_ready++;
-               VSL(SLT_SessionReuse, sp->fd, "%s %s", sp->addr, sp->port);
                sp->step = STP_AGAIN;
                return (0);
        } else {
-               VSL(SLT_SessionReuse, sp->fd, "%s %s", sp->addr, sp->port);
                VSL_stats->sess_herd++;
        }
        sp->wrk->idle = sp->t_open.tv_sec;
@@ -677,7 +672,7 @@ cnt_recv(struct sess *sp)
        clock_gettime(CLOCK_REALTIME, &sp->t_req);
        sp->wrk->idle = sp->t_req.tv_sec;
        sp->xid = ++xids;
-       VSL(SLT_ReqStart, sp->fd, "XID %u", sp->xid);
+       VSL(SLT_ReqStart, sp->fd, "%s %s %u", sp->addr, sp->port,  sp->xid);
 
        AZ(sp->vcl);
        sp->vcl = VCL_Get();
index 2ca9199824e5a6475883fc1bb933a9cc462fe83b..f5608bafd451bd69c55588cd823d8883246e557a 100644 (file)
@@ -78,13 +78,10 @@ extended_log_format(void *priv, unsigned tag, unsigned fd, unsigned len, unsigne
        switch (tag) {
 
        case SLT_SessionOpen:
-       case SLT_SessionReuse:
+       case SLT_ReqStart:
                for (p = ptr, q = lp->df_h; *p && *p != ' ';)
                        *q++ = *p++;
                *q = '\0';
-               break;
-
-       case SLT_ReqStart:
                vsb_clear(lp->sb);
                break;
 
index c615231a20c7866b2cd2af529ae39d9532fee407..41d1d027773349e94943dfa86d70ae06aca0344f 100644 (file)
@@ -15,7 +15,6 @@ SLTM(StatAddr)
 SLTM(StatSess)
 SLTM(ReqEnd)
 SLTM(SessionOpen)
-SLTM(SessionReuse)
 SLTM(SessionClose)
 SLTM(BackendOpen)
 SLTM(BackendXID)