]> err.no Git - varnish/commitdiff
Make separate stats counters for number of object checked against purges
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Thu, 31 Jul 2008 09:25:25 +0000 (09:25 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Thu, 31 Jul 2008 09:25:25 +0000 (09:25 +0000)
and number of regexps checked.

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

varnish-cache/bin/varnishd/cache_ban.c
varnish-cache/include/stat_field.h

index c4f3f27aa5ea7c2a943fe757e6e0c16a1238f779..050d09834db192465de591333480c39cf8539d2d 100644 (file)
@@ -176,7 +176,8 @@ BAN_CheckObject(struct object *o, const char *url, const char *hash)
        o->ban->refcount--;
        if (b == o->ban)        /* not banned */
                b0->refcount++;
-       VSL_stats->n_purge_test++;
+       VSL_stats->n_purge_obj_test++;
+       VSL_stats->n_purge_re_test += tests;
        UNLOCK(&ban_mtx);
 
        if (b == o->ban) {      /* not banned */
index 6d095fbd23ccf64dd89192b189f91eb1d621c352..b46e26c1fc2a43ff4e49ba45320fdd885af1cd9e 100644 (file)
@@ -120,4 +120,5 @@ MAC_STAT(n_vcl_discard,             uint64_t, 'a', "N vcl discarded")
 MAC_STAT(n_purge,              uint64_t, 'i', "N total active purges")
 MAC_STAT(n_purge_add,          uint64_t, 'a', "N new purges added")
 MAC_STAT(n_purge_retire,       uint64_t, 'a', "N old purges deleted")
-MAC_STAT(n_purge_test,         uint64_t, 'a', "N purge record tests")
+MAC_STAT(n_purge_obj_test,     uint64_t, 'a', "N objects tested")
+MAC_STAT(n_purge_re_test,      uint64_t, 'a', "N regexps tested against")