service worker should maybe not timeout during FetchEvent.respondWith()

RESOLVED DUPLICATE of bug 1302715

Status

()

defect
RESOLVED DUPLICATE of bug 1302715
4 years ago
2 years ago

People

(Reporter: bkelly, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Recently we added a timeout to our service worker lifetimes.  If a waitUntil() takes too long, then the browser kills the service worker.  We also do this for respondWith().

The main goal here is to prevent script from doing things like bitcoin mining in the background while the user doesn't have the page open in a window.  This is mainly a concern for waitUntil().

For respondWith(), however, this is less of a concern.  You can only ever get a FetchEvent for an origin if a window is open for that origin.

On the flip side, Catalin points out that script can do bogus things like respondWith(new Promise()) which never resolves.  We still need to handle that somehow.

For reference, I believe chrome does not timeout respondWith().
See Also: → 1378587
Duping this to bug 1302715.  They are basically the same, but that bug has more commentary in it.
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1302715
You need to log in before you can comment on or make changes to this bug.