Title here
Summary here
You want a quick feel for how fast Pionia Shop handles a warm GET ping or a Moonlight dispatch on your machine — before you reach for load testers or RoadRunner profiling.
php pionia bench (alias benchmark)php pionia workingauth / list_auth)bench boots the application once, warms the process, then times repeated in-process calls:
handleRequest (no TCP server)dispatch(service, action) for the pair you chooseflowchart LR CLI["php pionia bench"] --> Boot[AppRealm once] Boot --> Warm[Warmup iterations] Warm --> Ping[Time ping] Warm --> ML[Time moonlight dispatch] Ping --> Stats[mean / p50 / p95] ML --> Stats
Not a load test
This is a microbenchmark of a warm PHP process. It does not open sockets, exercise nginx/FPM, or simulate concurrent users. For request metrics under real traffic, use Developer stats or an external load tool.
php pionia bench
php pionia bench --iterations=200 --warmup=20
php pionia bench --service=task --action=list --json| Option | Default | Purpose |
|---|---|---|
--iterations | 100 | Timed runs per probe |
--warmup | 10 | Discarded runs before timing |
--service | auth | Moonlight service alias |
--action | list_auth | Moonlight action name |
--json | off | Machine-readable output |
Example terminal output (numbers vary by machine):
Ping (handleRequest)
mean 0.42 ms p50 0.38 ms p95 0.71 ms 2380 ops/s
Moonlight dispatch (product.list)
mean 0.85 ms p50 0.79 ms p95 1.20 ms 1176 ops/sUse bench when… | Prefer something else when… |
|---|---|
| Comparing two code paths on the same laptop | You need concurrent users or HTTP latency |
| Checking that a change did not explode warm dispatch cost | You are tuning SQL — use Porm performance |
| Capturing a JSON snapshot in CI smoke | You need production OPcache — see Production performance |
--warmup so OPcache and autoload settle.auth / list_auth from the template.Request metrics at /stats and stats:view.
OPcache preload and optimize --production.
Full CLI registry.