class
Illuminate
/
Cache
/
RedisLock
You are viewing an older version of the documentation. For the latest, please visit master documentation.
RedisLock
Extends
Properties
Methods
public
__construct ( $redis , $name , $seconds , $owner ) : void
Create a new lock instance.
Parameters
- $redis Connection
- $name string
- $seconds int
- $owner string|null
public
acquire ( ) : bool
Attempt to acquire the lock.
public
release ( ) : bool
Release the lock.
public
forceRelease ( ) : void
Releases this lock in disregard of ownership.
protected
getCurrentOwner ( ) : string
Returns the owner value written into the driver for this lock.
public
getConnectionName ( ) : string
Get the name of the Redis connection being used to manage the lock.