Skip to content

andersondanilo/process-pool

Repository files navigation

PHP Process Pool

Latest Version Total Downloads CI

PHP Process Pool is a simple process pool using symfony process

use ProcessPool\ProcessPool;
use Symfony\Component\Process\Process;

function processGenerator($count) {
    for ($i = 0; $i < 10; $i++) {
        yield new Process(['sleep', $i]);
    }
}

$processes = processGenerator(10);
$pool = new ProcessPool($processes);
$pool->setConcurrency(2);
$pool->wait();

About

PHP Process Pool (Using symfony process)

Resources

License

Stars

Watchers

Forks

Packages

No packages published