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

Unified Diff: net/reporting/reporting_policy.cc

Issue 2740833004: Reporting: Implement garbage collector. (Closed)
Patch Set: rebase Created 3 years, 8 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 | « net/reporting/reporting_policy.h ('k') | net/reporting/reporting_test_util.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/reporting/reporting_policy.cc
diff --git a/net/reporting/reporting_policy.cc b/net/reporting/reporting_policy.cc
index 6d36f845292fe5920e22894a5441f78c10b75185..abf58b8e567e6061725384f7bebc789af194a63b 100644
--- a/net/reporting/reporting_policy.cc
+++ b/net/reporting/reporting_policy.cc
@@ -6,7 +6,10 @@
namespace net {
-ReportingPolicy::ReportingPolicy() {
+ReportingPolicy::ReportingPolicy()
+ : max_report_age(base::TimeDelta::FromMinutes(15)),
+ max_report_attempts(5),
+ garbage_collection_interval(base::TimeDelta::FromMinutes(5)) {
endpoint_backoff_policy.num_errors_to_ignore = 0;
endpoint_backoff_policy.initial_delay_ms = 60 * 1000; // 1 minute
endpoint_backoff_policy.multiply_factor = 2.0;
@@ -17,7 +20,10 @@ ReportingPolicy::ReportingPolicy() {
}
ReportingPolicy::ReportingPolicy(const ReportingPolicy& other)
- : endpoint_backoff_policy(other.endpoint_backoff_policy) {}
+ : max_report_age(other.max_report_age),
+ max_report_attempts(other.max_report_attempts),
+ endpoint_backoff_policy(other.endpoint_backoff_policy),
+ garbage_collection_interval(other.garbage_collection_interval) {}
ReportingPolicy::~ReportingPolicy() {}
« no previous file with comments | « net/reporting/reporting_policy.h ('k') | net/reporting/reporting_test_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698