AWS Certified Developer Associate DVA-C02 Practice Question
A web application is leveraging a content delivery network (CDN) to distribute images. The development team wants to implement caching optimizations to serve different image qualities based on the bandwidth of the user's connection, which is indicated by the Save-Data
client hint request header. Which strategy should be implemented to provide the most suitable image quality while optimizing for performance and bandwidth usage?
Cache different versions of images depending on the
Save-Data
header value to serve lower-quality images if the client requests data savings.Use the
Referer
header to determine the originating domain of the request and serve a universally optimized image quality based on the most frequent domain.Ignore request headers and always serve images from the same high-quality cache to all users to simplify the caching logic.
Determine the user's device type and capabilities by examining the
User-Agent
header and serve images from a cache optimized for desktop or mobile.