Backed out changeset 5ec7f3ce97d2 (landed the wrong/older version of the patch in bug 1124895)
authorJustin Dolske <dolske@mozilla.com>
Mon, 16 Mar 2015 16:16:04 -0700
changeset 250402 42877284c697
parent 250401 5ec7f3ce97d2
child 250403 fe5932c2b378
push id4575
push userjdolske@mozilla.com
push date2015-03-16 23:21 +0000
treeherdermozilla-beta@fe5932c2b378 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1124895
milestone37.0
backs out5ec7f3ce97d2
Backed out changeset 5ec7f3ce97d2 (landed the wrong/older version of the patch in bug 1124895)
services/healthreport/docs/dataformat.rst
toolkit/components/passwordmgr/LoginManagerParent.jsm
toolkit/components/passwordmgr/passwordmgr.manifest
--- a/services/healthreport/docs/dataformat.rst
+++ b/services/healthreport/docs/dataformat.rst
@@ -1894,35 +1894,8 @@ Example
       "treatment": [
         "optin",
         "optin-DNT"
       ],
       "another-tag": [
         "foobar-value"
       ]
     }
-
-org.mozilla.passwordmgr.passwordmgr
------------------------------------
-
-Daily measurement reporting information about the Password Manager
-
-Version 1
-^^^^^^^^^
-
-Property:
-
-numSavedPasswords
-    number of passwords saved in the Password Manager
-
-enabled
-    Whether or not the user has disabled the Password Manager in prefernces
-
-Example
-^^^^^^^
-
-::
-
-    "org.mozilla.passwordmgr.passwordmgr": {
-      "_v": 1,
-      "numSavedPasswords": 5,
-      "enabled": 0,
-    }
--- a/toolkit/components/passwordmgr/LoginManagerParent.jsm
+++ b/toolkit/components/passwordmgr/LoginManagerParent.jsm
@@ -11,22 +11,18 @@ const Cc = Components.classes;
 
 Cu.import("resource://gre/modules/XPCOMUtils.jsm");
 Cu.import("resource://gre/modules/Services.jsm");
 
 XPCOMUtils.defineLazyModuleGetter(this, "UserAutoCompleteResult",
                                   "resource://gre/modules/LoginManagerContent.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "AutoCompleteE10S",
                                   "resource://gre/modules/AutoCompleteE10S.jsm");
-XPCOMUtils.defineLazyModuleGetter(this, "Task",
-                                  "resource://gre/modules/Task.jsm");
-XPCOMUtils.defineLazyModuleGetter(this, "Metrics",
-                                  "resource://gre/modules/Metrics.jsm");
 
-this.EXPORTED_SYMBOLS = [ "LoginManagerParent", "PasswordsMetricsProvider" ];
+this.EXPORTED_SYMBOLS = [ "LoginManagerParent" ];
 
 var gDebug;
 
 function log(...pieces) {
   function generateLogMessage(args) {
     let strings = ['Login Manager (parent):'];
 
     args.forEach(function(arg) {
@@ -50,61 +46,16 @@ function log(...pieces) {
   if (!gDebug)
     return;
 
   let message = generateLogMessage(pieces);
   dump(message + "\n");
   Services.console.logStringMessage(message);
 }
 
-this.PasswordsMetricsProvider = function() {
-  Metrics.Provider.call(this);
-}
-
-PasswordsMetricsProvider.prototype = Object.freeze({
-  __proto__: Metrics.Provider.prototype,
-
-  name: "org.mozilla.passwordmgr",
-
-  measurementTypes: [
-    PasswordsMeasurement1,
-  ],
-
-  pullOnly: true,
-
-  collectDailyData: function () {
-    return this.storage.enqueueTransaction(this._recordDailyPasswordData.bind(this));
-  },
-
-  _recordDailyPasswordData: function() {
-    let m = this.getMeasurement(PasswordsMeasurement1.prototype.name,
-                                PasswordsMeasurement1.prototype.version);
-    let enabled = Services.prefs.getBoolPref("signon.rememberSignons");
-    yield m.setDailyLastNumeric("enabled", enabled ? 1 : 0);
-
-    let loginsCount = Services.logins.countLogins("", "", "");
-    yield m.setDailyLastNumeric("numSavedPasswords", loginsCount);
-
-  },
-});
-
-function PasswordsMeasurement1() {
-  Metrics.Measurement.call(this);
-}
-
-PasswordsMeasurement1.prototype = Object.freeze({
-  __proto__: Metrics.Measurement.prototype,
-  name: "passwordmgr",
-  version: 1,
-  fields: {
-    enabled: {type: Metrics.Storage.FIELD_DAILY_LAST_NUMERIC},
-    numSavedPasswords: {type: Metrics.Storage.FIELD_DAILY_LAST_NUMERIC},
-  },
-});
-
 function prefChanged() {
   gDebug = Services.prefs.getBoolPref("signon.debug");
 }
 
 Services.prefs.addObserver("signon.debug", prefChanged, false);
 prefChanged();
 
 var LoginManagerParent = {
--- a/toolkit/components/passwordmgr/passwordmgr.manifest
+++ b/toolkit/components/passwordmgr/passwordmgr.manifest
@@ -10,9 +10,8 @@ contract @mozilla.org/login-manager/logi
 component {8c2023b9-175c-477e-9761-44ae7b549756} storage-mozStorage.js
 contract @mozilla.org/login-manager/storage/mozStorage;1 {8c2023b9-175c-477e-9761-44ae7b549756}
 #else
 component {c00c432d-a0c9-46d7-bef6-9c45b4d07341} storage-json.js
 contract @mozilla.org/login-manager/storage/json;1 {c00c432d-a0c9-46d7-bef6-9c45b4d07341}
 #endif
 component {dc6c2976-0f73-4f1f-b9ff-3d72b4e28309} crypto-SDR.js
 contract @mozilla.org/login-manager/crypto/SDR;1 {dc6c2976-0f73-4f1f-b9ff-3d72b4e28309}
-category healthreport-js-provider-default PasswordsMetricsProvider resource://gre/modules/LoginManagerParent.jsm
\ No newline at end of file