Граф коммитов

53 Коммитов

Автор SHA1 Сообщение Дата
Henrik Skupin 8cb90829cc Bug 1690474 - [remote] Move CDP specific code to cdp/. r=remote-protocol-reviewers,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D104574
2021-02-14 14:24:27 +00:00
Henrik Skupin d461492d57 Bug 1690468 - [remote] Move Remote Agent component related files to components/. r=remote-protocol-reviewers,jgraham,mak
Differential Revision: https://phabricator.services.mozilla.com/D104159
2021-02-08 12:34:37 +00:00
Henrik Skupin a82f8b1b2d Bug 1690472 - [remote] Move sharable top-level JS modules to shared/ subfolder. r=remote-protocol-reviewers,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D103944
2021-02-06 16:27:01 +00:00
Bogdan Tara bbc8af695c Backed out 3 changesets (bug 1690472, bug 1690469, bug 1690468) for browser_Troubleshoot.js failures CLOSED TREE
Backed out changeset a8552dfa3009 (bug 1690469)
Backed out changeset dccc9af2fd2d (bug 1690468)
Backed out changeset 3f2817c73dff (bug 1690472)
2021-02-05 18:15:26 +02:00
Henrik Skupin ffff48e5b5 Bug 1690468 - [remote] Move Remote Agent component related files to components/. r=remote-protocol-reviewers,jgraham
Depends on D103944

Differential Revision: https://phabricator.services.mozilla.com/D104159
2021-02-05 15:07:33 +00:00
Henrik Skupin 1a93388c50 Bug 1690472 - [remote] Move sharable top-level JS modules to shared/ subfolder. r=remote-protocol-reviewers,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D103944
2021-02-05 16:03:15 +00:00
Bogdan Tara ad1e568c64 Backed out 3 changesets (bug 1690472, bug 1690469, bug 1690468) for test_Sync.js failures CLOSED TREE
Backed out changeset a997c2b34b36 (bug 1690469)
Backed out changeset fc757eec91bd (bug 1690468)
Backed out changeset b60bf057d62f (bug 1690472)
2021-02-05 17:02:21 +02:00
Henrik Skupin 7cb9dcf75e Bug 1690468 - [remote] Move Remote Agent component related files to components/. r=remote-protocol-reviewers,jgraham
Depends on D103944

Differential Revision: https://phabricator.services.mozilla.com/D104159
2021-02-05 13:23:40 +00:00
Henrik Skupin 696ff9be8a Bug 1690472 - [remote] Move sharable top-level JS modules to shared/ subfolder. r=remote-protocol-reviewers,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D103944
2021-02-05 13:21:03 +00:00
Henrik Skupin 06d9e227d0 Bug 1634029 - [remote] Re-organize observer modules into a single directory. r=remote-protocol-reviewers,maja_zf
To better keep track of available observer classes
it's better to have them all in the same folder.

While moving files around the patch also renames
the TabObserver module to TargetObserver, which
would allow us to add target observers for workers
in the future.

Differential Revision: https://phabricator.services.mozilla.com/D73042
2020-04-30 00:33:25 +00:00
Maja Frydrychowicz 2536ddcb74 Bug 1614108 - Truncate Remote Agent log messages; r=remote-protocol-reviewers,whimboo
Copy format module from Marionette.

Differential Revision: https://phabricator.services.mozilla.com/D62344

--HG--
extra : moz-landing-system : lando
2020-02-15 08:22:56 +00:00
Henrik Skupin 15e30b89a5 Bug 1607461 - [remote] Implement Network.setCacheDisabled. r=remote-protocol-reviewers,ato
Differential Revision: https://phabricator.services.mozilla.com/D58996

--HG--
extra : moz-landing-system : lando
2020-01-08 12:40:49 +00:00
Andreas Tolfsen 4ff0799afe bug 1565164: remote: rename Domains DomainCache r=remote-protocol-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D58610

