Open Bug 1903060 Opened 12 days ago Updated 5 days ago

Expose an observer notification when a data channel is created in the content process

Categories

(Core :: DOM: Networking, task, P3)

task
Points:
2

Tracking

()

People

(Reporter: Sasha, Unassigned)

References

(Blocks 6 open bugs)

Details

(Whiteboard: [necko-triaged][necko-priority-next])

While adding support for data URLs in the scope of bug 1805176, we've noticed that in the cases when data URLs requested in the content process (e.g. data URL as src for images on the page, as background images or in fetch requests inside the page) the data-channel-opened notification is sent only in the content process, where at the moment we listen to all the network related notifications in the parent process.
There are two solutions here:

  • the notification is propagated to parent process on the platform side;
  • we set up an observer in the content process on WebDriver BiDi and DevTools side.

Moving the comment from the discussion on the bug 1805176:
(In reply to Kershaw Chang [:kershaw] from comment #18)

(In reply to Alexandra Borovova [:Sasha] from comment #13)

Hi Valentin,

I have another question. :)
I've noticed that in some case (e.g. data URL as src for images on the page, as background images or in fetch requests inside the page) the data-channel-opened notification is sent only in the content process, where at the moment we listen to all the network related notifications in the parent process. Is it maybe possible to bubble them up?

Thank you in advance

Yeah, I think that's possible, but it requires some amount of work.
I assume we need to forward the data URL to parent process and open it again.

Component: WebDriver BiDi → DOM: Networking
Product: Remote Protocol → Core
Summary: Support network events using data URLs in content process → Expose an observer notification when a data channel is created in the content process

Just want to reiterate what Sasha mentioned in the description: we can also observe the notifications in content processes if needed. It's a bit more plumbing work to do on our side, but it's feasible. So if it is problematic for necko to bubble those notifications from content to parent (for performance reasons or others), that is still an option here.

See Also: → 1903496
Severity: -- → S3
Priority: -- → P3
Whiteboard: [necko-triaged][necko-priority-new]

For every DataChannel created in content proces, we create a DataChannelChild here, which means there is also a DataChannelParent created in parent process.
I think we can reuse PDataChannel to forward the notification.

Severity: S3 → N/A
Points: --- → 2
Whiteboard: [necko-triaged][necko-priority-new] → [necko-triaged][necko-priority-next]
You need to log in before you can comment on or make changes to this bug.