diff --git a/toolkit/components/telemetry/Scalars.yaml b/toolkit/components/telemetry/Scalars.yaml index ca02acada71f..629e4acccb14 100644 --- a/toolkit/components/telemetry/Scalars.yaml +++ b/toolkit/components/telemetry/Scalars.yaml @@ -480,6 +480,42 @@ browser.usage: - 'main' - 'content' +gecko: + version: + bug_numbers: + - 1611240 + description: > + The version of the Gecko engine, example: '74.0a1'. + It consists of the major and minor version, followed by the release life cycle phase. + 'a' stands for alpha or nightly, 'b' stands for beta. + The number behind the release life cycle phase indicates minor releases within the phase. + expires: never + kind: string + notification_emails: + - gfx-telemetry-alerts@mozilla.com + - ktaeleman@mozilla.com + products: + - 'geckoview_streaming' + record_in_processes: + - 'main' + release_channel_collection: opt-out + build_id: + bug_numbers: + - 1611240 + description: > + The build id of the Gecko engine, example: '20200205124310'. + It contains the time the build was created and is used as a unique id for the build. + expires: never + kind: string + notification_emails: + - gfx-telemetry-alerts@mozilla.com + - ktaeleman@mozilla.com + products: + - 'geckoview_streaming' + record_in_processes: + - 'main' + release_channel_collection: opt-out + extensions.updates: rdf: bug_numbers: diff --git a/toolkit/components/telemetry/geckoview/streaming/metrics.yaml b/toolkit/components/telemetry/geckoview/streaming/metrics.yaml index 2f8e646eaac5..c8d7454ee344 100644 --- a/toolkit/components/telemetry/geckoview/streaming/metrics.yaml +++ b/toolkit/components/telemetry/geckoview/streaming/metrics.yaml @@ -10,6 +10,36 @@ $schema: moz://mozilla.org/schemas/glean/metrics/1-0-0 geckoview: + version: + description: > + The version of the Gecko engine, example: 74.0a1 + type: string + lifetime: application + gecko_datapoint: gecko.version + bugs: + - https://bugzilla.mozilla.org/show_bug.cgi?id=1611240 + data_reviews: + - https://bugzilla.mozilla.org/show_bug.cgi?id=1611240#c2 + notification_emails: + - gfx-telemetry-alerts@mozilla.com + - ktaeleman@mozilla.com + expires: never + + build_id: + description: > + The Buildid of the Gecko engine, example: 20200205124310 + type: string + lifetime: application + gecko_datapoint: gecko.build_id + bugs: + - https://bugzilla.mozilla.org/show_bug.cgi?id=1611240 + data_reviews: + - https://bugzilla.mozilla.org/show_bug.cgi?id=1611240#c2 + notification_emails: + - gfx-telemetry-alerts@mozilla.com + - ktaeleman@mozilla.com + expires: never + page_load_progress_time: type: timing_distribution time_unit: millisecond diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp index 7a9b656f7d50..027d5335b77c 100644 --- a/toolkit/xre/nsAppRunner.cpp +++ b/toolkit/xre/nsAppRunner.cpp @@ -4517,6 +4517,12 @@ nsresult XREMain::XRE_mainRun() { } #endif /* MOZ_INSTRUMENT_EVENT_LOOP */ + // Send Telemetry about Gecko version and buildid + Telemetry::ScalarSet(Telemetry::ScalarID::GECKO_VERSION, + NS_ConvertASCIItoUTF16(gAppData->version)); + Telemetry::ScalarSet(Telemetry::ScalarID::GECKO_BUILD_ID, + NS_ConvertASCIItoUTF16(gAppData->buildID)); + #if defined(MOZ_SANDBOX) && defined(XP_LINUX) // If we're on Linux, we now have information about the OS capabilities // available to us.