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

Unified Diff: components/precache/core/proto/precache.proto

Issue 2037523002: Select precache resources based on field trial experiment group (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments, added more test Created 4 years, 6 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 | « components/precache/core/precache_fetcher_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/precache/core/proto/precache.proto
diff --git a/components/precache/core/proto/precache.proto b/components/precache/core/proto/precache.proto
index bfd4c508780911bc4cd8a2d0485674d2e022e04e..9bdd7af9b5cf1e9d8afef82f1a4c157328d5e089 100644
--- a/components/precache/core/proto/precache.proto
+++ b/components/precache/core/proto/precache.proto
@@ -20,8 +20,30 @@ message PrecacheManifest {
// List of resources that we predict that the user will need if they are
// likely to fetch the host.
repeated PrecacheResource resource = 1;
+
+ // Experiments running on this manifest.
+ optional PrecacheExperiments experiments = 2;
};
+message PrecacheExperiments {
+ // A mapping between experiment groups and the resources that should be
+ // considered for the experiment.
+ map<fixed32, PrecacheResourceSelection> resources_by_experiment_group = 1;
+}
+
+message PrecacheResourceSelection {
+ // Select the resources as a std::bitset over the resources listed in the
+ // manifest.
+ //
+ // The bitset should be loaded as:
+ // std::bitset selection(resource_selection.bitset());
+ // Then manifest.resource(i) is selected for the experiment iff
+ // selection.test(i).
+ //
+ // A missing bitset means that the experiment applies to all the resources.
+ optional fixed64 bitset = 1 [default = 0xFFFFFFFFFFFFFFFF];
+}
+
message PrecacheConfigurationSettings {
// The maximum rank of the user's most visited hosts to consider precaching
// resources for, starting from 1. For example, a value of 10 means that only
« no previous file with comments | « components/precache/core/precache_fetcher_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698