Re: [w3c/ServiceWorker] consider fetching service worker scripts with no-cache by default (#893)

I asked Jake about the short-circuit in step 5.3.  He suggests the short-circuit should only happen if the useCache value is the same:

>9:31 AM <wanderview> JakeA: so we are implementing the "use no-cache by default on updates" thing in gecko and a question arose
9:32 AM <wanderview> the issue defines an API like register(scriptURL, { useCache: true })
9:32 AM <wanderview> the spec also short circuits registration if the scriptURL and scope are the same as an existing registration
9:33 AM <wanderview> our question is, should that short circuit still happen even if the "useCache" value has changed?
9:33 AM <wanderview> or should there be another way for a service worker to change its "useCache" value?
9:33 AM <wanderview> JakeA: ^^^
9:34 AM <wanderview> I'm inclined to implement without any ability to change useCache to start, but thought I would get your opinion
9:34 AM <JakeA> wanderview: changing the value of useCache in .register feels like the right way to update this value
9:35 AM <JakeA> wanderview: whether it causes an immediate refetch of the SW (like changing the url does) is another question
9:35 AM <wanderview> JakeA: so the bypass check should be "if script URL, scope, and useCache value are identical, then bypass" ?
9:35 AM <JakeA> wanderview: yeah
9:36 AM <wanderview> ok
9:36 AM <wanderview> JakeA: it would be easiest if it just acted the same as if a script URL changed
9:36 AM <JakeA> wanderview: that works for me then

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/issues/893#issuecomment-263588680

Received on Tuesday, 29 November 2016 14:45:40 UTC