Reasonable timeout for `plugin.fetch()` in the ServiceWorker
Currently the ServiceWorker just runs any plugin (including the initial HTTPS fetch()
) without any explicit timeouts. This is sub-optimal, for example when:
- the site is censored by
DROP
ing the packets on some firewall (instead of rejecting them); - the site is experiencing technical issues and effectively takes forever to load;
- any of the plugins (looking at you,
IPFS
) takes inordinate amount of time to return either the content, or an error.
We need to be able to wait for some time, but then just go with another plugin, before the browser times out on us.