Summary
The Cache driver interface only has basic Set/Get/Delete/Keys/FlushAll. It's missing TTL expiration, atomic counters, and pub/sub — the most fundamental Redis features.
What's Missing
TTL / Expiration
- SetWithTTL (set key with expiration)
- GetTTL / SetTTL / Persist (manage key expiration)
- Expired key auto-cleanup
Atomic Counters
- Incr / Decr / IncrBy / DecrBy
- IncrByFloat
Pub/Sub
- Subscribe / Unsubscribe / Publish
- PSubscribe (pattern-based)
Data Structures (stretch)
- LPush / RPush / LPop / RPop / LRange (Lists)
- SAdd / SRem / SMembers / SIsMember (Sets)
- HSet / HGet / HDel / HGetAll (Hashes)
Provider Mapping
| Feature |
AWS ElastiCache |
Azure Cache for Redis |
GCP Memorystore |
| TTL |
EXPIRE/TTL |
EXPIRE/TTL |
EXPIRE/TTL |
| Counters |
INCR/DECR |
INCR/DECR |
INCR/DECR |
| Pub/Sub |
Pub/Sub |
Pub/Sub |
Pub/Sub |
Why This Matters
Acceptance Criteria
Summary
The Cache driver interface only has basic Set/Get/Delete/Keys/FlushAll. It's missing TTL expiration, atomic counters, and pub/sub — the most fundamental Redis features.
What's Missing
TTL / Expiration
Atomic Counters
Pub/Sub
Data Structures (stretch)
Provider Mapping
Why This Matters
Acceptance Criteria
cache/driver/driver.go