get cache ttl

This block is part of the redis group and was last modified in core v15.0.0.

Redis Key Selection Required

This block relies on a Redis key to perform its redis releated actions. You must manually select the Redis key you want to use in the flow in the blueprint using the Redis key selector modal. To access the modal, click the white button on the block.

get cache ttl v11.0.0 Updated v15.0.0

get the time to live in seconds

In pins 0 + flow
  • flow
    flow
Out pins 4 + flow
  • flow
    flow
  • TTL
    number

    Current time to live in seconds. Redis' own sentinels are passed through: -1 when the key exists but has no expiry, -2 when the key does not exist.

  • exists v15.0.0
    condition

    False when the key does not exist (TTL -2).

  • has expiry v15.0.0
    condition

    False when the key exists but never expires (TTL -1), or when it does not exist at all.

  • key v15.0.0
    value

    The resolved cache key.

redis

A typical wiring for get cache ttl: a function trigger starts the flow; the flow out pin feeds debug.

Studio canvas example for the get cache ttl block: typical wiring for get cache ttl.

Version history

Introduced in v11.0.0.

Last modified in v15.0.0.

v13.0.6 This block or one of its pins was updated in v13.0.6, click here to see the release notes.
Back to redis Return to the main group to view all sub-groups Back to redis Return to the group to view all blocks within this group