DevTools/e10s
DevTools e10s Work
This page is for the investigation and planning of the migration of Firefox' Developer Tools to a post-electrolysis world. The DevTools team is currently in an information-gathering phase. We are investigating requirements to convert our existing tools planning for future tools to be able to communicate across process boundaries within Firefox.
Debug Protocol
Web Console
Inspector
Introduction
For the Inspector and it's associated tools, it should be possible to get an easy win by just pushing the code into the content process. The rationale for this is pretty simple: The Inspector lives very close to content and requires access to the entire DOM. Given that it could be very costly to ship the whole DOM over a process boundary using the Debug Protocol or something implemented on top of the message manager, it makes sense to move most of the Inspector code into the content process.
Requirements
There will be a need for an API to tell the content process to run a particular element or JS code in itself. Using this, we should be able to instantiate the Inspector UI as part of the content process and bootstrap it.
- need bug link
We will need a mechanism to refer to a DOM element in the content process from chrome.
Planning
First Phase - analysis
- Begin testing with patches from bug 666713 installed. I think it's safe to assume that everything the Inspector does from startup to shutdown connects with content. There won't be much news here, but could provide some interesting feedback about this analysis tool itself.
- Load the Inspector in an e10s build and watch it fail. Again, we'll learn a bit about limitations of our current implementation in e10s from this, but shouldn't be terribly surprising.
Second Phase - implementation
- Using the above API to move elements to the content process, begin migrating the Inspector's HTML panel UI to that process.
- Implement an in-content API to update the HTML panel's selection
- Decouple InspectorUI from gBrowser
- Remove references of contentWindow and contentDocument
- Implement chrome InspectorUI APIs using Message Manager.
- HighlightNode
- SelectNode
- GetAnnotation
- GetId
- GetClass
- GetLayoutInformation…