r4302 - in branches/2.0/varnish-cache: bin/varnishd include

tfheen at projects.linpro.no tfheen at projects.linpro.no
Thu Oct 8 15:34:03 CEST 2009

Author: tfheen
Date: 2009-10-08 15:34:03 +0200 (Thu, 08 Oct 2009)
New Revision: 4302

Merge r4177: Add a stats counter for backend connections which we came too late to recycle

Modified: branches/2.0/varnish-cache/bin/varnishd/cache_backend.c
--- branches/2.0/varnish-cache/bin/varnishd/cache_backend.c	2009-10-08 13:23:36 UTC (rev 4301)
+++ branches/2.0/varnish-cache/bin/varnishd/cache_backend.c	2009-10-08 13:34:03 UTC (rev 4302)
@@ -314,11 +314,11 @@
 		if (VBE_CheckFd(vc->fd)) {
 			/* XXX locking of stats */
 			VSL_stats->backend_reuse += 1;
-			VSL_stats->backend_conn++;
 			WSP(sp, SLT_Backend, "%d %s %s",
 			    vc->fd, sp->director->vcl_name, bp->vcl_name);
 			return (vc);
+		VSL_stats->backend_toolate++;
 		sp->vbe = vc;

Modified: branches/2.0/varnish-cache/include/stat_field.h
--- branches/2.0/varnish-cache/include/stat_field.h	2009-10-08 13:23:36 UTC (rev 4301)
+++ branches/2.0/varnish-cache/include/stat_field.h	2009-10-08 13:34:03 UTC (rev 4302)
@@ -37,14 +37,14 @@
 MAC_STAT(cache_hitpass,		uint64_t, 'a', "Cache hits for pass")
 MAC_STAT(cache_miss,		uint64_t, 'a', "Cache misses")
-MAC_STAT(backend_conn,		uint64_t, 'a', "Backend connections success")
-MAC_STAT(backend_unhealthy,	uint64_t, 'a',
-    "Backend connections not attempted")
-MAC_STAT(backend_busy,		uint64_t, 'a', "Backend connections too many")
-MAC_STAT(backend_fail,		uint64_t, 'a', "Backend connections failures")
-MAC_STAT(backend_reuse,		uint64_t, 'a', "Backend connections reuses")
-MAC_STAT(backend_recycle,	uint64_t, 'a', "Backend connections recycles")
-MAC_STAT(backend_unused,	uint64_t, 'a', "Backend connections unused")
+MAC_STAT(backend_conn,		uint64_t, 'a', "Backend conn. success")
+MAC_STAT(backend_unhealthy,	uint64_t, 'a', "Backend conn. not attempted")
+MAC_STAT(backend_busy,		uint64_t, 'a', "Backend conn. too many")
+MAC_STAT(backend_fail,		uint64_t, 'a', "Backend conn. failures")
+MAC_STAT(backend_reuse,		uint64_t, 'a', "Backend conn. reuses")
+MAC_STAT(backend_toolate,	uint64_t, 'a', "Backend conn. was closed")
+MAC_STAT(backend_recycle,	uint64_t, 'a', "Backend conn. recycles")
+MAC_STAT(backend_unused,	uint64_t, 'a', "Backend conn. unused")
 MAC_STAT(n_srcaddr,		uint64_t, 'i', "N struct srcaddr")
 MAC_STAT(n_srcaddr_act,		uint64_t, 'i', "N active struct srcaddr")

More information about the varnish-commit mailing list