Skip to content
This repository was archived by the owner on Nov 1, 2022. It is now read-only.

Commit aa8860d

Browse files
author
Grisha Kruglov
committed
Telemetry for sync engines - credit cards, addresses, tabs
1 parent dac19af commit aa8860d

File tree

4 files changed

+669
-3
lines changed

4 files changed

+669
-3
lines changed

Diff for: components/support/sync-telemetry/docs/metrics.md

+84
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,40 @@ This means you might have to go searching through the dependency tree to get a f
88

99
# Pings
1010

11+
- [addresses-sync](#addresses-sync)
1112
- [bookmarks-sync](#bookmarks-sync)
13+
- [creditcards-sync](#creditcards-sync)
1214
- [history-sync](#history-sync)
1315
- [logins-sync](#logins-sync)
1416
- [sync](#sync)
17+
- [tabs-sync](#tabs-sync)
18+
19+
## addresses-sync
20+
21+
A ping sent for every Addresses engine sync. It doesn't include the `client_id` because it reports a hashed version of the user's Firefox Account ID.
22+
23+
24+
**Data reviews for this ping:**
25+
26+
- <https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481>
27+
28+
**Bugs related to this ping:**
29+
30+
- <https://github.com/mozilla-mobile/android-components/issues/10371>
31+
32+
All Glean pings contain built-in metrics in the [`ping_info`](https://mozilla.github.io/glean/book/user/pings/index.html#the-ping_info-section) and [`client_info`](https://mozilla.github.io/glean/book/user/pings/index.html#the-client_info-section) sections.
33+
34+
In addition to those built-in metrics, the following metrics are added to the ping:
35+
36+
| Name | Type | Description | Data reviews | Extras | Expiration | [Data Sensitivity](https://wiki.mozilla.org/Firefox/Data_Collection) |
37+
| --- | --- | --- | --- | --- | --- | --- |
38+
| addresses_sync.failure_reason |[labeled_string](https://mozilla.github.io/glean/book/user/metrics/labeled_strings.html) |Records why the addresses 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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>other</li><li>unexpected</li><li>auth</li></ul>|never |2 |
39+
| addresses_sync.finished_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the addresses sync finished. This includes the time to download, apply, and upload all records. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
40+
| addresses_sync.incoming |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records incoming addresses record counts. `applied` is the number of incoming records that were successfully stored or updated in the local database. `failed_to_apply` is the number of records that were ignored due to errors. `reconciled` is the number of merged records. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>applied</li><li>failed_to_apply</li><li>reconciled</li></ul>|never |2 |
41+
| addresses_sync.outgoing |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records outgoing addresses 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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>uploaded</li><li>failed_to_upload</li></ul>|never |2 |
42+
| addresses_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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
43+
| addresses_sync.started_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the addresses sync started. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
44+
| addresses_sync.uid |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The user's hashed Firefox Account ID. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
1545

1646
## bookmarks-sync
1747

@@ -42,6 +72,33 @@ In addition to those built-in metrics, the following metrics are added to the pi
4272
| bookmarks_sync.uid |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The user's hashed Firefox Account ID. |[mozilla-mobile/android-components#3092](https://github.com/mozilla-mobile/android-components/pull/3092)||never |2 |
4373
| sync.sync_uuid |[uuid](https://mozilla.github.io/glean/book/user/metrics/uuid.html) |Unique identifier for this sync, used to correlate together individual pings for data types that were synchronized together (history, bookmarks, logins). If a data type is synchronized by itself via the legacy 'sync' API (as opposed to the Sync Manager), then this field will not be set on the corresponding ping. |[mozilla-mobile/android-components#5386](https://github.com/mozilla-mobile/android-components/pull/5386#pullrequestreview-392363687)||never |1 |
4474

75+
## creditcards-sync
76+
77+
A ping sent for every Credit Cards engine sync. It doesn't include the `client_id` because it reports a hashed version of the user's Firefox Account ID.
78+
79+
80+
**Data reviews for this ping:**
81+
82+
- <https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481>
83+
84+
**Bugs related to this ping:**
85+
86+
- <https://github.com/mozilla-mobile/android-components/issues/10371>
87+
88+
All Glean pings contain built-in metrics in the [`ping_info`](https://mozilla.github.io/glean/book/user/pings/index.html#the-ping_info-section) and [`client_info`](https://mozilla.github.io/glean/book/user/pings/index.html#the-client_info-section) sections.
89+
90+
In addition to those built-in metrics, the following metrics are added to the ping:
91+
92+
| Name | Type | Description | Data reviews | Extras | Expiration | [Data Sensitivity](https://wiki.mozilla.org/Firefox/Data_Collection) |
93+
| --- | --- | --- | --- | --- | --- | --- |
94+
| creditcards_sync.failure_reason |[labeled_string](https://mozilla.github.io/glean/book/user/metrics/labeled_strings.html) |Records why the credit cards 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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>other</li><li>unexpected</li><li>auth</li></ul>|never |2 |
95+
| creditcards_sync.finished_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the credit cards sync finished. This includes the time to download, apply, and upload all records. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
96+
| creditcards_sync.incoming |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records incoming credit cards record counts. `applied` is the number of incoming records that were successfully stored or updated in the local database. `failed_to_apply` is the number of records that were ignored due to errors. `reconciled` is the number of merged records. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>applied</li><li>failed_to_apply</li><li>reconciled</li></ul>|never |2 |
97+
| creditcards_sync.outgoing |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records outgoing credit cards 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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>uploaded</li><li>failed_to_upload</li></ul>|never |2 |
98+
| creditcards_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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
99+
| creditcards_sync.started_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the credit cards sync started. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
100+
| creditcards_sync.uid |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The user's hashed Firefox Account ID. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
101+
45102
## history-sync
46103

47104
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.
@@ -122,6 +179,33 @@ In addition to those built-in metrics, the following metrics are added to the pi
122179
| sync.failure_reason |[labeled_string](https://mozilla.github.io/glean/book/user/metrics/labeled_strings.html) |Records a global sync failure: either due to an authentication error, unexpected exception, or other error that caused the sync to fail. Error strings are truncated and sanitized to omit PII, like URLs and file system paths. |[mozilla-mobile/android-components#3092](https://github.com/mozilla-mobile/android-components/pull/3092)|<ul><li>other</li><li>unexpected</li><li>auth</li></ul>|never |2 |
123180
| sync.sync_uuid |[uuid](https://mozilla.github.io/glean/book/user/metrics/uuid.html) |Unique identifier for this sync, used to correlate together individual pings for data types that were synchronized together (history, bookmarks, logins). If a data type is synchronized by itself via the legacy 'sync' API (as opposed to the Sync Manager), then this field will not be set on the corresponding ping. |[mozilla-mobile/android-components#5386](https://github.com/mozilla-mobile/android-components/pull/5386#pullrequestreview-392363687)||never |1 |
124181

182+
## tabs-sync
183+
184+
A ping sent for every Tabs engine sync. It doesn't include the `client_id` because it reports a hashed version of the user's Firefox Account ID.
185+
186+
187+
**Data reviews for this ping:**
188+
189+
- <https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481>
190+
191+
**Bugs related to this ping:**
192+
193+
- <https://github.com/mozilla-mobile/android-components/issues/10371>
194+
195+
All Glean pings contain built-in metrics in the [`ping_info`](https://mozilla.github.io/glean/book/user/pings/index.html#the-ping_info-section) and [`client_info`](https://mozilla.github.io/glean/book/user/pings/index.html#the-client_info-section) sections.
196+
197+
In addition to those built-in metrics, the following metrics are added to the ping:
198+
199+
| Name | Type | Description | Data reviews | Extras | Expiration | [Data Sensitivity](https://wiki.mozilla.org/Firefox/Data_Collection) |
200+
| --- | --- | --- | --- | --- | --- | --- |
201+
| tabs_sync.failure_reason |[labeled_string](https://mozilla.github.io/glean/book/user/metrics/labeled_strings.html) |Records why the tabs 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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>other</li><li>unexpected</li><li>auth</li></ul>|never |2 |
202+
| tabs_sync.finished_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the tabs sync finished. This includes the time to download, apply, and upload all records. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
203+
| tabs_sync.incoming |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records incoming tabs record counts. `applied` is the number of incoming records that were successfully stored or updated in the local database. `failed_to_apply` is the number of records that were ignored due to errors. `reconciled` is the number of merged records. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>applied</li><li>failed_to_apply</li><li>reconciled</li></ul>|never |2 |
204+
| tabs_sync.outgoing |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Records outgoing tabs 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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)|<ul><li>uploaded</li><li>failed_to_upload</li></ul>|never |2 |
205+
| tabs_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. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
206+
| tabs_sync.started_at |[datetime](https://mozilla.github.io/glean/book/user/metrics/datetime.html) |Records when the tabs sync started. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
207+
| tabs_sync.uid |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The user's hashed Firefox Account ID. |[mozilla-mobile/android-components#10372](https://github.com/mozilla-mobile/android-components/pull/10372#issuecomment-850378481)||never |2 |
208+
125209
Data categories are [defined here](https://wiki.mozilla.org/Firefox/Data_Collection).
126210

127211
<!-- AUTOGENERATED BY glean_parser. DO NOT EDIT. DO NOT COMMIT. -->

0 commit comments

Comments
 (0)