hope/locker

Process locker

Installs: 15

Dependents: 0

Watchers: 1

Language: PHP

1.1.1 2014-06-10 10:12 UTC

README

Test passing Latest Stable Version

Usage

$locker = new FileLocker('large-process', ['lockDir' => '/tmp/lock']);
if ($locker->isLocked()) {
    die('Already locked');
}

$locker->lock();
... some code ...
$locker->unlock();