Closed Bug 1636106 Opened 6 months ago Closed 5 months ago

[rel=preload] Don't cancel a preload channel and don't remove a preload from Document when all <link preload> nodes for it are removed

Categories

(Core :: Networking, enhancement, P1)

enhancement

Tracking

()

RESOLVED FIXED
mozilla78
Tracking Status
firefox78 --- fixed

People

(Reporter: mayhemer, Assigned: mayhemer)

References

(Blocks 1 open bug)

Details

(Whiteboard: [necko-triaged])

Attachments

(1 file)

Seems like there is eventually no test expecting the cancellation to happen:
https://treeherder.mozilla.org/#/jobs?repo=try&collapsedPushes=682858%2C682846%2C682608%2C682564%2C689301%2C689322%2C700450&revision=19ee1c1eddb9b6bee03cdefdd6715a8fc3629979

Note that this is actually untestable because the channel cancellation is kinda racy anyway.

This diverts from the current implementation in nsPrefetchService which cancels the channel when all <link preload> tags are removed and when the tag updates.

This will make few things simpler. Specifically, will get rid of bug 1635417 and it's possible variants with other resource types. Other reason is we can then easily coalesce CSS preloads just inside the CSS loader, using it's existing coalescing logic, because it already coalesces CSS regular (and speculative) loads and no longer need to have two coalescing approaches that would need synchronization.

No longer blocks: 1618549
Pushed by honzab.moz@firemni.cz:
https://hg.mozilla.org/integration/autoland/rev/5b51450d6aae
Do not cancel a preload channel and do not remove a preload from Document`s preloads when last <link preload> node referencing it is removed from the DOM tree or otherwise updated making it abandon the preload, r=emilio
Status: ASSIGNED → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla78
You need to log in before you can comment on or make changes to this bug.