trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From z..@apache.org
Subject [3/3] git commit: TS-1289 stats codes mess up when disk fail
Date Thu, 21 Jun 2012 15:41:09 GMT
TS-1289 stats codes mess up when disk fail


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/99cbf8ac
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/99cbf8ac
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/99cbf8ac

Branch: refs/heads/master
Commit: 99cbf8acb97b191631882bfcfaf06d512347fdd4
Parents: 2549fa2
Author: Zhao Yongming <ming.zym@gmail.com>
Authored: Wed Jun 6 10:36:17 2012 +0800
Committer: Zhao Yongming <ming.zym@gmail.com>
Committed: Thu Jun 21 11:00:52 2012 +0800

----------------------------------------------------------------------
 iocore/cache/Cache.cc |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/99cbf8ac/iocore/cache/Cache.cc
----------------------------------------------------------------------
diff --git a/iocore/cache/Cache.cc b/iocore/cache/Cache.cc
index f8d7a07..36eb830 100644
--- a/iocore/cache/Cache.cc
+++ b/iocore/cache/Cache.cc
@@ -1685,13 +1685,13 @@ AIO_Callback_handler::handle_disk_failure(int event, void *data) {
           if (d->fd == gvol[p]->fd) {
             total_dir_delete += gvol[p]->buckets * gvol[p]->segments * DIR_DEPTH;
             used_dir_delete += dir_entries_used(gvol[p]);
-            total_bytes_delete = gvol[p]->len - vol_dirlen(gvol[p]);
+            total_bytes_delete += gvol[p]->len - vol_dirlen(gvol[p]);
           }
         }
 
         RecIncrGlobalRawStat(cache_rsb, cache_bytes_total_stat, -total_bytes_delete);
-        RecIncrGlobalRawStat(cache_rsb, cache_bytes_total_stat, -total_dir_delete);
-        RecIncrGlobalRawStat(cache_rsb, cache_bytes_total_stat, -cache_direntries_used_stat);
+        RecIncrGlobalRawStat(cache_rsb, cache_direntries_total_stat, -total_dir_delete);
+        RecIncrGlobalRawStat(cache_rsb, cache_direntries_used_stat, -used_dir_delete);
 
         if (theCache) {
           rebuild_host_table(theCache);


Mime
View raw message