set¶
-
async
AsyncRedisCache.set(key: str, value: Any, timeout: Optional[int] = 300)[source]¶ Set the cache key
keyto the valuevalue, and automatically expire the key aftertimeoutseconds from now.If
timeoutisNone, then the key will never expire (unless the cache implementation loses it’s persistence, e.g. memory caches with no disk writes).