trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From iga...@apache.org
Subject [3/5] git commit: TS-1289 stats codes mess up when disk fail
Date Mon, 24 Sep 2012 14:26:41 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/7f5e8f5f
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/7f5e8f5f
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/7f5e8f5f

Branch: refs/heads/3.2.x
Commit: 7f5e8f5fa6f245d3c09cf5c60adecedbf0c00c3a
Parents: 1f29e34
Author: Zhao Yongming <ming.zym@gmail.com>
Authored: Wed Jun 6 10:36:17 2012 +0800
Committer: Igor Galić <i.galic@brainsware.org>
Committed: Mon Sep 24 16:15:51 2012 +0200

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


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/7f5e8f5f/iocore/cache/Cache.cc
----------------------------------------------------------------------
diff --git a/iocore/cache/Cache.cc b/iocore/cache/Cache.cc
index ad0fbf8..0ed3afd 100644
--- a/iocore/cache/Cache.cc
+++ b/iocore/cache/Cache.cc
@@ -1692,13 +1692,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