Open sawaca96 opened 2 years ago
I think it would be nice if I could determine the expiration in more various ways or dynamically .
def get_expire(): # return seconds ... @ring.lru(expire_callback=get_exprie()) def foo(): return "foo"
expired_at can be cron expressoin or time or datetime.
I think cron expression is very nice.
time and datetime is ambiguous, because it cannot be repeated and can only be used once.
@ring.lru(expired_at=expired_at) def foo(): return "foo"
I think it would be nice if I could determine the expiration in more various ways or dynamically .
use expire callback
use expired_at
expired_at can be cron expressoin or time or datetime.
I think cron expression is very nice.
time and datetime is ambiguous, because it cannot be repeated and can only be used once.