Technologies/Redis/redis.keyspace.avg_ttl
RedisRedisMetric

redis.keyspace.avg_ttl

Average TTL of keys with an expiration
Dimensions:None
Available on:DatadogDatadog (1)Native (1)PrometheusPrometheus (1)

Summary

Average TTL in milliseconds across all keys with expiration set in a database. This metric helps validate that TTL settings align with data lifecycle requirements. Unexpectedly high averages may indicate TTLs are too long, causing memory bloat, while very low averages could mean cache entries expire before being useful. Track trends to detect configuration drift or application changes affecting key lifetime management.

Interface Metrics (3)
DatadogDatadog
Average TTL of keys with an expiration
Dimensions:None
Native
Average TTL of keys with an expiration
Dimensions:None
PrometheusPrometheus
Average TTL of keys with an expiration
Dimensions:None
Related Insights (1)
Expiring Keys Without TTL Monitoring Causes Memory Leakswarning

When redis.persist count is high relative to redis.db.expires, many keys lack TTLs and will accumulate indefinitely, causing memory growth. redis.keyspace.avg_ttl can indicate if TTL values are too long for workload patterns.