Esc
API Index — Namespaces, Packages, Reports, Indices
Store
Table of Contents
Interfaces
- RedisDriver
- Behavioural contract for a Redis/Valkey client lib (phpredis or predis).
- StoreBackend
- Behavioural contract every Store backend implements.
Classes
- CircuitBreakerBackend
- 3-state circuit breaker decorator for
StoreBackend. Opt-in only: applications that want "Redis down → degrade to Table cache" wrap their RedisBackend in this decorator at boot. Default behaviour is unchanged — apps that don't wrap see the same throw-on-Redis-failure semantics they had before. - MemcachedBackend
- Memcached-backed
StoreBackend. - PhpredisDriver
- phpredis-backed driver. Only instantiable when the
redisPHP extension is loaded; the adapter falls back to predis otherwise. Tests skip the phpredis-specific path when the ext isn't present (covered by CI matrix). - PredisDriver
- predis-backed driver. Pure PHP — works without ext-redis. Slower than phpredis but parity-tested against the same RedisClientTest cases.
- PubSubStopException
- Sentinel thrown from inside a
SUBSCRIBEconsumer to signal clean shutdown. - RedisBackend
- Redis/Valkey-backed
StoreBackend. - RedisClient
- Thin adapter over phpredis (preferred when ext-redis is loaded) or predis (pure-PHP fallback). The ONE place the client lib is referenced by name in ZealPHP — every other class talks to this adapter.
- RedisConnectionPool
- Per-worker pool of
RedisClientconnections. - RedisPubSub
- Per-worker pub/sub runner.
- RedisStreams
- Per-worker Redis Streams consumer runner.
- Stats
- Per-worker counter struct for Store/Counter/Pool/Subscriber observability.
- StoreException
- Thrown by every public method in the ZealPHP\Store namespace.
- TableBackend
- Default StoreBackend — wraps OpenSwoole\Table.
- TieredBackend
- Three-tier-ready hybrid backend —
TableBackendas L1 (in-process, ns latency, bounded staleness) +RedisBackendas L2 (cross-node, source of truth, ~µs to ~ms). - TypeCodec
- Backend-neutral row (de)serialization.
Enums
- DriverPreference
- Type-safe enum for
RedisClient's driver selection. Accepted byStore::defaultBackend()via the'prefer'opt and byRedisClient::__construct()'s opts array. - StoreBackendKind
- Type-safe enum for the Store backend kind.