--HG--
rename : remote/domains/Domains.jsm => remote/domains/DomainCache.jsm
rename : remote/test/unit/test_Domains.js => remote/test/unit/test_DomainCache.js
extra : moz-landing-system : lando
2020-01-06 09:32:11 +00:00
Andreas Tolfsen 112d47f40c bug 1565164: remote: rename Targets TargetList r=remote-protocol-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D58609

--HG--
rename : remote/targets/Targets.jsm => remote/targets/TargetList.jsm
extra : moz-landing-system : lando
2020-01-06 09:32:09 +00:00
Henrik Skupin 5a966347fc Bug 1600053 - [remote] Implement IO.read. r=remote-protocol-reviewers,baku,ato,maja_zf
This patch implements the IO.read() method to allow
reading streams for files and blobs.

Therefor all the methods in the IO domain need a registry
for streams. Those have to be stored globally because
they need to be kept existent across different client
connections.

Differential Revision: https://phabricator.services.mozilla.com/D55968

--HG--
extra : moz-landing-system : lando
2019-12-16 16:17:59 +00:00
Henrik Skupin 162084495c Bug 1600053 - [remote] Add registry for managing references to streams. r=remote-protocol-reviewers,maja_zf
Differential Revision: https://phabricator.services.mozilla.com/D57304

--HG--
extra : moz-landing-system : lando
2019-12-16 16:17:47 +00:00
Andreas Tolfsen 36f394af15 bug 1543115: remote, toolkit: bootstrap from Rust; r=remote-protocol-reviewers,maja_zf
This bootstraps the remote agent from Rust so that we have access
to write to stderr using the eprintln!() macro.  There is a future
intention to expand Rust usage in the remote agent by delegating
CDP and WebDriver Bi-Di protocol schema validation to serde.

The Rust port is faithful to the JS version in terms of functionality,
and in some places improves on the original design by enforcing
a strict division between flag handling code on one hand, and the
remote agent server on the other.

Differential Revision: https://phabricator.services.mozilla.com/D50289

--HG--
extra : moz-landing-system : lando
2019-11-22 08:03:21 +00:00
Henrik Skupin 727713505e Bug 1595697 - [remote] Implement basic support for Emulation.setUserAgentOverride. r=remote-protocol-reviewers,maja_zf
This patch implements setting the user agent only. Support for
accepted language, and platform will be done in a follow-up bug.

Differential Revision: https://phabricator.services.mozilla.com/D52831

--HG--
extra : moz-landing-system : lando
2019-11-18 10:07:38 +00:00
Henrik Skupin e19b0aa009 Bug 1591922 - [remote] Page.bringToFront has to wait for activate and focus events. r=remote-protocol-reviewers,ato
Differential Revision: https://phabricator.services.mozilla.com/D52000

--HG--
rename : remote/domains/parent/target/TabManager.jsm => remote/TabManager.jsm
extra : moz-landing-system : lando
2019-11-07 14:47:53 +00:00
Andreas Tolfsen ea1f27965e bug 1591927: remote: implement Security.setIgnoreCertificateErrors; r=remote-protocol-reviewers,maja_zf
This implements an all-or-nothing insecure sweeping override that
bypasses security exceptions when loading documents with invalid
or otherwise bad TLS certificates.

Differential Revision: https://phabricator.services.mozilla.com/D50838

--HG--
extra : moz-landing-system : lando
2019-11-02 18:08:56 +00:00
Henrik Skupin 513521f536 Bug 1585272 - [remote] Register ChannelEventSinkFactory only once, and allow for multiple client connections. r=remote-protocol-reviewers,maja_zf
To allow for multiple client connections the ChannelEventSinkFactory
class only has to be registered once. By reference counting consumers
of this factory it can be made sure to only unregister it once no
consumers of the factory exist anymore.

With this refactoring we basically allow multiple client connections
to our CDP implementation.

Differential Revision: https://phabricator.services.mozilla.com/D49329

--HG--
extra : moz-landing-system : lando
2019-10-16 20:23:05 +00:00
Julian Descottes e64c2ab141 Bug 1545724 - Add support for javascriptDialog APIs in Page domain r=remote-protocol-reviewers,whimboo,ochameau
Depends on D37168

