Telemetry for Default Search Provider
Why/User Benefit/User Problem
As a Product Owner I want to have insight about what search providers people use.
What / Requirements
Specific things we capture for default search on desktop, and should for Fenix as well:
defaultSearchEngine: this should be the engine identifier (i.e. google-b-1-m vs. google-b-m) defaultSearchEngineData.loadPath: This is the full path the engine is loaded from, typically with a prefix like [app], [profile], [other], etc. defaultSearchEngineData.name: the display name (i.e. "Google") for the default search defaultSearchEngineData.origin: the origin default_search_engine_data_submission_url: the full search URL used with this setting (note that there's some privacy constraints on desktop for which URLs to record, @mkaply can provide guidance for how this works)
As an example, the desktop ping contains the following (defaultSeachEngine was added first, in a new ping I'd have them all in a single object:
- defaultSearchEngine google-b-d
- defaultSearchEngineData.name Google
- defaultSearchEngineData.loadPath jar:[app]/omni.ja!/google-b-d.xml
- defaultSearchEngineData.origin default
- defaultSearchEngineData.submissionURL https://www.google.com/search?client=firefox-b-d&q=
Acceptance Criteria (how do I know when I’m done?)
- We are sending telemetry events for the actions listed in the requirements
- We have documented the telemetry
- We have asked a data steward to review the telemetry
- We have consulted the Search Team that this telemetry is complete
┆Issue is synchronized with this Jira Task
Asking @mconnormoz for feedback on telemetry specifics.
Specific things we capture for default search on desktop, and should for Fenix as well:
defaultSearchEngine: this should be the engine identifier (i.e. google-b-1-m vs. google-b-m) defaultSearchEngineData.loadPath: This is the full path the engine is loaded from, typically with a prefix like [app], [profile], [other], etc. defaultSearchEngineData.name: the display name (i.e. "Google") for the default search defaultSearchEngineData.origin: the origin default_search_engine_data_submission_url: the full search URL used with this setting (note that there's some privacy constraints on desktop for which URLs to record, @mkaply can provide guidance for how this works)
As an example, the desktop ping contains the following (defaultSeachEngine was added first, in a new ping I'd have them all in a single object
defaultSearchEngine google-b-d defaultSearchEngineData.name Google defaultSearchEngineData.loadPath jar:[app]/omni.ja!/google-b-d.xml defaultSearchEngineData.origin default defaultSearchEngineData.submissionURL https://www.google.com/search?client=firefox-b-d&q=
Blocked by https://github.com/mozilla-mobile/android-components/issues/2533
Specific things we capture for default search on desktop, and should for Fenix as well:
defaultSearchEngine: this should be the engine identifier (i.e. google-b-1-m vs. google-b-m) defaultSearchEngineData.loadPath: This is the full path the engine is loaded from, typically with a prefix like [app], [profile], [other], etc. defaultSearchEngineData.name: the display name (i.e. "Google") for the default search defaultSearchEngineData.origin: the origin default_search_engine_data_submission_url: the full search URL used with this setting (note that there's some privacy constraints on desktop for which URLs to record, @mkaply can provide guidance for how this works)
This seems to cover only the default search provider.
For these specific examples here, they could all be individual string metrics in Glean, collected under one category. E.g.:
search.default_engine:
identifier:
kind: string
...
name:
kind: string
...
... etc.
We might have to check whether the permitted length of string is sufficient (and if not, how we deal with that with allowing very long strings everywhere).
Hey @mconnormoz, where does defaultSearchEngineData.origin come from?
We probably don't need origin. That comes from some anti-hijacking code on desktop that in theory tells us whether someone's modified the config out of band, but in practice hijackers are faking it. I don't think it's needed for Fenix.
I verified the data was coming with Frank
This has been verified by QA, the ping is sent and data is successfully logged.