Cache
Cache Stores
MemoryStore
Azu.configure do |config|
config.cache = Azu::Cache::MemoryStore.new
endRedisStore
Azu.configure do |config|
config.cache = Azu::Cache::RedisStore.new(
url: ENV["REDIS_URL"]
)
endCache Methods
set
get
fetch
delete
exists?
clear
increment
decrement
expire
RedisStore-Specific Methods
delete_matched
ttl
Cache Patterns
Cache-Aside
Write-Through
Cache Stampede Prevention
Configuration Example
See Also
Last updated
Was this helpful?
