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

Unified Diff: extensions/browser/process_manager.cc

Issue 874643003: Add UMA histogram timers for ProcessManager and BackgroundContentsService startup. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: macros 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 | « chrome/browser/background/background_contents_service.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/browser/process_manager.cc
diff --git a/extensions/browser/process_manager.cc b/extensions/browser/process_manager.cc
index 5e2e3aa0dcd1397ff692e3fc3ce3c25cdf671ad3..186009464b6d9c16ab5fc122df87f54f387b32e4 100644
--- a/extensions/browser/process_manager.cc
+++ b/extensions/browser/process_manager.cc
@@ -9,7 +9,7 @@
#include "base/lazy_instance.h"
#include "base/logging.h"
#include "base/message_loop/message_loop.h"
-#include "base/metrics/histogram.h"
+#include "base/metrics/histogram_macros.h"
#include "base/stl_util.h"
#include "base/strings/string_number_conversions.h"
#include "base/time/time.h"
@@ -751,7 +751,10 @@ void ProcessManager::Observe(int type,
case extensions::NOTIFICATION_EXTENSIONS_READY_DEPRECATED: {
// TODO(jamescook): Convert this to use ExtensionSystem::ready() instead
// of a notification.
+ const base::TimeTicks start_time = base::TimeTicks::Now();
MaybeCreateStartupBackgroundHosts();
+ UMA_HISTOGRAM_TIMES("Extensions.ProcessManagerStartupHostsTime",
+ base::TimeTicks::Now() - start_time);
break;
}
« no previous file with comments | « chrome/browser/background/background_contents_service.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698