summaryrefslogtreecommitdiff
path: root/chromium/components/query_tiles/internal/stats.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/components/query_tiles/internal/stats.h')
-rw-r--r--chromium/components/query_tiles/internal/stats.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/chromium/components/query_tiles/internal/stats.h b/chromium/components/query_tiles/internal/stats.h
index 84ee417fc0b..f0467645866 100644
--- a/chromium/components/query_tiles/internal/stats.h
+++ b/chromium/components/query_tiles/internal/stats.h
@@ -10,6 +10,22 @@
namespace query_tiles {
namespace stats {
+extern const char kImagePreloadingHistogram[];
+
+extern const char kHttpResponseCodeHistogram[];
+
+extern const char kNetErrorCodeHistogram[];
+
+extern const char kRequestStatusHistogram[];
+
+extern const char kGroupStatusHistogram[];
+
+extern const char kFirstFlowDurationHistogram[];
+
+extern const char kFetcherStartHourHistogram[];
+
+extern const char kPrunedGroupReasonHistogram[];
+
// Event to track image loading metrics.
enum class ImagePreloadingEvent {
// Start to fetch image in full browser mode.
@@ -27,6 +43,14 @@ enum class ImagePreloadingEvent {
kMaxValue = kFailureReducedMode,
};
+enum class PrunedGroupReason {
+ // Group has expired.
+ kExpired = 0,
+ // Locale mismatched.
+ kInvalidLocale = 1,
+ kMaxValue = kInvalidLocale,
+};
+
// Records an image preloading event.
void RecordImageLoading(ImagePreloadingEvent event);
@@ -42,6 +66,16 @@ void RecordTileRequestStatus(TileInfoRequestStatus status);
// Records status of tile group.
void RecordTileGroupStatus(TileGroupStatus status);
+// Records the number of hours passed from first time schedule to first time
+// run.
+void RecordFirstFetchFlowDuration(int hours);
+
+// Records the locale explode hour when fetching starts.
+void RecordExplodeOnFetchStarted(int explode);
+
+// Records the reason to cause TileManager to prune the group.
+void RecordGroupPruned(PrunedGroupReason reason);
+
} // namespace stats
} // namespace query_tiles