kinetis / roadrunner-adapter
RoadRunner runtime adapter for Kinetis — speaks the PSR7Worker/Goridge protocol and converts to/from PSR-7, including multipart/form-data support.
Requires
- php: ^8.4
- kinetis/framework: ^1.0.0
- nyholm/psr7: ^1.8.2
- psr/http-message: ^2.0
- riverline/multipart-parser: ^2.2.2
- spiral/roadrunner-http: ^4.1
- spiral/roadrunner-worker: ^3.5
Requires (Dev)
- infection/infection: ^0.35.0
- phpstan/phpstan: ^2.2.8
- phpunit/phpunit: ^12.5.33
- spiral/roadrunner-cli: ^2.6
- vimeo/psalm: ^6.16.1
README
kinetis/roadrunner-adapter
RoadRunner runtime adapter for Kinetis
Speaks RoadRunner's own Goridge/PSR7Worker protocol — a persistent
worker loop, structurally the closest of Kinetis's four runtime adapters
to FrankenPhpAdapter's, but built on RoadRunner's own PHP worker
library rather than a raw request-handling function. Converts to/from
PSR-7, including multipart/form-data/application/x-www-form-urlencoded
support parsed in userland — the same shape kinetis/bref-adapter needs
for the identical reason: a request body here is one in-memory string
with no live php://input behind it.
There's nothing to configure or call directly: install the package, and
RuntimeDetector picks it up automatically the moment RR_MODE=http is
set in the environment — RoadRunner's own rr serve sets this itself
when it spawns the worker.
composer require kinetis/roadrunner-adapter
Two RoadRunner configuration settings are required, not optional —
http.raw_body: true, and http.max_request_size to actually bound how
large a form body can grow before this adapter parses it (there's no
SAPI here to enforce post_max_size, and RoadRunner's own default is a
generous 1000 MB):
http: address: 0.0.0.0:8080 raw_body: true max_request_size: 10
max_request_size is a separate ceiling from MAX_BODY_SIZE (Kinetis's
own env var, default 2 MiB) — the two don't automatically agree; set
MAX_BODY_SIZE=10485760 alongside max_request_size: 10 above if you
want one consistent limit.
Requires PHP 8.4+ and kinetis/framework. See
Runtime Adapters for
the full reasoning — why raw_body: true and max_request_size matter,
what's mapped and how, and the two disclosed, environment-caused
conformance gaps (a purely-numeric header name; occasional cookie
reordering) that are upstream RoadRunner behavior, not something this
package's own code can recover from.
License
MIT — see LICENSE.