I am trying to figure out how a working service works regarding cache headers in responses. Now I have implemented a couple of service workers, but I never had to worry about caching headers, about how long I need to cache files, etc. I am currently implementing it on a corporate website where this material really matters.
Basically when using an employee an http cache is fully cached?
Should I then create a framework to handle resource expiration / revocation, such as the http cache that was used for us? Or am I saying trash?
It would be very helpful if someone could clarify this. I see that there are 3 possible scenarios:
AND). Network request => Service employee fetch => (browser cache?) <=> Server
AT). Network request <=> (browser cache?) <=> Service selector <=> Server
WITH). Network request => Service selector <=> Server
I tested this locally and it seems like C). is the correct implementation where the developer sacrificed a cache / length header paragraph for management.
I am fine with this, I just want it to clear up before I run away and create the basis for reading and observing the caching headers in the worker.
source
share