finds.dev← search

// the find

nunomaduro/pokio

★ 764 · PHP · MIT · updated Jul 2026

Pokio is a dead simple Asynchronous API for PHP that just works.

Pokio adds async/await syntax to PHP by forking processes via PCNTL and using FFI-backed shared memory for IPC. It's a proof-of-concept from Nuno Maduro (Pest author) intended to power parallelism inside Pest, not a general-purpose concurrency library. The API is clean and familiar if you've written JavaScript async code.

The fallback to sequential execution when PCNTL/FFI aren't available is a smart safety net — your code doesn't break on Windows or restricted environments, it just runs slower. The IPC layer using FFI shared memory instead of pipes or temp files is a meaningful performance choice. Promise chaining with then/catch/finally is properly implemented, not bolted on. Coming from the Pest maintainer means the test coverage and code style are unusually disciplined for a small library.

The README opens with a caution block telling you not to use this in production — that's not a caveat, that's the whole story. FFI + PCNTL across forked processes means shared state, signal handling, and database connections all become your problem. There's no event loop, no I/O multiplexing, no way to await network operations without blocking a forked OS process per task — this is process-based parallelism dressed up as async, which breaks down quickly at scale. With 39 forks and no published roadmap for production use, adopting this outside of Pest internals is a gamble with no obvious upside over established alternatives like spatie/async.

View on GitHub → Homepage ↗

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →