0.10.0 (2026-12-03)
⚠️ Breaking Changes
- 🧹 Single-Process ZTS Worker Threads: Replaced forked NTS worker processes with ZTS PHP worker threads in one server process. Release packages and container images now ship ZTS PHP. Self-hosted builds that run more than one worker or more than one pool must link ZTS PHP (
--enable-zts --disable-zend-signals); NTS builds allow one pool and clampworkersto1. Running more than one worker with OPcache enabled requires PHP 8.4.29, 8.5.14, 8.6.1, or later, #334. - 🧹 Server and Pool Configuration: Renamed
[supervisor]to[server],process_control_timeout_secstostop_timeout_secs, and[<plugin>.pool].processestoworkers. Removed[<plugin>.pool].max_memory_mband[http].io_threads. Updaterapira.tomlbecause unknown keys fail startup, #334. - 🧹 Relative Unix Socket Paths: Relative
unix:listen paths in[http],[grpc], and[observability]now resolve against the directory ofrapira.tomlinstead of the current working directory. Update relative paths or use absolute socket paths, #334. - 🧹 Observability Metrics: Removed
rapira_worker_exits_total,rapira_worker_rss_bytes, andrapira_worker_pss_bytesbecause workers run as threads in one process. Remove these series from Prometheus dashboards and alerts, #334. - 🧹 Docker Images and Bundled Extensions:
ghcr.io/rapira-rs/rapira:php8.xis now a complete Debian Trixie image with ZTS PHP instead of ascratchpayload forCOPY --from. Removed theredisextension because it is unsafe under ZTS PHP. Update Dockerfiles to base onghcr.io/rapira-rs/rapira:php8.xor:php8.x-distroless, #321, #334, #346. - 🧹 gRPC Response Metadata Ownership:
$call->getResponseMetadata()now returns the call object itself (UnaryCallorServerStreamingCall). Do not keep a reference to the returned object after finalizing the call, #275. - 🧹 HTTP Content-Length Validation:
Exchange::writeHead()now throws\ValueErrorwhencontent-lengthrepeats or is not a non-negative integer, #355.
🎯 Core
- ✨ Pool Environment Variables: Added
[http.pool.env]and[grpc.pool.env]tables with thread-localputenv()isolation. Pool variables populate$_SERVER,$_ENV,getenv(), and${NAME}inphp.ini, #300, #334. - ✨ Execution Timer Clock: Added
[<plugin>.pool].execution_clockwith"wall"(default) and"cpu"modes."cpu"measures per-thread CPU time on Linux ZTS builds so I/O waits do not consumemax_execution_time, #336. - ✨ Boot Failure Backoff: Added
[<plugin>.pool].max_boot_failures(default5,0disables the limit). Failed worker boots back off from 500 ms to 5 s and stop the server with exit code70if reached before the pool serves a request, #299. - ✨ Object Inspection API: Added
\Rapira\count_objects()and\Rapira\get_objects(array $classes = [])to inspect live PHP objects without creating strong references, #305. - ✨ Request Watchdog: Reserved
SIGRTMAXfor the per-request watchdog and exited with code124only when every worker in a pool remains blocked past the five-second grace period, #334. - 🐛 Reloads and OPcache: Coordinated
opcache_reset()across worker threads onSIGHUP/SIGUSR2, resolved symlinked deployment entrypoints per app instance, and handled OPcache scheduled restarts without killing workers, #288, #289, #290, #334. - 🐛 Session and Shutdown Handling: Saved active PHP sessions before sending responses, reported uncaught exceptions from
register_shutdown_function()in worker mode, entered the entrypoint directory per worker thread, and reported the loadedlibphpversion inX-Powered-By, #286, #287, #296, #334. - 🐛 PHP 8.6 and 8.7 Compatibility: Added support for PHP 8.6 and tracked
php-srcmaster changes, including zero-copy POST bodies viapre_request_init, #322, #343, #355. - ⚡ Worker Scheduling and Boot: Woke the most recently parked worker first for queued work and cached constant
$_SERVERentries once per worker, #303, #334.
📦 rapira pack and VFS
- ✨ Application Packing: Added
rapira pack <APP_DIR> -o <PATH>to embed a PHP application,rapira.toml, and optional--php-iniinto a 64-bit ELF or Mach-Orapiraexecutable with zstd compression and SHA-256 verification, #351. - ✨ In-Memory
/appVFS: Packed executables on PHP 8.5+ mount the application read-only at/appin memory, supporting PHP stream wrappers,stat,glob,SplFileInfo/SplFileObject,opcache.preload,open_basedir,StaticFiles,Exchange::sendFile(), and gRPC schema/token files, #351, #355. - ✨ Extract Directory Mode: Added
--extract-dir <DIR>andRAPIRA_EXTRACT_DIRto extract a packed bundle atomically to disk for PHP 8.4 or disk-backed deployments, #351. - ⚡ VFS Performance: Dropped the compressed bundle before serving, eliminated per-lookup allocations in
Vfs::lookupandVfs::glob, and mixed the bundle digest intozend_system_idforopcache.file_cache, #351.
📦 http plugin
- ✨ HTTP Middleware and Compression: Added a shared HTTP middleware interface and built-in
compressmiddleware (middleware = ["compress"]and[http.compress]) supportingzstdandgzipcontent negotiation, #334. - ⚡ Sharded I/O and Streaming Bodies: Replaced multi-process accept loops with dedicated single-threaded
LocalSetI/O shards, streamed multipart parsing and rawphp://inputbodies directly from transport chunks, and wrote largewriteBody()chunks in place, #271, #272, #274, #334. - 🐛 Spool, Sendfile, and Connection Hardening: Cleaned stale upload spool directories on startup, isolated
/appVFS and hostsendFile()roots, skipped queued classic units when clients disconnect, enforced Host/body limits, and hardened connection draining, #260, #285, #332, #351, #355.
📦 grpc plugin
- ✨ Server-Streaming RPCs: Added server-streaming support via
ServerStreamingCall::respond(\Generator)across gRPC, binary gRPC-Web, and Connect streaming, withMethodKind,HeadersAlreadyCommittedError, cancellation viaWorkDiscardedException, and nestedrespond()protection, #312, #355. - ✨ Remote Descriptor Sets: Loaded
[grpc].descriptor_setfromhttp://andhttps://URLs at startup with system CA verification, Basic auth redaction, proxy variables, and a 64 MiB limit, #306. - ✨ Reserved REST Protocol Case: Declared
Rapira\Grpc\Call\Protocol::Restas a reserved extension point on the protocol enum, #304. - 🐛 Security and Deadlines: Compared SHA-256 bearer token digests in constant time in
grpc.authand enforced call deadlines before accepting responses and across complete streams, #312, #355.
📦 static_files middleware
- 🐛 Symlink Confinement and Rename Detection: Confined static file symlinks to the configured root without traversing dot-prefixed or forbidden targets on both disk and
/appVFS, and tracked inode and device IDs to detect atomic renames with identical mtime and length, #284, #355. - ⚡ Shared Cache: Shared the file cache across the single server process with
RwLock, dispatched the VFS backend once at construction, and matched forbidden suffixes without allocating, #334, #351.
📊 Observability
- ✨ In-Process Observability: Moved
/metrics,/livez, and/readyzto a dedicated thread inside the server process and counted host-refused units inrapira_requests_totalandrapira_requests_failed_total, #334.
📦 Packages and Docker Images
- ✨ Static Linux Binaries: Added static single-binary Linux release archives (
-static.tar.gz) for PHP 8.5 and PHP 8.6 (x86_64 and aarch64) linkinglibphp.a, exporting PHP symbols fordlopen()extensions, and probing host CA certificate bundles automatically, #347, #350. - ✨ Distroless Container Images: Added non-root Distroless images (
php8.4-distroless,php8.5-distroless,php8.6-distroless) built ongcr.io/distroless/cc-debian13:nonroot, #346. - ✨ PHP 8.6 and Automatic Base Rebuilds: Added PHP 8.6 release packages, tarballs, and container images, and automated image rebuilds when upstream PHP or Distroless base images update, #321, #322, #346.
- 🐛 Package Dependencies: Updated RPM packages to depend on the
libssl.so.3soname and required OpenSSL 3.3 and RHEL 9.7 glibc for PHP 8.6 packages, #324, #332.