Differential Revision: https://phabricator.services.mozilla.com/D37368

--HG--
extra : moz-landing-system : lando
2019-08-01 12:25:57 +00:00
Alexandre Poirot 111854b5a5 Bug 1563689 - Revamp how targets are watched and reported. r=remote-protocol-reviewers,ato,jdescottes
* TabObserver is rather an helper class of Targets rather than RemoteAgent.
  Targets is the class which holds all the targets and reports about their
  creation and destructor. It feels legitimate to have it directly integrate
  with TabObserver.
* To better sort of the files. i.e. avoid having "random files" in /remote/
  I'm renaming and moving TabObserver according to its usage.
* We were emitting "connect" and "disconnect" event when a target was created
  or destroyed. But this is misleading as there is no connection to anything
  being made. Only later, a CDP client might connect to a target HTTP endpoint
  and initiate a connection. These events are making this hard to understand
  that the connection actually happens when Target.handle is called.

Differential Revision: https://phabricator.services.mozilla.com/D37043

--HG--
rename : remote/WindowManager.jsm => remote/targets/TabObserver.jsm
extra : moz-landing-system : lando
2019-07-18 12:30:10 +00:00
Alexandre Poirot 370bc3f1f2 Bug 1563692 - Move all CDP's JSON packet handling to Connection. r=remote-protocol-reviewers,jdescottes,ato
This helps sharing a single implementation of how the JSON objects
are read and written from/to the WebSocket connection.
Also, by delegating the command calls to the Session via `Session.execute`
and expecting a promise with a resolution or rejection, we make error
handling of command calls clearer and unified.

Differential Revision: https://phabricator.services.mozilla.com/D37046

--HG--
extra : moz-landing-system : lando
2019-07-11 17:45:29 +00:00
Alexandre Poirot 6713234855 Bug 1563685 - Rename WebSocket.jsm and drop unused accept method. r=remote-protocol-reviewers,jdescottes,ato
Differential Revision: https://phabricator.services.mozilla.com/D37039

--HG--
rename : remote/server/WebSocket.jsm => remote/server/WebSocketHandshake.jsm
extra : moz-landing-system : lando
2019-07-09 09:36:14 +00:00
shindli 351e9a95ce Backed out 2 changesets (bug 1563685) for causing bc perma failures in browser/base/content/test/static/browser_all_files_referenced.js CLOSED TREE
Backed out changeset 10109cbe9641 (bug 1563685)
Backed out changeset 6525d810b0b0 (bug 1563685)

--HG--
rename : remote/server/WebSocketHandshake.jsm => remote/server/WebSocket.jsm
2019-07-08 22:25:34 +03:00
Alexandre Poirot 22a355f138 Bug 1563685 - Rename WebSocket.jsm and drop unused accept method. r=remote-protocol-reviewers,jdescottes,ato
Differential Revision: https://phabricator.services.mozilla.com/D37039

--HG--
rename : remote/server/WebSocket.jsm => remote/server/WebSocketHandshake.jsm
extra : moz-landing-system : lando
2019-07-08 15:03:10 +00:00
Alexandre Poirot 7c4f974fe1 Bug 1552325 - Implement Network.requestWillBeSent. r=remote-protocol-reviewers,ato
Differential Revision: https://phabricator.services.mozilla.com/D36008

--HG--
extra : moz-landing-system : lando
2019-06-28 08:16:46 +00:00
Julian Descottes 21c37aac79 Bug 1543142 - Implement basic dispatchKeyEvent in parent Input domain r=ato
Differential Revision: https://phabricator.services.mozilla.com/D36044

--HG--
extra : moz-landing-system : lando
2019-06-27 14:47:18 +00:00
Julian Descottes 2456aa785c Bug 1535102 - Implement Page.bringToFront and introduce parent Page domain r=ato
Differential Revision: https://phabricator.services.mozilla.com/D32538

