RedisManager
Implements
Properties
$driver string
The name of the default driver.
$customCreators array
The registered custom driver creators.
$config array
The Redis server configurations.
$connections mixed
The Redis connections.
$events bool
Indicates whether event dispatcher is set on connections.
Methods
__construct ( $app , $driver , array $config ) : void
Create a new Redis manager instance.
Parameters
- $app Application
- $driver string
- $config array
connection ( $name ) : Connection
Get a Redis connection by name.
Parameters
- $name string|null
resolve ( $name ) : Connection
Resolve the given connection by name.
Parameters
- $name string|null
resolveCluster ( $name ) : Connection
Resolve the given cluster connection by name.
Parameters
- $name string
configure ( Connection $connection , $name ) : Connection
Configure the given connection to prepare it for commands.
Parameters
- $connection Connection
- $name string
parseConnectionConfiguration ( $config ) : array
Parse the Redis connection configuration.
Parameters
- $config mixed
connections ( ) : array
Return all of the created connections.
enableEvents ( ) : void
Enable the firing of Redis command events.
disableEvents ( ) : void
Disable the firing of Redis command events.
setDriver ( $driver ) : void
Set the default driver.
Parameters
- $driver string
purge ( $name ) : void
Disconnect the given connection and remove from local cache.
Parameters
- $name string|null
extend ( $driver , Closure $callback ) : $this
Register a custom driver creator Closure.
Parameters
- $driver string
- $callback Closure
__call ( $method , $parameters ) : mixed
Pass methods onto the default Redis connection.
Parameters
- $method string
- $parameters array