The if modified since type of pattern for retrieving data from cache can save significant network bandwidth and compute cycles.
The data modification time reference should be from the client side and be sent as part of the request and not assumed on server side based on a non acknowledgement type of method like simply last time the client connected to the server.
We can store the last modification time of a key in a hash and retrieve the value only if it is newer than the time client sent.
As expected there is a slight overhead, with plain get being the fastest and modification time based get the slowest. See this jupyter notebook for full working example and chart source.