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

Unified Diff: chrome/installer/setup/setup_main.cc

Issue 1537743006: Persist setup metrics and have Chrome report them during UMA upload. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@shared-histograms
Patch Set: addressed final review comments by Alexei Created 4 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/installer/setup/installer_metrics.cc ('k') | chrome/installer/util/google_update_constants.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/setup/setup_main.cc
diff --git a/chrome/installer/setup/setup_main.cc b/chrome/installer/setup/setup_main.cc
index 6f6f9d6dc2b23a1f83d95fe522a83818517b28ca..06f69cac43e49251ff5749625eeadf5e12b883f6 100644
--- a/chrome/installer/setup/setup_main.cc
+++ b/chrome/installer/setup/setup_main.cc
@@ -45,6 +45,7 @@
#include "chrome/installer/setup/install.h"
#include "chrome/installer/setup/install_worker.h"
#include "chrome/installer/setup/installer_crash_reporting.h"
+#include "chrome/installer/setup/installer_metrics.h"
#include "chrome/installer/setup/setup_constants.h"
#include "chrome/installer/setup/setup_util.h"
#include "chrome/installer/setup/uninstall.h"
@@ -69,6 +70,7 @@
#include "chrome/installer/util/self_cleaning_temp_dir.h"
#include "chrome/installer/util/shell_util.h"
#include "chrome/installer/util/user_experiment.h"
+#include "chrome/installer/util/util_constants.h"
#include "components/crash/content/app/crash_switches.h"
#include "components/crash/content/app/run_as_crashpad_handler_win.h"
#include "content/public/common/content_switches.h"
@@ -1624,6 +1626,9 @@ int WINAPI wWinMain(HINSTANCE instance, HINSTANCE prev_instance,
if (!installer::IsProcessorSupported())
return installer::CPU_NOT_SUPPORTED;
+ // Persist histograms so they can be uploaded later.
+ installer::BeginPersistentHistogramStorage();
+
// The exit manager is in charge of calling the dtors of singletons.
base::AtExitManager exit_manager;
base::CommandLine::Init(0, NULL);
@@ -1782,6 +1787,7 @@ int WINAPI wWinMain(HINSTANCE instance, HINSTANCE prev_instance,
return_code = InstallUtil::GetInstallReturnCode(install_status);
}
+ installer::EndPersistentHistogramStorage(installer_state.target_path());
VLOG(1) << "Installation complete, returning: " << return_code;
return return_code;
« no previous file with comments | « chrome/installer/setup/installer_metrics.cc ('k') | chrome/installer/util/google_update_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698