Re: [ServiceWorker] 24 hour spontaneous update doesn't seem specced (#514)

>From https://codereview.chromium.org/1283273002/, another question came up about scheduled updates by the user agents.

Do we consider the service worker's max age set by min(Cache-Control: max-age's value, 86400) a desired lifetime of a service worker? In which case, using this value for an auto-update seems fine.

On the other hand, it still sounds reasonable to use 24h rule for auto-updating a stale SW as it was. Scheduling the updates for all the installed service workers in a short timeframe only depending on the Cache-Control max-age values would be too much for the user agents I guess.

If we want to keep the 24h auto-update rule, the service worker's max age internal slot in the spec is not necessary at all. As point out by @nhiroki (https://codereview.chromium.org/1283273002/diff/20001/content/browser/service_worker/service_worker_context_request_handler.cc#newcode72), the Cache-Control max-age will cover all the cases in the network layer.

---
Reply to this email directly or view it on GitHub:
https://github.com/slightlyoff/ServiceWorker/issues/514#issuecomment-132859690

Received on Thursday, 20 August 2015 02:36:54 UTC