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

Side by Side Diff: components/variations/proto/study.proto

Issue 2614443002: Supporting study definitions without default groups and end_date filtering. (Closed)
Patch Set: Created 3 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 syntax = "proto2"; 5 syntax = "proto2";
6 6
7 option optimize_for = LITE_RUNTIME; 7 option optimize_for = LITE_RUNTIME;
8 8
9 package variations; 9 package variations;
10 10
11 // This defines the Protocol Buffer representation of a Chrome Variations study 11 // This defines the Protocol Buffer representation of a Chrome Variations study
12 // as sent to clients of the Variations server. 12 // as sent to clients of the Variations server.
13 // 13 //
14 // Next tag: 13 14 // Next tag: 13
15 message Study { 15 message Study {
16 // The name of the study. Should not contain spaces or special characters. 16 // The name of the study. Should not contain spaces or special characters.
17 // Ex: "my_study" 17 // Ex: "my_study"
18 required string name = 1; 18 required string name = 1;
19 19
20 // DEPRECATED: Prefer end_date instead.
20 // The expiry date of the study in Unix time format. (Seconds since midnight 21 // The expiry date of the study in Unix time format. (Seconds since midnight
21 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time 22 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time
22 // 23 //
23 // A study that has expired will be disabled, and users will be assigned 24 // A study that has expired will be disabled, and users will be assigned
24 // groups based on the default_experiment_name. This will take precedence over 25 // groups based on the default_experiment_name. This will take precedence over
25 // a corresponding hardcoded field trial in the client. 26 // a corresponding hardcoded field trial in the client.
26 // 27 //
27 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z) 28 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z)
28 optional int64 expiry_date = 3; 29 optional int64 expiry_date = 3;
29 30
30 // Consistency setting for a study. 31 // Consistency setting for a study.
31 enum Consistency { 32 enum Consistency {
32 SESSION = 0; // Can't change within a session. 33 SESSION = 0; // Can't change within a session.
33 PERMANENT = 1; // Can't change for a given user. 34 PERMANENT = 1; // Can't change for a given user.
34 } 35 }
35 36
36 // Consistency setting for this study. Optional - defaults to SESSION. 37 // Consistency setting for this study. Optional - defaults to SESSION.
37 // Ex: PERMANENT 38 // Ex: PERMANENT
38 optional Consistency consistency = 7 [default = SESSION]; 39 optional Consistency consistency = 7 [default = SESSION];
39 40
40 // Name of the experiment that gets the default experience. This experiment 41 // Name of the experiment that gets the default experience. This experiment
41 // must be included in the list below. 42 // must be included in the list below. If not specified, a dummy experiment
43 // named "variations_dummy_default" is used, and will have a probability
rkaplow 2017/01/04 15:58:25 this isn't the name you put above
jwd 2017/01/04 21:10:22 Done.
44 // weight of 0.
42 // Ex: "default" 45 // Ex: "default"
43 optional string default_experiment_name = 8; 46 optional string default_experiment_name = 8;
44 47
45 // An experiment within the study. 48 // An experiment within the study.
46 // 49 //
47 // Next tag: 14 50 // Next tag: 14
48 message Experiment { 51 message Experiment {
49 // A named parameter value for this experiment. 52 // A named parameter value for this experiment.
50 // 53 //
51 // Next tag: 3 54 // Next tag: 3
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 // Possible form factors Chrome is running on. 194 // Possible form factors Chrome is running on.
192 enum FormFactor { 195 enum FormFactor {
193 DESKTOP = 0; 196 DESKTOP = 0;
194 PHONE = 1; 197 PHONE = 1;
195 TABLET = 2; 198 TABLET = 2;
196 } 199 }
197 200
198 // Filtering criteria specifying whether this study is applicable to a given 201 // Filtering criteria specifying whether this study is applicable to a given
199 // Chrome instance. 202 // Chrome instance.
200 // 203 //
201 // Next tag: 13 204 // Next tag: 14
202 message Filter { 205 message Filter {
203 // The start date of the study in Unix time format. (Seconds since midnight 206 // The start date of the study in Unix time format. (Seconds since midnight
204 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time 207 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time
205 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z) 208 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z)
206 optional int64 start_date = 1; 209 optional int64 start_date = 1;
207 210
211 // The end date of the study in Unix time format. (Seconds since midnight
212 // January 1, 1970 UTC). See: http://en.wikipedia.org/wiki/Unix_time
213 // Ex: 1330893974 (corresponds to 2012-03-04 20:46:14Z)
214 // Mutually exclusive with expiry_date. The difference between end_date and
215 // expiry_date is that, when end_date is past, the field trial will not be
216 // created. When expiry_date is past, the trial is still created, but will
217 // be disabled, casing it to select it's default group.
218 optional int64 end_date = 13;
219
208 // The minimum Chrome version for this study, allowing a trailing '*' 220 // The minimum Chrome version for this study, allowing a trailing '*'
209 // character for pattern matching. Inclusive. (To check for a match, iterate 221 // character for pattern matching. Inclusive. (To check for a match, iterate
210 // over each component checking >= until a * or end of string is reached.) 222 // over each component checking >= until a * or end of string is reached.)
211 // Optional - if not specified, there is no minimum version. 223 // Optional - if not specified, there is no minimum version.
212 // Ex: "17.0.963.46", "17.0.963.*", "17.*" 224 // Ex: "17.0.963.46", "17.0.963.*", "17.*"
213 optional string min_version = 2; 225 optional string min_version = 2;
214 226
215 // The maximum Chrome version for this study; same formatting as 227 // The maximum Chrome version for this study; same formatting as
216 // |min_version| above. Inclusive. (To check for a match, iterate over each 228 // |min_version| above. Inclusive. (To check for a match, iterate over each
217 // component checking <= until a * or end of string is reached.) 229 // component checking <= until a * or end of string is reached.)
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 // This is recommended for most studies that include client code. 305 // This is recommended for most studies that include client code.
294 ACTIVATION_EXPLICIT = 0; 306 ACTIVATION_EXPLICIT = 0;
295 // The study will be automatically activated when it is created. This 307 // The study will be automatically activated when it is created. This
296 // is recommended for studies that do not have any client logic. 308 // is recommended for studies that do not have any client logic.
297 ACTIVATION_AUTO = 1; 309 ACTIVATION_AUTO = 1;
298 } 310 }
299 311
300 // Activation type for this study. Defaults to ACTIVATION_EXPLICIT if omitted. 312 // Activation type for this study. Defaults to ACTIVATION_EXPLICIT if omitted.
301 optional ActivationType activation_type = 12; 313 optional ActivationType activation_type = 12;
302 } 314 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698