Index: chrome/browser/safe_browsing/certificate_reporting_service.h |
diff --git a/chrome/browser/safe_browsing/certificate_reporting_service.h b/chrome/browser/safe_browsing/certificate_reporting_service.h |
index 639b27e34a9372cde43e7d421b50b78601425bae..6aac1a7d029432bb1067108ff0c1369c7a921483 100644 |
--- a/chrome/browser/safe_browsing/certificate_reporting_service.h |
+++ b/chrome/browser/safe_browsing/certificate_reporting_service.h |
@@ -55,6 +55,24 @@ class SafeBrowsingService; |
// extended reporting preferences. |
class CertificateReportingService : public KeyedService { |
public: |
+ // Events for UMA. Do not rename or remove values, add new values to the end. |
+ // Public for testing. |
+ enum UMAEvent { |
Jialiu Lin
2017/05/05 00:25:43
nit: how about "ReportOutcome"? "UMAEvent" sounds
estark
2017/05/05 16:21:13
+1
meacer
2017/05/05 19:24:19
Done.
|
+ // A report is submitted. This includes failed and successful uploads as |
+ // well as uploads that never return a response. |
+ REPORT_SUBMITTED, |
estark
2017/05/05 16:21:13
Not sure but I think you're supposed to explicitly
meacer
2017/05/05 19:24:19
Done.
|
+ // A report submission failed. |
+ REPORT_FAILED, |
+ // A report submission was successful. |
estark
2017/05/05 16:21:13
nit: perhaps define successful (HTTP 200 status co
meacer
2017/05/05 19:24:19
Done.
|
+ REPORT_SUCCESSFUL, |
+ // A report was dropped from the reporting queue because it was older |
+ // than report TTL, or it was ignored because the queue was full and the |
+ // report was older than the oldest report in the queue. Does not include |
+ // reports that were cleared because of a SafeBrowsing preference change. |
+ REPORT_DROPPED_OR_IGNORED, |
+ REPORT_EVENT_COUNT |
+ }; |
+ |
// Represents a report to be sent. |
struct Report { |
int report_id; |
@@ -153,6 +171,8 @@ class CertificateReportingService : public KeyedService { |
DISALLOW_COPY_AND_ASSIGN(Reporter); |
}; |
+ static const char kReportEventHistogram[]; |
estark
2017/05/05 16:21:13
nit: also "Public for testing"
meacer
2017/05/05 19:24:19
Done.
|
+ |
CertificateReportingService( |
safe_browsing::SafeBrowsingService* safe_browsing_service, |
scoped_refptr<net::URLRequestContextGetter> url_request_context_getter, |