Hmmmmm, I don’t have the impression that Redis keeps track of TTL. It is unbound seeing that the TTL is expired.
See my earlier remarks about serving expired info by Unbound and Knot. So it emulates Redis and in the mean time it gets fresh info for the next request.
serve-expired: <yes or no> If enabled, unbound attempts to serve old responses from cache with a TTL of 0 in the response without waiting for the actual resolution to finish. The actual resolution answer ends up in the cache later on. Default is "no". serve-expired-ttl: <seconds> Limit serving of expired responses to configured seconds after expiration. 0 disables the limit. This option only applies when serve-expired is enabled. The default is 0. serve-expired-ttl-reset: <yes or no> Set the TTL of expired records to the serve-expired-ttl value after a failed attempt to retrieve the record from upstream. This makes sure that the expired records will be served as long as there are queries for it. Default is "no".