2017 © Pedro Peláez
 

yii2-extension yii2-redis-mutex

Yii2 Redis mutex.

image

pastuhov/yii2-redis-mutex

Yii2 Redis mutex.

  • Friday, March 25, 2016
  • by pastuhov
  • Repository
  • 1 Watchers
  • 5 Stars
  • 2,017 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 3 % Grown

The README.md

Yii2 redis mutex

Build Status Scrutinizer Code Quality Code Coverage Total Downloads, (*1)

Install

Via Composer, (*2)

``` bash $ composer require pastuhov/yii2-redis-mutex, (*3)


## Features * Deadlock free * Robust ## Disadvantages * no spinlock * non distributed ## Usage ```php $mutex = \Yii::createObject([ 'class' => \pastuhov\yii2redismutex\RedisMutex::className(), 'redis' => $redisConnection ]); $mutexName = 'lock'; if ($mutex->acquire($mutexName)) { $value++; $mutex->release($mutexName); }

Testing

$ composer test

or, (*4)

$ phpunit

Debugging

For debugging purposes use:, (*5)

$ redis-cli monitor

or, (*6)

$ tail -f tests/runtime/logs/app.log -n 1000

Security

If you discover any security related issues, please email kirill@pastukhov.su instead of using the issue tracker., (*7)

Credits

License

GNU General Public License, version 2. Please see License File for more information., (*8)

The Versions

25/03 2016

dev-master

9999999-dev https://github.com/pastuhov/yii2-redis-mutex

Yii2 Redis mutex.

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

redis mutex dog pile

25/03 2016

dev-pastuhov-patch-1

dev-pastuhov-patch-1 https://github.com/pastuhov/yii2-redis-mutex

Yii2 Redis mutex.

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

redis mutex dog pile

19/01 2016

v0.1.1

0.1.1.0 https://github.com/pastuhov/yii2-redis-mutex

Yii2 Redis mutex.

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

redis mutex dog pile