[ntp] Log distribution of NTP loads
This CL adds a histogram, which logs, when an NTP loads, the time since
the previous NTP started loading. This should give us the distribution
of how frequently NTPs load.
The hope is that this metric allows us to better judge what caching
strategies should be employed to reduce server requests made by NTP
modules.
Fixed: 1210219
Change-Id: I99f35a622a6b4b9bfea6aa9923013d795e2a0e95
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2900987
Commit-Queue: Tibor Goldschwendt <[email protected]>
Auto-Submit: Tibor Goldschwendt <[email protected]>
Reviewed-by: Moe Ahmadi <[email protected]>
Reviewed-by: Lei Zhang <[email protected]>
Reviewed-by: Mark Pearson <[email protected]>
Cr-Commit-Position: refs/heads/master@{#885161}
diff --git a/chrome/browser/prefs/browser_prefs.cc b/chrome/browser/prefs/browser_prefs.cc
index 9ce6fcbb..b18cc56b 100644
--- a/chrome/browser/prefs/browser_prefs.cc
+++ b/chrome/browser/prefs/browser_prefs.cc
@@ -244,6 +244,7 @@
#include "chrome/browser/ui/startup/startup_browser_creator.h"
#include "chrome/browser/ui/webui/history/foreign_session_handler.h"
#include "chrome/browser/ui/webui/new_tab_page/new_tab_page_handler.h"
+#include "chrome/browser/ui/webui/new_tab_page/new_tab_page_ui.h"
#include "chrome/browser/ui/webui/settings/settings_ui.h"
#include "chrome/browser/upgrade_detector/upgrade_detector.h"
#include "components/ntp_tiles/custom_links_manager_impl.h"
@@ -1094,6 +1095,7 @@
InstantService::RegisterProfilePrefs(registry);
media_router::RegisterProfilePrefs(registry);
NewTabPageHandler::RegisterProfilePrefs(registry);
+ NewTabPageUI::RegisterProfilePrefs(registry);
NewTabUI::RegisterProfilePrefs(registry);
ntp_tiles::CustomLinksManagerImpl::RegisterProfilePrefs(registry);
PinnedTabCodec::RegisterProfilePrefs(registry);