API Index — Namespaces, Packages, Reports, Indices
Isolation
: string
in package
Type-safe enum for App::isolation() — the single knob that says HOW a
request is isolated. It folds the old (processIsolation × enableCoroutine ×
hookAll × cgiMode) cross-product into one intention-revealing value.
App::isolation(Isolation::Coroutine); // ← type-checked App::isolation(App::ISOLATION_COROUTINE);// ← class constant (canonical) App::isolation('coroutine'); // ← bare string (BC)
Pair with App::superglobals(bool) (the orthogonal axis: real $_GET/$_SESSION
vs per-coroutine $g). The two axes together describe every supported mode:
superglobals(true) + Coroutine → Mode 4 (ext-isolated superglobals, concurrent) superglobals(true) + CgiPool → Legacy CGI Pool (unmodified WordPress) [default for sg=true] superglobals(true) + None → Mixed / sequential (Symfony, Laravel) superglobals(false) + Coroutine → Pure coroutine ($g) [default for sg=false]
isolation() is pure sugar over the existing fluent setters — process vs
coroutine vs none are mutually-exclusive strategies (a CGI subprocess uses
blocking pipe I/O that cannot coexist with the coroutine scheduler), so a
single enum makes the impossible combo unrepresentable instead of relying on
boot-time forcing rules.
Table of Contents
Cases
- CgiFcgi = 'cgi-fcgi'
- Process isolation by forwarding to an external FastCGI upstream (php-fpm/hhvm/roadrunner).
- CgiPool = 'cgi-pool'
- Process isolation via a pre-spawned subprocess pool (mod_php-style, ~1-3ms warm). Default for superglobals(true).
- CgiProc = 'cgi-proc'
- Process isolation via a fresh proc_open subprocess per request (~30-50ms cold).
- Coroutine = 'coroutine'
- In-process, per-coroutine isolation via ext-zealphp (concurrent).
- None = 'none'
- In-process, sequential, no per-request isolation — safe only because workers handle one request at a time.
Methods
- cgiMode() : CgiMode|null
- The matching CgiMode for the process-isolation strategies; null otherwise.
- coerce() : self
- isProcess() : bool
- True for the three process-isolation (CGI subprocess) strategies.
Cases
Coroutine
In-process, per-coroutine isolation via ext-zealphp (concurrent).
CgiPool
Process isolation via a pre-spawned subprocess pool (mod_php-style, ~1-3ms warm). Default for superglobals(true).
CgiProc
Process isolation via a fresh proc_open subprocess per request (~30-50ms cold).
CgiFcgi
Process isolation by forwarding to an external FastCGI upstream (php-fpm/hhvm/roadrunner).
None
In-process, sequential, no per-request isolation — safe only because workers handle one request at a time.
Methods
cgiMode()
The matching CgiMode for the process-isolation strategies; null otherwise.
public
cgiMode() : CgiMode|null
Return values
CgiMode|nullcoerce()
public
static coerce(self|string $mode) : self
Parameters
- $mode : self|string
Return values
selfisProcess()
True for the three process-isolation (CGI subprocess) strategies.
public
isProcess() : bool