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

Unified Diff: chrome/browser/safe_browsing/database_manager.cc

Issue 962423002: Update instrumentation for many different bugs based on new UMA data. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 | content/browser/appcache/appcache_interceptor.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/safe_browsing/database_manager.cc
diff --git a/chrome/browser/safe_browsing/database_manager.cc b/chrome/browser/safe_browsing/database_manager.cc
index b8df09a75a9ed029cf7aa8a6cc4b0815fadd8c19..ef572f43cbc2842fea55d00609ea453fde9841ca 100644
--- a/chrome/browser/safe_browsing/database_manager.cc
+++ b/chrome/browser/safe_browsing/database_manager.cc
@@ -652,27 +652,37 @@ void SafeBrowsingDatabaseManager::ResetDatabase() {
}
void SafeBrowsingDatabaseManager::StartOnIOThread() {
+ // TODO(pkasting): Remove ScopedTracker below once crbug.com/455469 is fixed.
+ tracked_objects::ScopedTracker tracking_profile1(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION(
+ "455469 SafeBrowsingDatabaseManager::StartOnIOThread1"));
DCHECK_CURRENTLY_ON(BrowserThread::IO);
if (enabled_)
return;
DCHECK(!safe_browsing_task_runner_);
- // TODO(pkasting): Remove ScopedTracker below once crbug.com/455469 is fixed.
- tracked_objects::ScopedTracker tracking_profile2(
- FROM_HERE_WITH_EXPLICIT_FUNCTION(
- "455469 SafeBrowsingDatabaseManager::StartOnIOThread"));
// Use the blocking pool instead of a dedicated thread for safe browsing work,
// if specified by an experiment.
const bool use_blocking_pool =
variations::GetVariationParamValue("LightSpeed", "SBThreadingMode") ==
"BlockingPool";
if (use_blocking_pool) {
+ // TODO(pkasting): Remove ScopedTracker below once crbug.com/455469 is
+ // fixed.
+ tracked_objects::ScopedTracker tracking_profile2(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION(
+ "455469 SafeBrowsingDatabaseManager::StartOnIOThread2"));
base::SequencedWorkerPool* pool = BrowserThread::GetBlockingPool();
safe_browsing_task_runner_ =
pool->GetSequencedTaskRunnerWithShutdownBehavior(
pool->GetSequenceToken(),
base::SequencedWorkerPool::SKIP_ON_SHUTDOWN);
} else {
+ // TODO(pkasting): Remove ScopedTracker below once crbug.com/455469 is
+ // fixed.
+ tracked_objects::ScopedTracker tracking_profile3(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION(
+ "455469 SafeBrowsingDatabaseManager::StartOnIOThread3"));
DCHECK(!safe_browsing_thread_.get());
safe_browsing_thread_.reset(new base::Thread("Chrome_SafeBrowsingThread"));
@@ -793,10 +803,6 @@ void SafeBrowsingDatabaseManager::DoStopOnIOThread() {
}
bool SafeBrowsingDatabaseManager::DatabaseAvailable() const {
- // TODO(pkasting): Remove ScopedTracker below once crbug.com/455469 is fixed.
- tracked_objects::ScopedTracker tracking_profile2(
- FROM_HERE_WITH_EXPLICIT_FUNCTION(
- "455469 SafeBrowsingDatabaseManager::DatabaseAvailable"));
base::AutoLock lock(database_lock_);
return !closing_database_ && (database_ != NULL);
}
@@ -804,10 +810,6 @@ bool SafeBrowsingDatabaseManager::DatabaseAvailable() const {
bool SafeBrowsingDatabaseManager::MakeDatabaseAvailable() {
DCHECK_CURRENTLY_ON(BrowserThread::IO);
DCHECK(enabled_);
- // TODO(pkasting): Remove ScopedTracker below once crbug.com/455469 is fixed.
- tracked_objects::ScopedTracker tracking_profile2(
- FROM_HERE_WITH_EXPLICIT_FUNCTION(
- "455469 SafeBrowsingDatabaseManager::MakeDatabaseAvailable"));
if (DatabaseAvailable())
return true;
safe_browsing_task_runner_->PostTask(
« no previous file with comments | « no previous file | content/browser/appcache/appcache_interceptor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698