Skip to content

Cache

flowtask.interfaces.cache

CacheSupport

CacheSupport(*args, **kwargs)

Bases: ABC

Very Basic Cache Support using Redis

parse_duration

parse_duration(duration)

Parse a duration string and return its value in seconds.

Supported formats: - "Xs" for seconds - "Xm" for minutes - "Xh" for hours

setex async

setex(key, value, timeout=None)

setex Set the value and expiration of a Key params: key: key Name value: value of the key timeout: expiration time in seconds

setexp

setexp(key, value, timeout=None)

setexp Set the value and expiration of a Key params: key: key Name value: value of the key timeout: expiration time in seconds