blob: 2dad150636b74984853c816c3012eefbcfe6f094 [file] [log] [blame]
# Copyright 2020 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
metric_definitions:
################################################################################
# Life Cycle events for Timekeeper.
#
# An event is generated when certain key conditions are met during the execution
# of Timekeeper. These events are infrequent, with each occurring at most once
# per instantiation of the Timekeeper component.
################################################################################
- id: 1
metric_name: timekeeper_lifecycle_events
metric_type: EVENT_OCCURRED
metric_dimensions:
- dimension: event_type
event_codes:
# Timekeeper was initialized before the UTC clock had been started.
# This is the expected initialization path.
0: InitializedBeforeUtcStart
# Timekeeper was initialized after the UTC clock was already started,
# probably indicating Timekeeper has been restarted.
1: InitializedAfterUtcStart
# Timekeeper successfully read performance data from the stash.
2: ReadFromStash
# Timekeeper started the UTC clock using data it received from a time
# source.
3: StartedUtcFromTimeSource
# Timekeeper started the UTC clock using data from the real time clock.
4: StartedUtcFromRtc
max_event_code: 31
reports:
- report_name: counts
id: 1
report_type: SIMPLE_OCCURRENCE_COUNT
local_privacy_noise_level: NONE
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
- report_name: n_day_actives
id: 2
report_type: UNIQUE_N_DAY_ACTIVES
local_privacy_noise_level: NONE
window_size:
- 1
- 7
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
meta_data:
max_release_stage: GA
expiration_date: "2021/07/15"
################################################################################
# Time source time update events.
#
# An event is generated for each successful or failed time update Timekeeper
# receives from a time source. For successful time updates the event indicates
# whether it was accepted or rejected by Timekeeper.
################################################################################
- id: 2
metric_name: time_update_events
metric_type: EVENT_COUNT
metric_dimensions:
- dimension: outcome
event_codes:
0: Accepted
1: Failed
2: RejectedNotAfterBackstop
3: RejectedRateLimitExceeded
max_event_code: 31
- dimension: role
event_codes:
0: Primary
1: Fallback
2: Gating
3: Monitor
- dimension: experiment
# Product and role are sufficient to identify which time source produced a
# particular event, except for cases where an experiment or partial
# rollout is in progress. The experiment dimension is used to distinguish
# between the potential options in these cases.
event_codes:
0: None
1: A
2: B
reports:
- report_name: per_device_stats
id: 1
report_type: PER_DEVICE_NUMERIC_STATS
window_size:
- 1
- 7
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
meta_data:
max_release_stage: GA
expiration_date: "2021/07/15"
################################################################################
# Real Time Clock events.
#
# A single read or failure event is generated during Timekeeper initialization,
# one or more write events may occur after initialization as time is updated.
################################################################################
- id: 3
metric_name: real_time_clock_events
metric_type: EVENT_OCCURRED
metric_dimensions:
- dimension: event_type
event_codes:
# No real time clock devices could be found. No reads or writes will
# be attempted.
0: NoDevices
# More than one real time clock device was found. Since the correct
# clock could not be determined no reads or writes will be attemped.
1: MultipleDevices
# A single RTC was found but a connection could not be established.
# No reads or writes will be attempted.
2: ConnectionFailed
# A read of the RTC failed.
3: ReadFailed
# A read of the RTC succeeded but the returned value was less than the
# minimum allowed time.
4: ReadInvalidBeforeBackstop
# A valid time was read from the RTC. Note this does not imply the
# system used the RTC time.
5: ReadSucceeded
# A write to the RTC failed.
6: WriteFailed
# A write to the RTC succeeded.
7: WriteSucceeded
max_event_code: 15
reports:
- report_name: counts
id: 1
report_type: SIMPLE_OCCURRENCE_COUNT
local_privacy_noise_level: NONE
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
- report_name: n_day_actives
id: 2
report_type: UNIQUE_N_DAY_ACTIVES
local_privacy_noise_level: NONE
window_size:
- 1
- 7
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
meta_data:
max_release_stage: GA
expiration_date: "2021/08/17"
################################################################################
# HTTPSDate time source poll latency
#
# Round trip times observed while polling a server in ms.
################################################################################
- id: 4
metric_name: httpsdate_poll_latency
metric_type: INT_HISTOGRAM
int_buckets:
linear:
floor: 0
num_buckets: 50 # 1000 ms
step_size: 20 # 20 ms
reports:
- report_name: latency_histogram
id: 1
report_type: INT_RANGE_HISTOGRAM
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
meta_data:
max_release_stage: GA
expiration_date: "2021/10/15"
################################################################################
# HTTPSDate time source bound size
#
# Size of the final bounds produced for a single sample in ms. Serves as a
# measure of the accuracy achieved by HTTPSDate.
################################################################################
- id: 5
metric_name: httpsdate_bound_size
metric_type: EVENT_COUNT
metric_dimensions:
- dimension: phase
event_codes:
0: Initial
1: Converge
2: Maintain
reports:
- report_name: bound_size_percentiles
id: 1
report_type: NUMERIC_AGGREGATION
percentiles: [50, 90, 95, 99]
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
- report_name: bound_size_histogram
id: 2
report_type: INT_RANGE_HISTOGRAM
int_buckets:
linear:
floor: 0
num_buckets: 40 # 2000 ms
step_size: 50 # 50 ms
system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL]
meta_data:
max_release_stage: GA
expiration_date: "2021/10/15"