Networking·Intermediate·Conceptual·1 min read
What does Vary do?
Short interview answer
It tells caches which request headers helped select the representation, making them part of the cache key. Missing Vary can serve the wrong encoding or origin-specific response; excessive Vary fragments the cache.
Key takeaway
Explain the underlying mental model clearly, then support it with a concrete example and its trade-offs.