Laravel cache remaining TTL -
i looking way access remaining ttl of redis key value pair via laravel. don't mind using either cache or redis facades (or else matter).
in api can see how return default ttl - getdefaultcachetime().
i want find remaining ttl.
for reference, redis terminal command ttl mykey
since there's command method on illuminate\redis\database class can run :
redis::command('ttl', ['yourkey']); this documented here.
Comments
Post a Comment