| # Copyright 2019 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. |
| |
| ################################################################################ |
| # Cobalt Project: software_delivery |
| ################################################################################ |
| |
| metric_definitions: |
| |
| ################################################################################ |
| # System Up To Date |
| # |
| # Used to log the fact that an update check was performed, but the system is |
| # already running the latest version. |
| ################################################################################ |
| - id: 1 |
| metric_name: system_up_to_date |
| # The count will always be one. |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| # What initiated the update check? |
| - dimension: initiator |
| event_codes: |
| 0: AutomaticUpdateCheck |
| 1: UserInitiatedCheck |
| # When did the update check occur? |
| - dimension: hour_of_day |
| max_event_code: 23 |
| reports: |
| - report_name: system_up_to_date_counts |
| id: 3897546620 # legacy long report_id |
| report_type: NUMERIC_AGGREGATION |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: system_up_to_date_per_device_count |
| id: 2703326378 # legacy long report_id |
| report_type: PER_DEVICE_NUMERIC_STATS |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| window_size: |
| - 1 |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/31" |
| |
| ################################################################################ |
| # OTA Start |
| # |
| # Used to log the fact that an update is available and is being applied. |
| ################################################################################ |
| - id: 2 |
| metric_name: ota_start |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| # What initiated the update check? |
| - dimension: initiator |
| event_codes: |
| 0: AutomaticUpdateCheck |
| 1: UserInitiatedCheck |
| # When did the update check occur? |
| - dimension: hour_of_day |
| max_event_code: 23 |
| reports: |
| - report_name: ota_start_counts |
| id: 276244619 # legacy long report_id |
| report_type: NUMERIC_AGGREGATION |
| # The |component| string is used to capture the target build version |
| candidate_file: fuchsia/software_delivery/build_versions.txt |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/31" |
| |
| ################################################################################ |
| # OTA Result Attempts |
| # |
| # Used to log OTA attempt number, at the point that update was applied and is |
| # ready to be booted, or an error was encountered during the update attempt |
| ################################################################################ |
| - id: 3 |
| metric_name: ota_result_attempts |
| # The value of the count will be the attempt number. |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| # What initiated the update check? |
| - dimension: initiator |
| event_codes: |
| 0: AutomaticUpdateCheck |
| 1: UserInitiatedCheck |
| # At which phase did the update terminate? |
| - dimension: phase |
| event_codes: &ota_result_termination_phases |
| 1: TUFUpdate |
| 2: PackageDownload |
| 3: ImageWrite |
| 4: SuccessPendingReboot |
| 5: Success |
| - dimension: status_code |
| event_codes: &ota_result_status_codes |
| 0: success |
| 1: error |
| 2: error_storage |
| 3: error_storage_out_of_space |
| 4: error_networking |
| 5: error_untrusted_tuf_repo |
| reports: |
| - report_name: ota_result_attempts_histogram |
| id: 1235984927 # legacy long report_id |
| report_type: INT_RANGE_HISTOGRAM |
| # The |component| string is used to capture the target build version |
| candidate_file: fuchsia/software_delivery/build_versions.txt |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION] |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 100 |
| step_size: 1 |
| - report_name: ota_result_attempts |
| id: 1004304452 # legacy long report_id |
| report_type: NUMERIC_AGGREGATION |
| # The |component| string is used to capture the target build version |
| candidate_file: fuchsia/software_delivery/build_versions.txt |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/31" |
| |
| |
| ################################################################################ |
| # OTA Result Duration |
| # |
| # Used to log the duration of an OTA at the point that an update was |
| # applied and is ready to be booted, or an error was encountered during the |
| # update attempt |
| ################################################################################ |
| - id: 4 |
| metric_name: ota_result_duration |
| # How long the update took from start to finish (not counting any necessary |
| # reboot), in milliseconds |
| metric_type: ELAPSED_TIME |
| metric_dimensions: |
| # What initiated the update check? |
| - dimension: initiator |
| event_codes: |
| 0: AutomaticUpdateCheck |
| 1: UserInitiatedCheck |
| # At which phase did the update terminate? |
| - dimension: phase |
| event_codes: *ota_result_termination_phases |
| - dimension: status_code |
| event_codes: *ota_result_status_codes |
| reports: |
| - report_name: ota_result_duration_histogram |
| id: 845188937 # legacy long report_id |
| report_type: INT_RANGE_HISTOGRAM |
| # The |component| string is used to capture the target build version |
| candidate_file: fuchsia/software_delivery/build_versions.txt |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION] |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 100 |
| step_size: 500 |
| - report_name: ota_result_duration__stats |
| id: 3514494109 # legacy long report_id |
| report_type: NUMERIC_AGGREGATION |
| # The |component| string is used to capture the target build version |
| candidate_file: fuchsia/software_delivery/build_versions.txt |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/31" |
| |
| |
| ################################################################################ |
| # OTA Result Free-Space Delta |
| # |
| # Used to log the delta between the free space after the OTA and the free space |
| # before the OTA, at the point that update was applied and is ready to be |
| # booted, or an error was encountered during the update attempt |
| ################################################################################ |
| - id: 5 |
| metric_name: ota_result_free_space_delta |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| # What initiated the update check? |
| - dimension: initiator |
| event_codes: |
| 0: AutomaticUpdateCheck |
| 1: UserInitiatedCheck |
| # At which phase did the update terminate? |
| - dimension: phase |
| event_codes: *ota_result_termination_phases |
| - dimension: status_code |
| event_codes: *ota_result_status_codes |
| reports: |
| - report_name: ota_result_free_space_delta_stats |
| id: 4160859516 # legacy long report_id |
| report_type: NUMERIC_AGGREGATION |
| # The |component| string is used to capture the target build version |
| candidate_file: fuchsia/software_delivery/build_versions.txt |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/31" |
| |
| ################################################################################ |
| # Fetch Blob Result |
| # |
| # Used to log a 1 every time fetch_blob is called. fetch_blob is called when |
| # resolving a package that is not cached. It will be called at least once (e.g. |
| # some network errors are retried) for each blob in the package. A system update |
| # resolves every package in the target system image and so will emit ~1,000 of |
| # these events over a period of about a minute. User devices are not expected to |
| # system update more than once per day. |
| ################################################################################ |
| - id: 6 |
| metric_name: fetch_blob |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: create_blob |
| 2: bad_http_status |
| 3: no_mirrors |
| 4: content_length_mismatch |
| 5: unknown_length |
| 6: blob_too_small |
| 7: blob_too_large |
| 8: truncate |
| 9: write |
| 10: hyper |
| 11: http |
| 12: blob_url |
| reports: |
| - report_name: fetch_blob_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: fetch_blob_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 50 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Is Font Package Check |
| # |
| # Triggered each time the font resolver is asked to resolve a package. This |
| # event logs a 1 and whether the package was a font package or not. We expect |
| # this to happen rarely, only a few times after certain applications start. |
| # Perhaps once per hour at most. We expect that only font packages should be |
| # requested from the font resolver so we should never log a not_font result. |
| ################################################################################ |
| - id: 7 |
| metric_name: is_font_package_check |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: font |
| 1: not_font |
| reports: |
| - report_name: is_font_package_check_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: is_font_package_check_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 50 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Font Manager Load Static Registry |
| # |
| # Occurs when the FontPackageManager tries to load a static registry. Logs a 1 |
| # along with the load result. This would only occur once per boot, so about once |
| # per month. |
| ################################################################################ |
| - id: 8 |
| metric_name: font_manager_load_static_registry |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: io |
| 2: parse |
| 3: pkg_url |
| reports: |
| - report_name: font_manager_load_static_registry_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: font_manager_load_static_registry_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 20 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Package Resolver Startup Duration |
| # |
| # Tracks the time it takes the package resolver to startup. Events occur |
| # once per boot. |
| ################################################################################ |
| - id: 9 |
| metric_name: pkg_resolver_startup_duration |
| metric_type: ELAPSED_TIME |
| reports: |
| - report_name: pkg_resolver_startup_duration_hist |
| id: 1 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| exponential: |
| floor: 0 |
| num_buckets: 17 |
| initial_step: 1000 |
| step_multiplier: 2 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| aggregation_type: MAX |
| window_size: |
| - 1 |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| |
| ################################################################################ |
| # Repository Manager Load Static Configs |
| # |
| # Occurs when RepositoryManager attempts to load static repo configs. Logs a 1 |
| # along with the load result. Occurs once per boot. |
| ################################################################################ |
| - id: 10 |
| metric_name: repository_manager_load_static_configs |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: io |
| 2: parse |
| 3: overridden |
| reports: |
| - report_name: repository_manager_load_static_configs_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: repository_manager_load_static_configs_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 30 |
| step_size: 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| window_size: |
| - 1 |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Repository Manager Load Repository for Channel |
| # |
| # Occurs when RepositoryManager tries to find a repo config for a channel. Logs |
| # a 1 and whether loading the repository was successful or not. Occurs once per |
| # boot. |
| ################################################################################ |
| - id: 11 |
| metric_name: repository_manager_load_repository_for_channel |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: failure |
| reports: |
| - report_name: repository_manager_load_repository_for_channel_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: repository_manager_load_repository_for_channel_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 30 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Create TUF Client |
| # |
| # Triggers when Repository tries to create a TUF client. Logs a 1 and the status |
| # of creating the TUF client. This happens once per boot. |
| ################################################################################ |
| - id: 12 |
| metric_name: create_tuf_client |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: &rust_tuf_result_status_codes |
| 0: success |
| 1: bad_signature |
| 2: encoding |
| 3: expired_metadata |
| 4: illegal_argument |
| 5: missing_metadata |
| 6: no_supported_hash_algorithm |
| 7: not_found |
| 8: opaque |
| 9: programming |
| 10: target_unavailable |
| 11: unknown_hash_algorithm |
| 12: unknown_key_type |
| 13: verification_failure |
| 32767: unexpected_tuf_error_variant |
| reports: |
| - report_name: create_tuf_client_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: create_tuf_client_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 30 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Update TUF Client |
| # |
| # Occurs when UpdatingTufClient tries to update. Logs a 1 and the update status. |
| # This happens once per package resolve. |
| ################################################################################ |
| - id: 13 |
| metric_name: update_tuf_client |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: *rust_tuf_result_status_codes |
| reports: |
| - report_name: update_tuf_client_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: update_tuf_client_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 50 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Resolve |
| # |
| # Triggers when resolving a package. Logs a 1 and the status of the resolve. |
| # Result event codes are positive versions of the exclusively negative error |
| # codes used in Zircon. On user builds (with ephemeral off), this happens once |
| # for each package in the system image per system update. |
| ################################################################################ |
| - id: 14 |
| metric_name: resolve |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: zx_ok |
| 1: zx_err_internal |
| 2: zx_err_not_supported |
| 3: zx_err_no_resources |
| 4: zx_err_no_memory |
| 6: zx_err_internal_intr_retry |
| 10: zx_err_invalid_args |
| 11: zx_err_bad_handle |
| 12: zx_err_wrong_type |
| 13: zx_err_bad_syscall |
| 14: zx_err_out_of_range |
| 15: zx_err_buffer_too_small |
| 20: zx_err_bad_state |
| 21: zx_err_timed_out |
| 22: zx_err_should_wait |
| 23: zx_err_canceled |
| 24: zx_err_peer_closed |
| 25: zx_err_not_found |
| 26: zx_err_already_exists |
| 27: zx_err_already_bound |
| 28: zx_err_unavailable |
| 30: zx_err_access_denied |
| 40: zx_err_io |
| 41: zx_err_io_refused |
| 42: zx_err_io_data_integrity |
| 43: zx_err_io_data_loss |
| 44: zx_err_io_not_present |
| 45: zx_err_io_overrun |
| 46: zx_err_io_missed_deadline |
| 47: zx_err_io_invalid |
| 50: zx_err_bad_path |
| 51: zx_err_not_dir |
| 52: zx_err_not_file |
| 53: zx_err_file_big |
| 54: zx_err_no_space |
| 55: zx_err_not_empty |
| 60: zx_err_stop |
| 61: zx_err_next |
| 62: zx_err_async |
| 70: zx_err_protocol_not_supported |
| 71: zx_err_address_unreachable |
| 72: zx_err_address_in_use |
| 73: zx_err_not_connected |
| 74: zx_err_connection_refused |
| 75: zx_err_connection_reset |
| 76: zx_err_connection_aborted |
| 32767: unexpected_zx_status_value |
| - dimension: resolver_type |
| event_codes: |
| 0: regular |
| 1: font |
| reports: |
| - report_name: resolve_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: resolve_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 1000 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Resolve Duration |
| # |
| # Occurs after a package has finished resolving, successful or otherwise. Tracks |
| # how long it takes to resolve a package. This is expected to take under a few |
| # seconds. Happens once per package resolve. |
| ################################################################################ |
| - id: 15 |
| metric_name: resolve_duration |
| metric_type: ELAPSED_TIME |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: failure |
| - dimension: resolver_type |
| event_codes: |
| 0: regular |
| 1: font |
| reports: |
| - report_name: resolve_duration_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: resolve_duration_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| exponential: |
| floor: 0 |
| num_buckets: 17 |
| initial_step: 1000 |
| step_multiplier: 2 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| aggregation_type: MAX |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Package Cache Open |
| # |
| # Occurs whenever a blob is opened in pkg-cache. Logs a 1 and the result status. |
| # Happens once per package resolve. |
| ################################################################################ |
| - id: 16 |
| metric_name: pkg_cache_open |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: not_found |
| 2: io |
| reports: |
| - report_name: pkg_cache_open_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| - report_name: pkg_cache_open_hist |
| id: 2 |
| report_type: PER_DEVICE_HISTOGRAM |
| int_buckets: |
| linear: |
| floor: 0 |
| num_buckets: 1000 |
| step_size: 1 |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |
| |
| ################################################################################ |
| # Merkle For Url |
| # |
| # Occurs whenever the pkg-resolver looks up the merkle for a package url. Logs a |
| # 1 and the result status. Happens once per package resolve. |
| ################################################################################ |
| - id: 17 |
| metric_name: merkle_for_url |
| metric_type: EVENT_COUNT |
| metric_dimensions: |
| - dimension: result |
| event_codes: |
| 0: success |
| 1: fidl |
| 2: not_found |
| 3: unexpected_status |
| 4: tuf_error |
| 5: parse_error |
| 6: blob_too_large |
| 7: invalid_target_path |
| 8: no_custom_metadata |
| 9: serde_error |
| reports: |
| - report_name: merkle_for_url_stats |
| id: 1 |
| report_type: PER_DEVICE_NUMERIC_STATS |
| window_size: |
| - 1 |
| system_profile_field: [BOARD_NAME, PRODUCT_NAME, SYSTEM_VERSION, CHANNEL] |
| meta_data: |
| max_release_stage: GA |
| expiration_date: "2021/03/18" |