Closed Feb 9, 2025
No due date
•Closed Fully reworked the runtime public facing API to utilize fibers:
From:
use React\EventLoop\Factory;
use ReactParallel\Runtime\Runtime;
use ReactParallel\FutureToPromiseConverter\FutureToPromiseConverter;
$loop = Factory::create();
$runtime = Runtime::create(new FutureToPromiseConverter($loop));
$runtime->run(function () {
sleep(3);
return 3;
})->done(function (int $int): void {
echo $int, PHP_EOL;
});
$loop->run();To:
use ReactParallel\Runtime\Runtime;
use ReactParallel\EventLoop\EventLoopBridge;
$runtime = Runtime::create(new EventLoopBridge());
echo $runtime->run(function (): int {
sleep(3);
return 3;
}), PHP_EOL;100% complete
Issues
No results matched your search
Try a different search query. Learn more about searching and filtering issues and pull requests.