arifnd / litequeue
A lightweight queue core for Laravel, compatible with Laravel Queue and Horizon.
Requires
- php: ^8.2
- illuminate/config: ^12.0 || ^13.0
- illuminate/console: ^12.0 || ^13.0
- illuminate/container: ^12.0 || ^13.0
- illuminate/contracts: ^12.0 || ^13.0
- illuminate/database: ^12.0 || ^13.0
- illuminate/events: ^12.0 || ^13.0
- illuminate/filesystem: ^12.0 || ^13.0
- illuminate/pipeline: ^12.0 || ^13.0
- illuminate/queue: ^12.0 || ^13.0
- illuminate/redis: ^12.0 || ^13.0
- illuminate/support: ^12.0 || ^13.0
- vlucas/phpdotenv: ^5.6.1
Requires (Dev)
- laravel/pint: ^1.18
- mockery/mockery: ^1.6
- orchestra/testbench: ^10.0 || ^11.0
- phpstan/phpstan: ^2.1
- phpunit/phpunit: ^10.5 || ^11.5 || ^12.0
Suggests
- laravel/horizon: Required only to view LiteQueue as a supervisor in a Horizon dashboard.
- predis/predis: Alternative Redis client when the phpredis extension is unavailable.
Provides
None
Conflicts
None
Replaces
None
This package is not auto-updated.
Last update: 2026-10-14 01:25:40 UTC
README
A lightweight queue core for Laravel, compatible with Laravel Queue and Laravel Horizon.
It reimplements the queue function (dispatcher, connections, worker, job execution, failed jobs)
and ships a standalone lq CLI so it can run with or without a full Laravel application.
Horizon is optional: when installed (in the same or another project) LiteQueue can appear in its dashboard as a supervisor by emulating Horizon's Redis supervisor state.
Requirements
- PHP
^8.2 - Laravel components
^12 || ^13(illuminate/*) — a full Laravel app is not required - Redis is required only for the
litequeue_redisdriver
Installation
composer require arifnd/litequeue
Publish the configuration (optional):
lq install
Environment variables
For a simple single-Redis setup almost everything has a default — only the queue backend and (if Redis is not on localhost) the host are needed:
QUEUE_CONNECTION=litequeue APP_NAME=Laravel # REDIS_HOST=127.0.0.1 # defaults to 127.0.0.1
REDIS_PORT (6379), REDIS_PASSWORD (none), REDIS_DB (0) and the queue name
(REDIS_QUEUE / LITEQUEUE_QUEUE, default default) all fall back automatically.
APP_NAME matters only for Horizon visibility: Horizon derives its Redis prefix from the app name
as {app_name}_horizon: (e.g. laravel_horizon:), and LiteQueue matches it.
Inside a Laravel app, .env is loaded automatically. The standalone lq binary does not load
a .env file — export these as real process environment variables (shell, Supervisor, Docker). See
Configuration for the full list, including
REDIS_PREFIX.
Quick start (standalone, no Laravel app)
# Publish config/litequeue.php and config/database.php lq install # Generate a job lq make:job SendEmail # Process jobs (single process) lq work redis # Or run as a Horizon-visible supervisor lq supervisor redis
Standalone boots the database manager, Eloquent and facades (via config/database.php), so jobs can
use DB::table(...) and models for database CRUD. See
Configuration.
Dispatch from PHP:
use App\Jobs\SendEmail; use function Arifnd\LiteQueue\dispatch; // or use the Bus facade SendEmail::dispatch($user);
Quick start (inside Laravel)
The package auto-registers Arifnd\LiteQueue\LiteQueueServiceProvider. Configure a connection
and dispatch as usual:
// config/queue.php (or config/litequeue.php) 'connections' => [ 'litequeue' => [ 'driver' => 'litequeue_redis', 'connection' => 'default', 'queue' => 'default', 'retry_after' => 90, ], ],
SendEmail::dispatch($user)->onConnection('litequeue');
Drivers
| Driver | Status | Notes |
|---|---|---|
litequeue_redis |
Supported | Storage schema identical to Laravel's RedisQueue. |
sync |
Supported | Executes inline. |
null |
Supported | Drops jobs (testing). |
Compatibility
| LiteQueue | PHP | Laravel | Horizon |
|---|---|---|---|
| 0.1.x | 8.2–8.5 | 12–13 | optional (n/a, 5.x, 6.x) |
The Redis queue schema, job payload, and Illuminate\Queue\Events\* event surface are frozen to
match Laravel, so Horizon metrics, failed_jobs, and external tooling interoperate.
Horizon as a supervisor
LiteQueue uses its own configuration (it never edits config/horizon.php) and writes
Horizon-compatible supervisor state to the shared Redis. See docs/supervisor.md.
Documentation
- Installation
- Configuration
- Jobs
- Worker
- Supervisor & Horizon
- Deployment (Supervisor & Docker)
- Commands
- Testing
- Upgrade guide
- Release/versioning plan
- ADR 0001 — Horizon compatibility
Security
Queue payloads are serialized PHP objects and Redis is a trusted boundary — see
SECURITY.md for the trust model, hardening recommendations and how to report a
vulnerability privately. Dependencies are audited in CI (composer audit) and updated via
Dependabot.
License
MIT. See LICENSE.