forked from mozilla-mobile/android-components
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
4242: Allow generating docs for Glean metrics r=Dexterp37 a=Dexterp37 The docs are written, at build-time, to '$project/docs/metrics.md'. This additionally enables automatic doc generation for the following components: lib-crash, storage-sync. Bonus: add a note to engine-gecko-nightly's readme to explicitly require a data-review for products using it. @pocmo - r? for the changes to lib-crash @linacambridge - r? for the changes to browser-sync **Note**: whenever new metrics are added, the build system will automatically update the docs so that the dev can simply commit the changes. Co-authored-by: Alessio Placitelli <alessio.placitelli@gmail.com>
- Loading branch information
Showing
8 changed files
with
148 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<!-- AUTOGENERATED BY glean_parser. DO NOT EDIT. --> | ||
|
||
# Metrics | ||
This document enumerates the metrics collected by this project. | ||
This project may depend on other projects which also collect metrics. | ||
This means you might have to go searching through the dependency tree to get a full picture of everything collected by this project. | ||
Sorry about that. | ||
|
||
# Pings | ||
|
||
- [bookmarks_sync](#bookmarks_sync) | ||
- [history_sync](#history_sync) | ||
|
||
|
||
## bookmarks_sync | ||
A ping sent for every bookmarks sync. It doesn't include the `client_id` because it reports a hashed version of the user's Firefox Account ID. | ||
|
||
The following metrics are added to the ping: | ||
|
||
| Name | Type | Description | Data reviews | Extras | Expiration | | ||
| --- | --- | --- | --- | --- | --- | | ||
| bookmarks_sync.failure_reason |[labeled_string](https://mozilla.github.io/glean/book/user/metrics/labeled_strings.html) |Records bookmark sync failure reasons. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.finished_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the bookmark sync finished. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.incoming |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records incoming bookmark record counts. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.outgoing |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records outgoing bookmark record counts. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.outgoing_batches |[counter](https://mozilla.github.io/glean/book/user/metrics/counter.html) |Records the number of batches needed to upload all outgoing records. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.remote_tree_problems |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records counts for structure problems and divergences in the remote bookmarks tree. These are documented in https://github.com/mozilla/dogear/blob/fbade15f2a4f11215e30b8f428a0a8df3defeaec/src/tree.rs#L1273-L1294. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.started_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the bookmark sync started. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| bookmarks_sync.uid |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The user's hashed Firefox Account ID. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
|
||
## history_sync | ||
A ping sent for every history sync. It doesn't include the `client_id` because it reports a hashed version of the user's Firefox Account ID. | ||
|
||
The following metrics are added to the ping: | ||
|
||
| Name | Type | Description | Data reviews | Extras | Expiration | | ||
| --- | --- | --- | --- | --- | --- | | ||
| history_sync.failure_reason |[labeled_string](https://mozilla.github.io/glean/book/user/metrics/labeled_strings.html) |Records why the history sync failed: either due to an authentication error, unexpected exception, or other error. The error strings are truncated and sanitized to omit PII, like URLs and file system paths. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| history_sync.finished_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the history sync finished. This includes the time to download, apply, and upload all records. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| history_sync.incoming |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records incoming history record counts. `applied` is the number of incoming history pages that were successfully stored or updated in the local database. `failed_to_apply` is the number of pages that were ignored due to errors. `reconciled` is the number of pages with new visits locally and remotely, and had their visits merged. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| history_sync.outgoing |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records outgoing history record counts. `uploaded` is the number of records that were successfully sent to the server. `failed_to_upload` is the number of records that weren't uploaded, and will be retried on the next sync. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| history_sync.outgoing_batches |[counter](https://mozilla.github.io/glean/book/user/metrics/counter.html) |Records the number of batches needed to upload all outgoing records. The Sync server has a hard limit on the number of records (and request body bytes) on the number of records that can fit into a single batch, and large syncs may require multiple batches. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| history_sync.started_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the history sync started. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
| history_sync.uid |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The user's hashed Firefox Account ID. |[1](https://github.com/mozilla-mobile/android-components/pull/3092)||never | | ||
|
||
|
||
<!-- AUTOGENERATED BY glean_parser. DO NOT EDIT. --> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<!-- AUTOGENERATED BY glean_parser. DO NOT EDIT. --> | ||
|
||
# Metrics | ||
This document enumerates the metrics collected by this project. | ||
This project may depend on other projects which also collect metrics. | ||
This means you might have to go searching through the dependency tree to get a full picture of everything collected by this project. | ||
Sorry about that. | ||
|
||
# Pings | ||
|
||
- [metrics](#metrics) | ||
|
||
|
||
## metrics | ||
This is a built-in ping that is assembled out of the box by the Glean SDK. | ||
See the Glean SDK documentation for the [`metrics` ping](https://mozilla.github.io/glean/book/user/pings/metrics.html). | ||
The following metrics are added to the ping: | ||
|
||
| Name | Type | Description | Data reviews | Extras | Expiration | | ||
| --- | --- | --- | --- | --- | --- | | ||
| crash_metrics.crash_count |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Counts the number of crashes that occur in the application. This measures only the counts of each crash in association with the labeled type of the crash. The labels correspond to the types of crashes handled by lib-crash. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1553935#c3)||never | | ||
|
||
|
||
<!-- AUTOGENERATED BY glean_parser. DO NOT EDIT. --> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters