Framework Competition — PHP-FPM Summary

The headline numbers from the measured nginx + PHP-FPM deployment: the cost of one pass over every endpoint, the plain routing request, the two data-access races, and what one request costs in memory. End-to-end HTTP over loopback, so the constant webserver overhead is included (see floor-http/floor-php in the dataset). The worker-recycling setting of the pool is stated with the server floor below, because it changes what each row contains.

PHP 8.5.11 · Linux 6.8.0-139-generic · php-fpm mode · OPcache: yes · 1000 iterations per run over 10 runs · charts show the median as a faint bar + dot with the fastest → p95 range, lower is better

Total response times
Total response times
Per-request memory — lightest, typical and heaviest endpoint
Per-request memory — lightest, typical and heaviest endpoint

Feature benchmarks

Routing

GET / — dispatches a request through the router and returns a rendered template — no database access. The `/echo` band runs the same path with a constant handler instead, so what the template render costs can be read off directly rather than inferred.

Routing
ORM / Active Record

GET /items — loads one page of the 1,000 seeded rows through each framework's ORM / Active Record layer: 20 items plus a COUNT for the pagination total. The `-fast` band repeats that page with hydration switched off, so the cost of building one object per row can be read directly instead of inferred.

ORM / Active Record
REST API (JSON)

GET /api/items — serves the same page of items as a JSON response rather than HTML, which adds serialization to the ORM work. The `-fast` band repeats that response with hydration switched off, so serialization cost and hydration cost can be told apart.

REST API (JSON)

Latency by endpoint (ms, trimmed mean — lower is better)

RequestWorkloadAzeraLaravelSymfonySpiralCodeIgniterCakePHP
GET /no DB — routing + template only0.6253.621.856.711.881.44
GET /echono DB — routing + dispatch only0.5183.451.606.541.721.30
GET /items20 of 1000 items (page 1, + COUNT)1.344.703.407.632.702.79
GET /items-fast20 of 1000 items (page 1, + COUNT), hydrated rows not built1.254.423.317.492.582.70
GET /items/11 item by id1.234.412.747.482.512.56
POST /items1 row upserted (sentinel #999999)1.414.453.687.522.692.72
GET /items-qb20 of 1000 items (page 1, + COUNT)1.174.242.427.122.552.19
GET /items-qb/11 item by id1.134.112.367.082.462.11
POST /items-qb1 row upserted (sentinel #999997)1.244.243.237.242.702.22
GET /api/items20 of 1000 items as JSON1.214.552.736.782.512.46
GET /api/items-fast20 of 1000 items as JSON, rows not hydrated1.134.142.676.632.422.41
GET /api/items/11 item by id as JSON1.144.362.506.682.422.43
POST /api/items1 row upserted (sentinel #999998)1.224.273.436.762.512.59
GET /features/aopno DB — interceptor pipeline2.324.973.088.23——
GET /features/cacheCOUNT(*) of 1000 rows, cached 10s (miss = query)1.414.292.707.322.362.32
GET /features/logno DB — buffered log handlers1.003.501.746.69——
GET /features/retryno DB — retry policy1.013.511.746.74——
GET /features/pipelineno DB — middleware pipeline0.5763.501.756.72——
GET /features/db-events1 event row INSERTed per request1.514.302.867.572.622.54
GET /features/eventsno DB — in-process listeners1.484.012.197.282.561.87
GET /features/validationno DB — validator run0.5854.412.106.832.171.73
GET /features/configno DB — config lookup0.5313.491.766.721.821.30
GET /features/request-scopedno DB — scoped service resolve0.5323.491.746.781.801.33
GET /features/rate-limitno DB — cache-backed limiter0.5363.641.786.841.811.43

Server floor — real nginx + PHP-FPM with pm.max_requests=0: the pool never recycles its worker, so no process is spawned per request — what remains is the FastCGI handshake plus a minimal script. A hello-world endpoint that boots nothing but PHP (floor-php) and a static file through nginx (floor-http) measure exactly that cost — the floor every row stands on. Subtracting that floor leaves the framework's own per-request boot, which FPM still pays for every request even though its worker survives.