Resources aren't unwatched on target destruction
Categories
(DevTools :: Framework, defect, P1)
Tracking
(firefox79 fixed)
Tracking | Status | |
---|---|---|
firefox79 | --- | fixed |
People
(Reporter: nchevobbe, Assigned: nchevobbe)
References
Details
(Whiteboard: dt-fission-m2-mvp)
Attachments
(1 file, 2 obsolete files)
In browsingContext's destroy
function ( devtools/server/actors/targets/browsing-context.js#600,604-606 ), we're calling unwatchTargetResources
, using this._resourceWatchers.keys()
to get the resources to be unwatched.
The issue is that we never populate this._resourceWatchers
(https://searchfox.org/mozilla-central/search?q=this._resourceWatchers&path=devtools%2F&case=true®exp=false), so we pass an empty array, and as a result we don't call the destroy method of the watcher, which might lead to a leak.
Assignee | ||
Comment 1•7 months ago
|
||
This removes the unpopulated _resourceWatchers attributes from
the browsing context, and instead uses a new function on the
Resource module (unwatchAllTargetResources
)
Assignee | ||
Comment 2•7 months ago
|
||
getActor (which is called by DevToolsServer.searchAllConnectionsForActor) wasn't
returning self-managed actors.
In this patch we're adding a new findInPools method to DevToolsServerConnection
which allows to loop through the pools. We then use it to search for self-managed
actors in getActor.
Depends on D79983
Assignee | ||
Comment 3•7 months ago
|
||
Depends on D81033
Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0a2e3506a46f Unwatch resources on target destruction. r=ochameau.
Comment 5•7 months ago
|
||
Comment on attachment 9159195 [details]
Bug 1648022 - Search for self-managed pools in DevToolsServerConnection.getActor. r=ochameau.
Revision D81033 was moved to bug 1648458. Setting attachment 9159195 [details] to obsolete.
Comment 6•7 months ago
|
||
Comment on attachment 9159197 [details]
Bug 1648022 - Add a test to assert resource watcher destruction when associated target actor is destroyed. r=ochameau.
Revision D81034 was moved to bug 1648458. Setting attachment 9159197 [details] to obsolete.
Comment 7•7 months ago
|
||
bugherder |
Description
•