renoki-co/horizon-exporter
A Prometheus exporter for Laravel Horizon that exposes queue, job, and worker metrics from Horizon's Redis data via a metrics endpoint, making it easy to monitor Horizon in Grafana and alert on queue health.
Architecture fit: renoki-co/horizon-exporter is a thin instrumentation layer that exposes Laravel Horizon's queue and worker telemetry in a Prometheus-scrapeable format. It sits alongside Horizon rather than replacing it: Horizon remains the source of truth for queue state, Redis remains the backing store, and this package adds an HTTP exposition surface plus (typically) a service provider, config file, and optional route middleware. For teams already running Horizon in production and standardising on Prometheus/Grafana, the architectural fit is high and the blast radius is small — it adds a read-only endpoint, not a new runtime dependency in the request/worker path.
Integration feasibility: Low-to-moderate. Installation is Composer plus config publishing and route registration; the real work is on the observability side — scrape config, label strategy, dashboards, and alert rules. There is no data migration requirement, no schema change, and no change to how jobs are dispatched or processed, which makes this one of the cheaper integrations available.
Technical risk: The 2.0.0 release contains exactly one substantive change: Laravel v9 support, with Laravel 8.x dropped. That is a breaking change for constraint resolution only — an application pinned to Laravel 8 cannot install 2.0.x, and an application that upgrades Laravel 9→10+ later will need to confirm this package keeps pace. Secondary risks are typical of small single-maintainer Laravel packages: Horizon's internal APIs and Redis key layout are not a stability contract, so a Horizon major release can silently break metric collection, and the exported metric names/labels are effectively a public API for your dashboards and alerts once adopted.
Key questions:
Stack fit: Designed for Laravel + Horizon + Redis, exposing metrics for Prometheus. It composes cleanly with the standard observability stack (Prometheus scrape → Grafana dashboards → Alertmanager), and does not conflict with existing APM tooling because it reports queue-state metrics rather than tracing spans. Teams without Horizon get nothing from this package; teams without Prometheus get a raw endpoint with no consumer.
Migration path: For a first-time adoption there is no migration — it is net-new instrumentation. For anyone already on 1.x, 2.0.0 is a constraint bump, not a code rewrite: update the Composer constraint, re-publish/merge the config if the route or middleware defaults changed, and re-run the metrics endpoint smoke test. Because 1.x remains installable for Laravel 8, the clean migration is by application, not by big-bang: upgrade each service's Laravel version first, then bump the exporter, so the dependency graph never has a service straddling both.
Compatibility: Effectively two tracks — 2.x for Laravel 9+, 1.x for Laravel 8. Any internal shared package, base image, or starter template that constrains renoki-co/horizon-exporter must be checked, since a shared constraint of ^1.0 will block Laravel 9 upgrades and a shared constraint of ^2.0 will block any straggler service. This is the single most likely integration friction point.
Sequencing:
Maintenance: Small surface area, modest ongoing cost: a Composer update a few times a year, plus a compatibility check whenever Horizon or Laravel majors land. The disproportionate maintenance cost is not the package but the contract it creates — dashboards and alerts that must be updated if metric names or labels change. Assign that contract an owner; unowned dashboards rot fastest.
Support: Single-maintainer open-source project with a narrow scope, which cuts both ways: the code is small enough to fork and patch internally if upstream stalls, and small enough that an abandoned release is recoverable. Do not assume enterprise support or a guaranteed CVE response; treat it as community-supported and plan a fork contingency for the endpoint code specifically.
Scaling: Overhead per scrape is bounded by the number of queues and workers being enumerated, not by job volume, so cost scales with Horizon topology rather than traffic — generally favourable. The real scaling concern is cardinality: per-queue or per-supervisor labels multiplied across many services can inflate Prometheus series count and storage. Budget series count deliberately, and keep scrape intervals sane (30–60s) rather than aggressive.
Failure modes:
^1.0 constraint quietly blocking a Laravel 9 upgrade across many repos.Ramp-up: Low for a Laravel-fluent engineer — roughly half a day to install, verify, and wire a scrape target. The longer pole is observability literacy: translating Horizon's queue semantics (wait time, supervisor balance, failed-job ratio) into meaningful SLOs and correctly-thresholded alerts. Budget one to two weeks for dashboards and alert tuning with someone who already owns on-call for those queues; without that ownership the metrics are collected but never acted on.
How can I help you explore Laravel packages today?