stekycz / critical-section
Lightweight class supporting critical section locking
Installs: 36 596
Dependents: 1
Suggesters: 0
Security: 0
Stars: 1
Watchers: 4
Forks: 1
pkg:composer/stekycz/critical-section
Requires
- php: >=7.1
Requires (Dev)
- jakub-onderka/php-parallel-lint: ^0.9
- mockery/mockery: ^1.3
- nette/tester: ^2.3
- phpstan/phpstan: ^0.12
Suggests
Replaces
- stekycz/criticalsection: 1.0.1
This package is not auto-updated.
Last update: 2025-09-28 08:27:03 UTC
README
Description
Lightweight class supporting critical section locking in PHP.
It requires PHP >= 7.1 and no other dependency.
Example
$pdo = new PDO('...'); $driver = new Bileto\CriticalSection\Driver\PdoPgsqlDriver($pdo); $criticalSection = new Bileto\CriticalSection\CriticalSection($driver); $criticalSection->enter('Section Label'); // Perform set of steps of critical tasks $criticalSection->leave('Section Label');