Bug 1528276 - Set DebuggerServer.keepAlive for RemoteDebugger and GeckoViewRemoteDebugger;r=ochameau a=lizzard
authorJulian Descottes <jdescottes@mozilla.com>
Wed, 27 Feb 2019 17:09:05 +0000
changeset 516225 f50d84563bc574211361fca6fe90e67b0cdb8f14
parent 516224 a8cd0839de6b06b2ed1c8fcf7bea7b2d1526574c
child 516226 bdc420ea17d6f2688cc1de7f433b5b2330b11983
push id1953
push userffxbld-merge
push dateMon, 11 Mar 2019 12:10:20 +0000
treeherdermozilla-release@9c35dcbaa899 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersochameau, lizzard
bugs1528276
milestone66.0
Bug 1528276 - Set DebuggerServer.keepAlive for RemoteDebugger and GeckoViewRemoteDebugger;r=ochameau a=lizzard Depends on D20831 Differential Revision: https://phabricator.services.mozilla.com/D20832
mobile/android/chrome/content/RemoteDebugger.js
mobile/android/modules/geckoview/GeckoViewRemoteDebugger.jsm
--- a/mobile/android/chrome/content/RemoteDebugger.js
+++ b/mobile/android/chrome/content/RemoteDebugger.js
@@ -210,16 +210,18 @@ var RemoteDebugger = {
     // Add browser and Fennec specific actors
     DebuggerServer.registerAllActors();
     const { createRootActor } = require("resource://gre/modules/dbg-browser-actors.js");
     DebuggerServer.setRootActor(createRootActor);
 
     // Allow debugging of chrome for any process
     DebuggerServer.allowChromeProcess = true;
     DebuggerServer.chromeWindowType = this._windowType;
+    // Force the Server to stay alive even if there are no connections at the moment.
+    DebuggerServer.keepAlive = true;
   },
 };
 
 RemoteDebugger.allowConnection =
   RemoteDebugger.allowConnection.bind(RemoteDebugger);
 RemoteDebugger.receiveOOB =
   RemoteDebugger.receiveOOB.bind(RemoteDebugger);
 
--- a/mobile/android/modules/geckoview/GeckoViewRemoteDebugger.jsm
+++ b/mobile/android/modules/geckoview/GeckoViewRemoteDebugger.jsm
@@ -56,16 +56,18 @@ var GeckoViewRemoteDebugger = {
 
     debug `onEnable`;
     DebuggerServer.init();
     DebuggerServer.registerAllActors();
     const { createRootActor } = require("resource://gre/modules/dbg-browser-actors.js");
     DebuggerServer.setRootActor(createRootActor);
     DebuggerServer.allowChromeProcess = true;
     DebuggerServer.chromeWindowType = "navigator:geckoview";
+    // Force the Server to stay alive even if there are no connections at the moment.
+    DebuggerServer.keepAlive = true;
 
     // Socket address for USB remote debugger expects
     // @ANDROID_PACKAGE_NAME/firefox-debugger-socket.
     // In /proc/net/unix, it will be outputed as
     // @org.mozilla.geckoview_example/firefox-debugger-socket
     //
     // If package name isn't available, it will be "@firefox-debugger-socket".