Allow loading a Script without recreating the WorkerScriptLoader
Categories
(Core :: DOM: Workers, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox106 | --- | fixed |
People
(Reporter: yulia, Assigned: yulia)
References
Details
Attachments
(5 files)
Currently, the WorkerScriptLoader is recreated, along with a sync loop, every time a script is loaded. This doesn't really work for modules, which are not synchronous but async, and we need to wait on a promise being resolved, not for execution to be continued.
We don't need to block execution with a syncloop, and in a sense having a sync loop makes it more complicated. Instead we handle the initialization and running of all of the modules in one go -- kind of like a single concatenated script. To reflect that model, we need a way to start loading a script which does not create a new syncloop. We can reuse the root module's sync loop, and then trigger execution of the root module once all of the loading is complete.
Getting there requires that we have a well formed pipeline of initializing single script loading.
Assignee | ||
Comment 1•1 year ago
|
||
Assignee | ||
Comment 2•1 year ago
|
||
Depends on D147318
Updated•1 year ago
|
Assignee | ||
Comment 3•1 year ago
|
||
Assignee | ||
Comment 4•1 year ago
|
||
This relates to 1784482, in that it allows modules to pass through the scriptloader independently.
This was a small bug that I caught in the wpt tests. I didn't have a better segment to put it under
so it is here.
Assignee | ||
Comment 5•1 year ago
|
||
This will be used by child modules. This is currently not used, but it will be in modules. I can
move this over to the other bug, if necessary.
Updated•1 year ago
|
Pushed by ystartsev@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f1f81f81af17 Move creation of ScriptLoadRequests into own functions; r=asuth https://hg.mozilla.org/integration/autoland/rev/13e623b3779f Do not rely on ScriptLoadRequestList in the main thread; r=asuth https://hg.mozilla.org/integration/autoland/rev/25311707288f Move shutdown operation to be always after ProcessRequests; r=asuth https://hg.mozilla.org/integration/autoland/rev/a67c04d83558 Implement corrected base URI for module redirection; r=asuth https://hg.mozilla.org/integration/autoland/rev/3bbb7bedfa0a Implement method for single script loading; r=asuth
Updated•1 year ago
|
Comment 7•1 year ago
|
||
Backed out for causing Bug 1789629.
Backout link: https://hg.mozilla.org/integration/autoland/rev/0b0be0b91acac2d96628fbf060aee84b9d7f70cf
Failure log:
https://treeherder.mozilla.org/logviewer?job_id=389739748&repo=autoland&lineNumber=3145
Pushed by ystartsev@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/50df272a06b8 Move creation of ScriptLoadRequests into own functions; r=asuth https://hg.mozilla.org/integration/autoland/rev/e65aaad7cc83 Do not rely on ScriptLoadRequestList in the main thread; r=asuth https://hg.mozilla.org/integration/autoland/rev/766a229973f9 Move shutdown operation to be always after ProcessRequests; r=asuth https://hg.mozilla.org/integration/autoland/rev/523bca0061ac Implement corrected base URI for module redirection; r=asuth https://hg.mozilla.org/integration/autoland/rev/5a65edaa747b Implement method for single script loading; r=asuth
Comment 9•1 year ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/50df272a06b8
https://hg.mozilla.org/mozilla-central/rev/e65aaad7cc83
https://hg.mozilla.org/mozilla-central/rev/766a229973f9
https://hg.mozilla.org/mozilla-central/rev/523bca0061ac
https://hg.mozilla.org/mozilla-central/rev/5a65edaa747b
Assignee | ||
Updated•1 year ago
|
Description
•