-
Notifications
You must be signed in to change notification settings - Fork 23
Open
Description
$manager = new \Ko\ProcessManager();
for ($i = 0; $i < 10; $i++) {
$manager->fork(function(\Ko\Process $p) use ($i) {
echo 'Hello from ' . $p->getPid();
sleep(1);
})->onSuccess(function() {
echo 'end';
})->onError(function() {
echo 'fail end';
});
}
$manager->wait();
OnSuccess / onError callbacks don't work if call wait() on process manager. If call wait () for each process handles call correct, but not parallel
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels