System Design · Junior · Question 48 of 75
What is an ETag, and why is it needed?
- ✓Correct answer: A resource version identifier: the server responds 304 if the version hasn't changed
- 2A tag the CDN uses to detect the user's country for translation
- 3An authorization token the browser adds to every request
Explanation
The browser sends If-None-Match: <etag>, and if the resource hasn't changed, the server responds 304 Not Modified without a body - saving traffic. It's the cache revalidation mechanism used together with Cache-Control.