Commit bac09f35 authored by Alexandr Ilin's avatar Alexandr Ilin Committed by Commit Bot

predictors: Reduce max number of tracked hosts.

This CL changes a default LoadingPredictorConfig limit for a maximum 
number of tracked hosts. Since the whole database is loaded into the 
memory at startup, it'd be better to keep the database size reasonably 
small. New setting is closer to that is used in net::Predictor
(see Predictor::kMaxReferrers with a comment).

A number of maximum origins per entry also could be reconsidered 
after experimenting in canary in dev.

Bug: 699080
Change-Id: Iae7ea78cda0910aba7ee4a7ad938cc0c1616e32a
Reviewed-on: https://chromium-review.googlesource.com/692274
Commit-Queue: Alexandr Ilin <alexilin@chromium.org>
Reviewed-by: default avatarMatthew Cary <mattcary@chromium.org>
Cr-Commit-Position: refs/heads/master@{#505414}
parent 1f50bf7f
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
#include "base/metrics/field_trial_params.h" #include "base/metrics/field_trial_params.h"
#include "chrome/browser/net/prediction_options.h" #include "chrome/browser/net/prediction_options.h"
#include "chrome/browser/net/predictor.h"
#include "chrome/browser/predictors/resource_prefetch_common.h" #include "chrome/browser/predictors/resource_prefetch_common.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "content/public/browser/browser_thread.h" #include "content/public/browser/browser_thread.h"
...@@ -102,7 +103,7 @@ LoadingPredictorConfig::LoadingPredictorConfig() ...@@ -102,7 +103,7 @@ LoadingPredictorConfig::LoadingPredictorConfig()
: mode(0), : mode(0),
max_navigation_lifetime_seconds(60), max_navigation_lifetime_seconds(60),
max_urls_to_track(500), max_urls_to_track(500),
max_hosts_to_track(200), max_hosts_to_track(chrome_browser_net::Predictor::kMaxReferrers),
min_url_visit_count(2), min_url_visit_count(2),
max_resources_per_entry(50), max_resources_per_entry(50),
max_origins_per_entry(50), max_origins_per_entry(50),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment