[IPC Urlbar] Make the message-path controller proxy a content module and let the child own controller construction
Categories
(Firefox :: Address Bar, task)
Tracking
()
People
(Reporter: dao, Assigned: dao)
References
(Blocks 1 open bug)
Details
(Whiteboard: [sng][mcab-hnt])
Attachments
(2 files)
Updated•1 day ago
|
| Assignee | ||
Comment 1•1 day ago
|
||
UrlbarParentControllerProxy is the content-side stand-in a
UrlbarChildController holds in place of the real parent controller, so for a
content-process <moz-urlbar> it has to run in the content global. Move it from
a .sys.mjs system module to a content/ .mjs (registered in jar.mn,
dropped from moz.build) and import it statically, as content modules must be.
With the proxy built content-side, controller construction becomes symmetric:
UrlbarChildController builds #parent for both transports -- a real
UrlbarParentController in place on the direct path, a
UrlbarParentControllerProxy on the message path -- keyed on a new
UrlbarChild.usesMessagePath predicate. The actor no longer builds or caches the
direct-path controller: getOrCreateController and its #controllers WeakMap are
gone. That caching only deduped by input element, which <moz-urlbar> already
does (it runs #init() only when it has no controller and never clears it on
disconnect), so the WeakMap never served a hit.
Behavior-neutral on both paths in chrome. Worth verifying: reconnect reuse in
customize mode, which the dropped WeakMap nominally covered.
Updated•1 day ago
|
| Assignee | ||
Updated•1 day ago
|
| Assignee | ||
Comment 2•1 day ago
|
||
The comments named the two transports inconsistently ("direct" vs "in-process",
"message path" vs "message-passing path" vs "wire path"). Settle on "direct
path" (synchronous, real controller reference) and "message path" (actor
messages), since the distinction is the transport, not the process boundary --
the chrome pref-on variant runs the message path in-process. "in-process" /
"cross-process" now appear only where the process boundary itself is the point.
Updated•1 day ago
|
Updated•1 day ago
|
Description
•