ThreadActor is not destroyed when worker target is destroyed
Categories
(DevTools :: Debugger, defect)
Tracking
(firefox84 fixed)
Tracking | Status | |
---|---|---|
firefox84 | --- | fixed |
People
(Reporter: ochameau, Assigned: nchevobbe)
References
Details
Attachments
(1 file)
(deleted),
text/x-phabricator-request
|
Details |
This is the same bug as bug 1672778, but for worker targets.
WorkerTargetActor isn't calling ThreadActor.exit, whereas this is the only way to fully destroy this special actor. That's because ThreadActor.destroy isn't calling Actor.destroy. Instead ThreadActor.exit does it.
So that destroying the target actor, which manages the thread actor, will call all its children actor's destroy method. But we expect to call exit.
BrowsingContext target actor has a special code to do that right:
https://searchfox.org/mozilla-central/source/devtools/server/actors/targets/browsing-context.js#1011
https://searchfox.org/mozilla-central/source/devtools/server/actors/targets/browsing-context.js#1046
https://searchfox.org/mozilla-central/source/devtools/server/actors/targets/browsing-context.js#641
https://searchfox.org/mozilla-central/source/devtools/server/actors/targets/browsing-context.js#620
We could probably benefit from cleaning up/removing this "exit" logic in favor of a unique destroy codepath. (bug 1673328)
Assignee | ||
Comment 1•4 years ago
|
||
We have to manually call ThreadActor#exit
as calling destroy
won't completely
destroy it, since it does not call Actor#destroy
, whereas ThreadActor#exit
does.
Updated•4 years ago
|
Comment 3•4 years ago
|
||
bugherder |
Description
•