Hi,
I know that cookies often make pages uncacheable, but wanted to explore a particular scenario anyway…
Let’s say the server sets “Vary: Cookie”. There is a cookie named “mode”, which could be A or B. So the versions of the page are
- no cookies
- cookie “mode”==“A”
- cookie “mode”==“B”
That’s three versions of the page. It seems plausible that Fastly could cache, and serve, those versions of the page.
Continuing on, add another similar cookie “screentype”, with two choices. Now the list of all variations are:
- no cookies
- cookie “mode”==“A”
- cookie “mode”==“B”
- cookie “screentype”==“C”
- cookie “screentype”==“D”
- cookie “mode”==“A”, cookie screentype"==“C”
- cookie “mode”==“A”, cookie screentype"==“D”
- cookie “mode”==“B”, cookie screentype"==“C”
- cookie “mode”==“B”, cookie screentype"==“D”
That’s nine versions of the page.
-
With low-granularity, low-variability cookies such as these, will Fastly cache the pages or determine they are uncacheable?
-
How much variability is permitted? How many variations of the same page with different cookie values? 100? 50? 3? What is the cutoff? This is probably the main question. What is the limit.
-
When too many variations are observed, and it stops caching, does that include all versions, or are a few cookied versions still retained in cache? At least the no-cookie copy would continue to be cacheable right?
-
Are these specific answers already in the docs? (which url? If so, that might be enough)
Thanks.