Use mutable map in source-actor reducer
Categories
(DevTools :: Debugger, task)
Tracking
(firefox111 fixed)
| Tracking | Status | |
|---|---|---|
| firefox111 | --- | fixed |
People
(Reporter: ochameau, Assigned: ochameau)
References
Details
Attachments
(1 file, 1 obsolete file)
Each time a new source actor is registered, we clone the whole map of all the actors:
https://searchfox.org/mozilla-central/rev/11cf68787bd00edfa7ac6a0ecd07794698cdebdc/devtools/client/debugger/src/reducers/source-actors.js#23-30
whereas it isn't really necessary and can be a very big performance issue.
| Assignee | ||
Comment 1•2 years ago
|
||
Also stop modifying source actor objects by putting breakable lines on it.
Ideally source actors should be immutable object. There is only sourceMapURL left.
And clarified the fact that we are having source actor IDs everywhere and never a Source ID.
Updated•2 years ago
|
Comment 3•2 years ago
|
||
Backed out changeset afdded1ef7c3 (Bug 1814609) for causing devtools failures on browser_aboutdebugging_serviceworker_console.js.
Backout link
Push with failures <--> dt6
Failure Log
| Assignee | ||
Comment 4•2 years ago
|
||
Should be fixed in the new revision. I missed a change in create.js.
Comment 6•2 years ago
|
||
| bugherder | ||
| Assignee | ||
Comment 7•2 years ago
|
||
- Remove the usage of PROMISE action, which isn't used
- Remove the memoizedAction as the reducer is already memoizing the breakableLines
All of this is only useful if we call setBreakableLines concurrently while
this is already in process of being loading.
This may still be theoriticaly possible between newSources and select actions.
But we should rather better coordinate when we pull breakable lines rather than
introduce such complexity. i.e. reduce the number of callsites requiring to load them.
Comment 8•2 years ago
|
||
A patch has been attached on this bug, which was already closed. Filing a separate bug will ensure better tracking. If this was not by mistake and further action is needed, please alert the appropriate party. (Or: if the patch doesn't change behavior -- e.g. landing a test case, or fixing a typo -- then feel free to disregard this message)
Comment 9•2 years ago
|
||
Comment on attachment 9316334 [details]
Bug 1814609 - [devtools] Simplify source actor breakable line computation.
Revision D169072 was moved to bug 1814608. Setting attachment 9316334 [details] to obsolete.
Description
•