liip/monitor
liip/monitor provides health-check endpoints for Laravel applications, running configurable checks for database, cache, queue, disk space, and custom services. Use its JSON status output to power uptime monitoring and alerting.
Bottom line: Do not add liip/monitor as a runtime dependency. Treat it as a design reference for a health-check registry inside a Laravel app.
Architecture fit
CheckInterface (single check() returning a Result with status + message) plus a Runner that registers checks into named groups and aggregates results. That shape is framework-agnostic and maps 1:1 onto a Laravel container binding + an App\Support\Health\HealthCheck contract.health: '/up' in bootstrap/app.php), and the ecosystem-standard replacement is spatie/laravel-health (actively maintained, ships DB/Redis/cache/Horizon/queue/disk/HTTP checks, JSON endpoint, result history). Functional overlap with LiipMonitor is roughly 90%.Integration feasibility
--ignore-platform-reqs, importing a legacy transitive tree for functionality we can re-implement in about a day.Technical risk (ranked)
/health that only asserts "PHP is running" is worse than none; it suppresses the alerting you actually need.Key questions
Stack fit
HealthCheck interface, tagged bindings in a service provider, a HealthController, and Cache-backed result storage. Route sits outside web/auth middleware, optionally behind a signed URL or IP allowlist.Migration path
spatie/laravel-health if the catalogue matches.liip/monitor-bundle, keep the contract compatible (same OK/WARNING/CRITICAL/UNKNOWN status vocabulary) so one dashboard can consume both.Compatibility
php: >=5.3.3-style constraints and abandoned optional deps. Do not attempt to satisfy them; if a spike requires execution, isolate in a throwaway container, never in the app's composer.json.{status, checks: [{name, status, message, duration_ms}]}, HTTP 200 for OK and 503 for CRITICAL — matches k8s probe semantics and reverse-proxy health checks.Sequencing (estimates, 1 engineer)
spatie/laravel-health and native /up. Deliverable: build-vs-adopt one-pager.HealthCheck contract, tagged registration, runner with result aggregation, /health JSON route; leave /up as the cheap liveness probe.DB::select('select 1') with timeout), cache put/get, Redis PING, Queue::size(), Horizon status, storage free space, one external HTTP check with a 2s timeout.Maintenance
spatie route: ~50–150 LOC to own, low churn, reviewed like any app code. Cost is a few hours per quarter plus adding a check whenever a new dependency lands.Support
Scaling
/health from tracing sampling and access-log noise.Failure modes
| Failure | Symptom | Mitigation |
|---|---|---|
| Check throws | 500 from /health, orchestrator restarts a healthy pod |
Wrap each check in try/catch; map exceptions to CRITICAL with message |
| Slow dependency | Probe timeout, cascading restarts | Per-check timeout, cached readiness, separate liveness |
| Threshold drift | Disk WARNING at 90% forever, ignored | Tune thresholds; route WARNING and CRITICAL differently |
| False green | Only "PHP alive" asserted | Enforce a minimum check set in code review |
| Alert fatigue | Every transient blip pages | Require N consecutive CRITICALs before paging |
| Scheduler probe dies | Dashboard green, reality red | Dead-man's-switch heartbeat on the probe job itself |
Ramp-up
TPM recommendation: Reject as a dependency (0/10 risk-adjusted adoption value); reference it for API design (7/10 concept value — which is what the 7.55 opportunity score actually flags: a well-shaped idea with no living implementation). Ship a thin in-house module or spatie/laravel-health, whichever the day-1 spike favors, and reinvest the saved effort into the runbook and alert routing.
How can I help you explore Laravel packages today?