I am serving static content intended to be cached by the browser indefinitely. Chrome is caching it as expected, but is still spending time "downloading" it. I am using Chrome 46.0.2490.71.
As you can see, the content is being served from cache, but still takes 68ms for content download. This is causing the svg images to flash in on every page load, even though the file is cached.
Here is the relevant timeline information from a page load in Incognito mode:
The "Total Time" and "Event Time" fields for each of those events is zero. Replicating this with the file served locally (but still from cache) the "Receive Data" event is only seen once.
A few interesting points to note:
- Serving the same file from my local machine, with the same encoding, does not produce the same download delay.
- Switching to Incognito mode (no extensions) halves the download delay, but does not eliminate it.
- It is quicker to refresh the page, as it appears to take less time to receive a 304 response from the server than to merely load it from cache.
- Closing the dev tools does not appear to have any effect on the delay.
- IE 11, Edge, and Firefox 41 do not show any delay.
What possible causes could there be?