Cache.touch()
Change the expiry of an existing entry without rewriting its value.
Usage
Cache.touch(
key,
expire=None,
*,
retry=False,
)Parameters
Returns
bool-
True if the entry existed and was updated, False if it was missing or expired, or with
durable=True, if the call failed.
Raises
Timeout- Another process held the write lock for longer than timeout.
Examples
cache.touch('session:xyz', expire=1800) # 30 more minutes, if it's still there