Both the Cache.get() and Cache.put() method have a TTL (time to live) parameter. You use this parameter to specify, roughly, the minimum duration for which you want the value to remain in the cache. However, values are not guaranteed to stay in the cache for the duration represented by the TTL parameter.