Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(784)

Unified Diff: chrome/browser/chromeos/gdata/drive_cache_metadata.cc

Issue 10981030: UMA counts for corrupt cache db. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/gdata/drive_cache_metadata.cc
===================================================================
--- chrome/browser/chromeos/gdata/drive_cache_metadata.cc (revision 158657)
+++ chrome/browser/chromeos/gdata/drive_cache_metadata.cc (working copy)
@@ -8,6 +8,7 @@
#include "base/callback.h"
#include "base/file_util.h"
+#include "base/metrics/histogram.h"
#include "base/sequenced_task_runner.h"
#include "chrome/browser/chromeos/gdata/drive.pb.h"
#include "chrome/browser/chromeos/gdata/drive_file_system_util.h"
@@ -468,6 +469,7 @@
// perhaps not other causes of failed DB::Open.
if (!db_status.ok()) {
DVLOG(1) << "Detected corrupt db";
+ UMA_HISTOGRAM_COUNTS("Drive.CorruptCacheDB", 1);
satorux1 2012/09/25 22:40:50 I think we want to know success/failure ratio and
const bool deleted = file_util::Delete(db_path, true);
DCHECK(deleted);
db_status = leveldb::DB::Open(options, db_path.value(), &level_db);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698