--HG--
extra : moz-landing-system : lando
2019-05-27 08:52:03 +00:00
Alexandre Poirot 2797f9402a Bug 1548102 - Coordinate Page.frameNavigated and Runtime.executionContextDestroyed/Created events. r=remote-protocol-reviewers,ato
Differential Revision: https://phabricator.services.mozilla.com/D30237

--HG--
extra : moz-landing-system : lando
2019-05-14 15:18:51 +00:00
Alexandre Poirot fcb2aa8735 Bug 1543099 - Implement Runtime.evaluate. r=remote-protocol-reviewers,ato
Differential Revision: https://phabricator.services.mozilla.com/D27525

--HG--
extra : moz-landing-system : lando
2019-05-02 11:55:55 +00:00
Andreas Tolfsen d3121dd02c bug 1546714: remote: map Remote Protocol :: {DOM, Input} bug components; r=ochameau
Patch unfortunately has to add a few domain stubs so that mach does
not complain about not finding any files associated with these new
bug components.

Differential Revision: https://phabricator.services.mozilla.com/D28688

--HG--
extra : moz-landing-system : lando
2019-04-25 14:27:15 +00:00
Andreas Tolfsen 6f0a882a05 bug 1543679: remote: remove unused server files; r=ochameau,yulia
These files became redundant after we started serving WebSocket
connections from the HTTPD.

This fixes the test
browser/base/content/test/static/browser_all_files_referenced.js,
which checks for unreferenced JSMs.

Differential Revision: https://phabricator.services.mozilla.com/D27247

--HG--
extra : moz-landing-system : lando
2019-04-15 14:06:25 +00:00
Alexandre Poirot 26d0c79caa Bug 1536888 - Move the remote agent to a JSM. r=ato
This will later help register the component statically in bug 1536862.
And already ease using the remote agent from other JSM files.

Differential Revision: https://phabricator.services.mozilla.com/D24227

--HG--
rename : remote/RemoteAgent.js => remote/RemoteAgent.jsm
extra : moz-landing-system : lando
2019-03-22 09:46:50 +00:00
Alexandre Poirot 8f9717d1e8 Bug 1536794 - Implement a base Target class. r=ato
In this revision it only helps sharing `handle`.
But in a followup changeset, it will also help closing all the connections
and justify the `sessions` map we keep around.

Differential Revision: https://phabricator.services.mozilla.com/D24219

--HG--
rename : remote/targets/MainProcessTarget.jsm => remote/targets/Target.jsm
extra : moz-landing-system : lando
2019-03-21 14:17:21 +00:00
Alexandre Poirot a7f9d31d4c Bug 1533682 - Implements empty domains used by puppeteer. r=ato
Puppetteer enable all these domains. Implement enable methods in order to prevent it from crashing on that.

Depends on D22695

Differential Revision: https://phabricator.services.mozilla.com/D22696

--HG--
rename : remote/domains/ContentProcessDomains.jsm => remote/domains/content/Emulation.jsm
rename : remote/domains/ContentProcessDomains.jsm => remote/domains/content/Network.jsm
rename : remote/domains/ContentProcessDomains.jsm => remote/domains/content/Performance.jsm
rename : remote/domains/ContentProcessDomains.jsm => remote/domains/content/Runtime.jsm
rename : remote/domains/ContentProcessDomains.jsm => remote/domains/content/Security.jsm
extra : moz-landing-system : lando
2019-03-11 12:51:09 +00:00
Alexandre Poirot 2d9789224a Bug 1533679 - Implement very first Target domains. r=ato
Empty methods that are necessary to make puppeteer.connect to pass without throwing.

Depends on D22692

Differential Revision: https://phabricator.services.mozilla.com/D22693

--HG--
rename : remote/domains/ParentProcessDomains.jsm => remote/domains/parent/Target.jsm
extra : moz-landing-system : lando
2019-03-10 12:51:11 +00:00
Alexandre Poirot 416760c48b Bug 1533679 - Differentiate Sessions and Targets bound to a browser-element from the others. r=ato
The Session used by MainProcessTarget isn't bound to any browser-element
and so do not use any of the message manager to pipe message to the content process.
Same for Target, the MainProcessTarget doesn't expose any browsing-context-related attribute.

