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

Side by Side Diff: components/variations/metrics.h

Issue 2935623004: [Cleanup] Clean up the VariationsSeedStore's histograms. (Closed)
Patch Set: Rebase Created 3 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 unified diff | Download patch
« no previous file with comments | « components/variations/BUILD.gn ('k') | components/variations/metrics.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_VARIATIONS_METRICS_H_
6 #define COMPONENTS_VARIATIONS_METRICS_H_
7
8 #include "build/build_config.h"
9
10 namespace variations {
11
12 #if defined(OS_ANDROID)
13 // The result of importing a seed during Android first run.
14 // Note: UMA histogram enum - don't re-order or remove entries.
15 enum class FirstRunSeedImportResult {
16 SUCCESS,
17 FAIL_NO_CALLBACK,
18 FAIL_NO_FIRST_RUN_SEED,
19 FAIL_STORE_FAILED,
20 FAIL_INVALID_RESPONSE_DATE,
21 ENUM_SIZE
22 };
23 #endif // OS_ANDROID
24
25 // The result of attempting to load a variations seed on startup.
26 // Note: UMA histogram enum - don't re-order or remove entries.
27 enum class LoadSeedResult {
28 SUCCESS,
29 EMPTY,
30 CORRUPT,
31 INVALID_SIGNATURE,
32 CORRUPT_BASE64,
33 CORRUPT_PROTOBUF,
34 CORRUPT_GZIP,
35 ENUM_SIZE
36 };
37
38 // The result of attempting to store a variations seed received from the server.
39 // Note: UMA histogram enum - don't re-order or remove entries.
40 enum class StoreSeedResult {
41 SUCCESS,
42 FAILED_EMPTY,
43 FAILED_PARSE,
44 FAILED_SIGNATURE,
45 FAILED_GZIP,
46 // DELTA_COUNT is not so much a result of the seed store, but rather counting
47 // the number of delta-compressed seeds the SeedStore() function saw. Kept in
48 // the same histogram for convenience of comparing against the other values.
49 DELTA_COUNT,
50 FAILED_DELTA_READ_SEED,
51 FAILED_DELTA_APPLY,
52 FAILED_DELTA_STORE,
53 FAILED_UNGZIP,
54 FAILED_EMPTY_GZIP_CONTENTS,
55 FAILED_UNSUPPORTED_SEED_FORMAT,
56 ENUM_SIZE
57 };
58
59 // The result of updating the date associated with an existing stored variations
60 // seed.
61 // Note: UMA histogram enum - don't re-order or remove entries.
62 enum class UpdateSeedDateResult {
63 NO_OLD_DATE,
64 NEW_DATE_IS_OLDER,
65 SAME_DAY,
66 NEW_DAY,
67 ENUM_SIZE
68 };
69
70 // The result of verifying a variation seed's signature.
71 // Note: UMA histogram enum - don't re-order or remove entries.
72 enum class VerifySignatureResult {
73 MISSING_SIGNATURE,
74 DECODE_FAILED,
75 INVALID_SIGNATURE,
76 INVALID_SEED,
77 VALID_SIGNATURE,
78 ENUM_SIZE
79 };
80
81 #if defined(OS_ANDROID)
82 // Records the result of importing a seed during Android first run.
83 void RecordFirstRunSeedImportResult(FirstRunSeedImportResult result);
84 #endif // OS_ANDROID
85
86 // Records the result of attempting to load a variations seed on startup.
87 void RecordLoadSeedResult(LoadSeedResult state);
88
89 // Records the result of attempting to store a variations seed received from the
90 // server.
91 void RecordStoreSeedResult(StoreSeedResult result);
92
93 } // namespace variations
94
95 #endif // COMPONENTS_VARIATIONS_METRICS_H_
OLDNEW
« no previous file with comments | « components/variations/BUILD.gn ('k') | components/variations/metrics.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698