Closed Bug 1800120 Opened 4 years ago Closed 5 months ago

Remove CreateWindowInDifferentProcess

Categories

(Core :: DOM: Content Processes, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
154 Branch
Tracking Status
firefox-esr140 --- fixed
firefox153 --- fixed
firefox154 --- fixed

People

(Reporter: nika, Assigned: nika)

References

Details

Attachments

(9 external files, 3 obsolete files)

This message was used with e10s in order to allow noopener windows to load into a different content process than the window they were opened from (send, recv). With Fission, the method was disabled, as process selection could now happen during navigation, making it much less relevant.

Since Fission shipped on Desktop, this method has only been used on Android, in order to distribute load between multi-e10s content processes, and Android has been slowly moving towards using Fission as well.

This bug tracks removing CreateWindowInDifferentProcess completely, reducing maintenance burden, and using the process isolation process selection logic to encourage distributing documents between content processes instead.

This will allow us to continue to spread load between processes after the other
changes in this bug, both with and without Fission. This is done because
replacing BrowsingContext forces process selection to re-run and potentially
select a different process than the one the initial about:blank page was
rendered in. In the case of these noopener pop-up windows, that process will be
the process which opened the pop-up.

In the next part the non-fission solution to this problem will be removed.

After the changes in part 1, it no longer brings any benefit to non-fission
callers either, so can be removed completely.

Depends on D161831

The only uses of these xpcom methods from C++ were to implement
CreateWindowInDifferentProcess, which has been removed in the previous part.
This allows some simplification in the nsIBrowserDOMWindow implementations.

It should also be possible to merge createContentWindow and
createContentWindow[InFrame] however there are some slight potential
behaviour differences right now, and I want to leave that to another bug.

Depends on D161832

Attachment #9302935 - Attachment is obsolete: true
Attachment #9302936 - Attachment is obsolete: true
Attachment #9302937 - Attachment is obsolete: true

This method is now dead code, as we have shipped fission.autostart on
all platforms since bug 1998306, and CreateWindowInDifferentProcess is
disabled when Fission is disabled.

This is intended to be a fairly straightforward change to remove the
unnecessary IPC call, and does not clean up the implementation to remove
the now-dead codepaths from CommonCreateWindow. That is done in part 2.

Attachment #9575201 - Attachment description: Bug 1800120 - Part 1: Remove CreateWindowInDifferentProcess, r=smaug! → Bug 1800120 - Part 1: Remove CreateWindowInDifferentProcess, r=vhilla!
Attachment #9575202 - Attachment description: Bug 1800120 - Part 2: Remove now-dead parameters in CommonCreateWindow, r=smaug! → Bug 1800120 - Part 2: Remove now-dead parameters in CommonCreateWindow, r=vhilla!
Pushed by smolnar@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/ec10ed016f0b https://hg.mozilla.org/integration/autoland/rev/f1b4c3b4b577 Revert "Bug 1800120 - Part 2: Remove now-dead parameters in CommonCreateWindow, r=vhilla" for causing wpt failures
Depends on: 2037229
Flags: needinfo?(nika)
No longer blocks: 2023743
Attachment #9575201 - Attachment description: Bug 1800120 - Part 1: Remove CreateWindowInDifferentProcess, r=vhilla! → Bug 1800120 - Part 1: Remove CreateWindowInDifferentProcess, r=smaug!
Attachment #9575202 - Attachment description: Bug 1800120 - Part 2: Remove now-dead parameters in CommonCreateWindow, r=vhilla! → Bug 1800120 - Part 2: Remove now-dead parameters in CommonCreateWindow, r=smaug!

This patch updates the expectations for window-open-popup-behavior.html
on Android to reflect the fact that many of these tests appear to have
only been passing due to Android using CreateWindowInDifferentProcess.

Now that codepath has been removed, the test is now failing more
consistently across platforms.

I also removed the pass cases for linux-nofis, though I don't think we
run that configuration in treeherder anymore off the top of my head.

It appears that we fail this test due to a fundamental mismatch between
our implementation and the WPT. Specifically it appears the test expects
that specifying noopener/noreferrer overrides all other window open
options, and always forces the document to open in a tab, not a popup.
We always respect the specified options even if noopener is set.

Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 154 Branch

This method is now dead code, as we have shipped fission.autostart on
all platforms since bug 1998306, and CreateWindowInDifferentProcess is
disabled when Fission is disabled.

This is intended to be a fairly straightforward change to remove the
unnecessary IPC call, and does not clean up the implementation to remove
the now-dead codepaths from CommonCreateWindow. That is done in part 2.

Original Revision: https://phabricator.services.mozilla.com/D297450

Attachment #9606294 - Flags: approval-mozilla-beta?
Attachment #9606295 - Flags: approval-mozilla-beta?

firefox-beta Uplift Approval Request

  • User impact if declined/Reason for urgency: Removal of unnecessary IPC surface.
  • Code covered by automated testing?: yes
  • Fix verified in Nightly?: yes
  • Needs manual QE testing?: no
  • Steps to reproduce for manual QE testing:
  • Risk associated with taking this patch: low
  • Explanation of risk level: Removes unnecessary IPC surface which is only used on disabled configurations.
  • String changes made/needed?: None
  • Is Android affected?: yes
Attachment #9606296 - Flags: approval-mozilla-beta?

This patch updates the expectations for window-open-popup-behavior.html
on Android to reflect the fact that many of these tests appear to have
only been passing due to Android using CreateWindowInDifferentProcess.

Now that codepath has been removed, the test is now failing more
consistently across platforms.

I also removed the pass cases for linux-nofis, though I don't think we
run that configuration in treeherder anymore off the top of my head.

It appears that we fail this test due to a fundamental mismatch between
our implementation and the WPT. Specifically it appears the test expects
that specifying noopener/noreferrer overrides all other window open
options, and always forces the document to open in a tab, not a popup.
We always respect the specified options even if noopener is set.

Original Revision: https://phabricator.services.mozilla.com/D308619

This method is now dead code, as we have shipped fission.autostart on
all platforms since bug 1998306, and CreateWindowInDifferentProcess is
disabled when Fission is disabled.

This is intended to be a fairly straightforward change to remove the
unnecessary IPC call, and does not clean up the implementation to remove
the now-dead codepaths from CommonCreateWindow. That is done in part 2.

Original Revision: https://phabricator.services.mozilla.com/D297450

Attachment #9607273 - Flags: approval-mozilla-esr140?
Attachment #9607274 - Flags: approval-mozilla-esr140?

firefox-esr140 Uplift Approval Request

  • User impact if declined/Reason for urgency: Removal of unnecessary IPC surface.
  • Code covered by automated testing?: yes
  • Fix verified in Nightly?: yes
  • Needs manual QE testing?: no
  • Steps to reproduce for manual QE testing:
  • Risk associated with taking this patch: low
  • Explanation of risk level: Removes unnecessary IPC surface which is only used on disabled configurations.
  • String changes made/needed?: None
  • Is Android affected?: yes
Attachment #9607275 - Flags: approval-mozilla-esr140?

This patch updates the expectations for window-open-popup-behavior.html
on Android to reflect the fact that many of these tests appear to have
only been passing due to Android using CreateWindowInDifferentProcess.

Now that codepath has been removed, the test is now failing more
consistently across platforms.

I also removed the pass cases for linux-nofis, though I don't think we
run that configuration in treeherder anymore off the top of my head.

It appears that we fail this test due to a fundamental mismatch between
our implementation and the WPT. Specifically it appears the test expects
that specifying noopener/noreferrer overrides all other window open
options, and always forces the document to open in a tab, not a popup.
We always respect the specified options even if noopener is set.

Original Revision: https://phabricator.services.mozilla.com/D308619

Attachment #9606294 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9606295 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9606296 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9607273 - Flags: approval-mozilla-esr140? → approval-mozilla-esr140+
Attachment #9607274 - Flags: approval-mozilla-esr140? → approval-mozilla-esr140+
Attachment #9607275 - Flags: approval-mozilla-esr140? → approval-mozilla-esr140+
QA Whiteboard: [qa-triage-done-c154/b153]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: