Bug 1397445: Remove expiring FILE_EMBEDDED_SERVICEWORKERS telemetry probe. r=bkelly
authorDavid Parks <dparks@mozilla.com>
Fri, 08 Sep 2017 11:21:27 -0700
changeset 429368 b7167e93c9db8e27845691a573d61321f19f4cc9
parent 429367 8a870bdf3aa0282d516d6184ebe81edf87dffa85
child 429369 c6425c1515d1954d46f3de0f1fec57a7ac820643
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbkelly
bugs1397445
milestone57.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 1397445: Remove expiring FILE_EMBEDDED_SERVICEWORKERS telemetry probe. r=bkelly This measured service workers registered in https iframes contained in file:// pages.
dom/workers/ServiceWorkerManager.cpp
toolkit/components/telemetry/Histograms.json
toolkit/components/telemetry/histogram-whitelists.json
--- a/dom/workers/ServiceWorkerManager.cpp
+++ b/dom/workers/ServiceWorkerManager.cpp
@@ -33,17 +33,16 @@
 #include "mozilla/BasePrincipal.h"
 #include "mozilla/ClearOnShutdown.h"
 #include "mozilla/ErrorNames.h"
 #include "mozilla/LoadContext.h"
 #include "mozilla/SystemGroup.h"
 #include "mozilla/Telemetry.h"
 #include "mozilla/dom/BindingUtils.h"
 #include "mozilla/dom/ContentParent.h"
-#include "mozilla/dom/ContentChild.h"
 #include "mozilla/dom/DOMError.h"
 #include "mozilla/dom/ErrorEvent.h"
 #include "mozilla/dom/Headers.h"
 #include "mozilla/dom/InternalHeaders.h"
 #include "mozilla/dom/Navigator.h"
 #include "mozilla/dom/NotificationEvent.h"
 #include "mozilla/dom/PromiseNativeHandler.h"
 #include "mozilla/dom/Request.h"
@@ -950,27 +949,16 @@ ServiceWorkerManager::Register(mozIDOMWi
   );
 
   job->AppendResultCallback(cb);
   queue->ScheduleJob(job);
 
   AssertIsOnMainThread();
   Telemetry::Accumulate(Telemetry::SERVICE_WORKER_REGISTRATIONS, 1);
 
-  ContentChild* contentChild = ContentChild::GetSingleton();
-  if (contentChild &&
-      contentChild->GetRemoteType().EqualsLiteral(FILE_REMOTE_TYPE)) {
-    nsString message(NS_LITERAL_STRING("ServiceWorker registered by document "
-                                       "embedded in a file:/// URI.  This may "
-                                       "result in unexpected behavior."));
-    ReportToAllClients(cleanedScope, message, EmptyString(),
-                       EmptyString(), 0, 0, nsIScriptError::warningFlag);
-    Telemetry::Accumulate(Telemetry::FILE_EMBEDDED_SERVICEWORKERS, 1);
-  }
-
   promise.forget(aPromise);
   return NS_OK;
 }
 
 void
 ServiceWorkerManager::AppendPendingOperation(nsIRunnable* aRunnable)
 {
   MOZ_ASSERT(!mActor);
--- a/toolkit/components/telemetry/Histograms.json
+++ b/toolkit/components/telemetry/Histograms.json
@@ -11761,24 +11761,16 @@
   "SERVICE_WORKER_LIFE_TIME": {
     "record_in_processes": ["main", "content"],
     "expires_in_version": "50",
     "kind": "exponential",
     "high": 120000,
     "n_buckets": 20,
     "description": "Tracking how long a ServiceWorker stays alive after it is spawned. File bugs in Core::DOM in case of a Telemetry regression."
   },
-  "FILE_EMBEDDED_SERVICEWORKERS": {
-    "record_in_processes": ["main", "content"],
-    "alert_emails": ["dparks@mozilla.com"],
-    "expires_in_version": "58",
-    "kind": "count",
-    "bug_numbers": [1312788],
-    "description": "Count ServiceWorkers that are embedded in pages loading with the file:/// protocol."
-  },
   "GRAPHICS_SANITY_TEST": {
     "record_in_processes": ["main", "content"],
     "expires_in_version": "never",
     "alert_emails": ["gfx-telemetry-alerts@mozilla.com","msreckovic@mozilla.com"],
     "kind": "enumerated",
     "n_values": 20,
     "releaseChannelCollection": "opt-out",
     "description": "Reports results from the graphics sanity test to track which drivers are having problems (0=TEST_PASSED, 1=TEST_FAILED_RENDER, 2=TEST_FAILED_VIDEO, 3=TEST_CRASHED)"
--- a/toolkit/components/telemetry/histogram-whitelists.json
+++ b/toolkit/components/telemetry/histogram-whitelists.json
@@ -1794,17 +1794,16 @@
     "FENNEC_SYNC11_MIGRATIONS_FAILED",
     "FENNEC_SYNC11_MIGRATIONS_SUCCEEDED",
     "FENNEC_SYNC11_MIGRATION_SENTINELS_SEEN",
     "FENNEC_SYNC_NUMBER_OF_SYNCS_COMPLETED",
     "FENNEC_SYNC_NUMBER_OF_SYNCS_FAILED",
     "FENNEC_SYNC_NUMBER_OF_SYNCS_FAILED_BACKOFF",
     "FENNEC_SYNC_NUMBER_OF_SYNCS_STARTED",
     "FENNEC_WAS_KILLED",
-    "FILE_EMBEDDED_SERVICEWORKERS",
     "FIPS_ENABLED",
     "FXA_CONFIGURED",
     "FX_BROWSER_FULLSCREEN_USED",
     "FX_CONTENT_CRASH_DUMP_UNAVAILABLE",
     "FX_CONTENT_CRASH_NOT_SUBMITTED",
     "FX_CONTENT_CRASH_PRESENTED",
     "FX_SESSION_RESTORE_SEND_UPDATE_CAUSED_OOM",
     "FX_TOUCH_USED",