Bug 1250897 - Add build number data in Telemetry pings r=gfritzsche
authorSylvestre Ledru <sledru@mozilla.com>
Fri, 26 Feb 2016 14:04:12 +0100
changeset 324084 06a4669aaf8c8d7f76232b5eb19ff0cd6263cc0b
parent 324083 d7584b9e016655aad9900c849ae2f58ec3dbcc26
child 324085 b88648a41ed26abcc1a9184d6c583f60c600014b
push id1128
push userjlund@mozilla.com
push dateWed, 01 Jun 2016 01:31:59 +0000
treeherdermozilla-release@fe0d30de989d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgfritzsche
bugs1250897
milestone47.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1250897 - Add build number data in Telemetry pings r=gfritzsche MozReview-Commit-ID: 2CB5CMGQN6G
toolkit/components/telemetry/TelemetryController.jsm
toolkit/components/telemetry/docs/common-ping.rst
toolkit/components/telemetry/tests/unit/test_TelemetryController.js
--- a/toolkit/components/telemetry/TelemetryController.jsm
+++ b/toolkit/components/telemetry/TelemetryController.jsm
@@ -376,16 +376,17 @@ var Impl = {
       this._log.trace("_getApplicationSection - Unable to get update channel.", e);
     }
 
     return {
       architecture: arch,
       buildId: Services.appinfo.appBuildID,
       name: Services.appinfo.name,
       version: Services.appinfo.version,
+      displayVersion: AppConstants.MOZ_APP_VERSION_DISPLAY,
       vendor: Services.appinfo.vendor,
       platformVersion: Services.appinfo.platformVersion,
       xpcomAbi: Services.appinfo.XPCOMABI,
       channel: updateChannel,
     };
   },
 
   /**
--- a/toolkit/components/telemetry/docs/common-ping.rst
+++ b/toolkit/components/telemetry/docs/common-ping.rst
@@ -22,16 +22,17 @@ Structure::
       creationDate: <ISO date>, // the date the ping was generated
       version: <number>, // the version of the ping format, currently 4
 
       application: {
         architecture: <string>, // build architecture, e.g. x86
         buildId: <string>, // "20141126041045"
         name: <string>, // "Firefox"
         version: <string>, // "35.0"
+        displayVersion: <string>, // "35.0b3"
         vendor: <string>, // "Mozilla"
         platformVersion: <string>, // "35.0"
         xpcomAbi: <string>, // e.g. "x86-msvc"
         channel: <string>, // "beta"
       },
 
       clientId: <UUID>, // optional
       environment: { ... }, // optional, not all pings contain the environment
--- a/toolkit/components/telemetry/tests/unit/test_TelemetryController.js
+++ b/toolkit/components/telemetry/tests/unit/test_TelemetryController.js
@@ -53,16 +53,17 @@ function checkPingFormat(aPing, aType, a
   const MANDATORY_PING_FIELDS = [
     "type", "id", "creationDate", "version", "application", "payload"
   ];
 
   const APPLICATION_TEST_DATA = {
     buildId: "2007010101",
     name: APP_NAME,
     version: APP_VERSION,
+    displayVersion: AppConstants.MOZ_APP_VERSION_DISPLAY,
     vendor: "Mozilla",
     platformVersion: PLATFORM_VERSION,
     xpcomAbi: "noarch-spidermonkey",
   };
 
   // Check that the ping contains all the mandatory fields.
   for (let f of MANDATORY_PING_FIELDS) {
     Assert.ok(f in aPing, f + " must be available.");