class

Session::RedisStore(T)

Inherits Session::QueryableStore < Session::Store < Reference < Object

Constructors

new(client : Redis | Nil = nil, pool : ConnectionPool | Nil = nil)

Initialize with either a Redis client or a ConnectionPool When using a pool, pass it as the pool parameter When using a direct client, pass it as the client parameter

Source
with_pool(pool : ConnectionPool) : self

Convenience factory method for connection pool

Source
with_pool(config : ConnectionPoolConfig) : self

Convenience factory method for pool config

Source

Instance methods

[](key : String) : T

Core store operations

Source
[]=(key : String, session : T) : T
Source
[]?(key : String) : T | Nil
Source
all_session_ids

Get all session IDs

Source
bulk_delete

Delete all sessions matching a predicate

Source
circuit_breaker
Source
clear
Source
delete(key : String)
Source
each_session

Iterate over all sessions matching a predicate

Source
healthy?

Health check method for monitoring

Source
shutdown

Graceful shutdown

Source
size
Source
storage

Storage abstraction - must be implemented by subclasses

Source