Depends on D22691

Differential Revision: https://phabricator.services.mozilla.com/D22692

--HG--
rename : remote/sessions/Session.jsm => remote/sessions/TabSession.jsm
rename : remote/targets/Target.jsm => remote/targets/TabTarget.jsm
extra : moz-landing-system : lando
2019-03-10 12:51:09 +00:00
Alexandre Poirot cf6ef6bab7 Bug 1533679 - Implement /json/version. r=ato
Introduces a new kind of target "main-process",
which is not bound to any particular browser-element/browsing-context.
This implements only a subtest of domains and typical won't support the "content" ones.

This will require some more work in order to acknowledge having multiple kinds of targets.
We will also have "worker", "addon" and remoted-frames which will be very similar to tabs.

Depends on D22690

Differential Revision: https://phabricator.services.mozilla.com/D22691

--HG--
extra : moz-landing-system : lando
2019-03-10 12:51:49 +00:00
Alexandre Poirot e795d282ef Bug 1533679 - Make content process domains to inherit from specialized ContentProcessDomain class. r=ato
Remove content, docShell and chromeEventHandler attribute from base Domain class
as these fields only work for domains implemented in the content process and
attached to a browsing context/document.
For "global" domains like Target or Browser, that are not bound to any document,
these properties won't work.

Depends on D22687

Differential Revision: https://phabricator.services.mozilla.com/D22688

--HG--
rename : remote/domains/Domain.jsm => remote/domains/ContentProcessDomain.jsm
extra : moz-landing-system : lando
2019-03-10 12:51:01 +00:00
Alexandre Poirot 2d957cfacd Bug 1533679 - Move session modules to a dedicated sessions folder. r=ato
This is going to help have different kind of session par target kind.

Depends on D22686

Differential Revision: https://phabricator.services.mozilla.com/D22687

--HG--
rename : remote/ContentProcessSession.jsm => remote/sessions/ContentProcessSession.jsm
rename : remote/Session.jsm => remote/sessions/Session.jsm
rename : remote/frame-script.js => remote/sessions/frame-script.js
extra : moz-landing-system : lando
2019-03-10 12:50:59 +00:00
Alexandre Poirot b87adfb2ba Bug 1533679 - Move targets modules to a dedicated targets folder. r=ato
This is going to help introduce multiple kind of targets.

Depends on D22685

Differential Revision: https://phabricator.services.mozilla.com/D22686

--HG--
rename : remote/Target.jsm => remote/targets/Target.jsm
rename : remote/Targets.jsm => remote/targets/Targets.jsm
extra : moz-landing-system : lando
2019-03-10 12:50:57 +00:00
Andreas Tolfsen c01f3dece0 bug 1523104: remote: upgrade to WebSocket on existing HTTPD; r=ochameau
Rather than spinning up a separate WebSocket listener for each target, this
enables us to serve WebSocket connections from the original HTTPD that we serve
the rest of the JSON API from.
2019-03-08 16:28:07 +00:00
Alexandre Poirot ed8224a660 bug 1523104: remote: use toolkit's event emitter; r=ato 2019-03-08 16:27:41 +00:00
Alexandre Poirot f93f68ae7d bug 1523104: remote: rename Prefs.jsm to match its exported symbol; r=ato
--HG--
rename : remote/Prefs.jsm => remote/RecommendedPreferences.jsm
2019-03-08 16:27:38 +00:00
Alexandre Poirot 8a01f77453 bug 1523104: remote: allow Domains to be implemented in either parent or content processes; r=ato 2019-03-08 16:27:15 +00:00
Andreas Tolfsen 0431233f04 bug 1523104: remote: drop protocol schema validation; r=ochameau 2019-03-08 16:27:07 +00:00
Andreas Tolfsen 01e6c6d438 bug 1523104: remote: move Targets class to separate module; r=ochameau 2019-03-08 16:26:59 +00:00
Alexandre Poirot c9dfbc96b8 bug 1523104: remote: remove unused modules; r=ato 2019-03-08 16:26:37 +00:00