kinetis / queue-redis
A Redis-backed queue implementation for kinetis/queue's QueueInterface — the reliable-queue pattern (pending/processing/delayed lists), so a worker crash never silently loses a job.
Requires
- php: ^8.4
- amphp/redis: ^2.0.4
- kinetis/cache-redis: ^1.2.1
- kinetis/framework: ^1.28.3
- kinetis/queue: ^1.7.0
Requires (Dev)
- infection/infection: ^0.35.0
- phpstan/phpstan: ^2.2.8
- phpunit/phpunit: ^12.5.33
- vimeo/psalm: ^6.16.1
README
kinetis/queue-redis
A Redis-backed queue implementation for kinetis/queue's QueueInterface
Adds Redis as a queue backend. push()/pop()/ack()/release()/fail()
work exactly like any other backend — only your configuration changes. A
worker crash never silently loses a job: pop() atomically moves a job
from a pending list to a separate processing list rather than
deleting it, so a job whose worker never called ack()/release()/
fail() is stranded, not lost.
use Kinetis\Config\Config; use Kinetis\QueueRedis\RedisQueueFactory; $queue = RedisQueueFactory::fromConfig($config); $queue->push(new SendWelcomeEmail($email, $name), queue: 'default');
Configuration
QUEUE_CONNECTION=redis
REDIS_HOST=127.0.0.1
This package introduces no configuration keys of its own — REDIS_HOST/
REDIS_URL/REDIS_TLS/... are the exact ones kinetis/cache-redis's
RedisSimpleCache already reads, scoped by QUEUE_CONNECTION_NAME the
same way every other backend is. kinetis/queue's own keys
(QUEUE_CONNECTION, QUEUE_MAX_ATTEMPTS, ...) are documented in that
package; full reference:
kinetis.dev/docs/config.html.
Installation
composer require kinetis/queue-redis
Requires PHP 8.4+, kinetis/framework, kinetis/queue, and
kinetis/cache-redis. Full documentation:
kinetis.dev/docs/queue-redis.html.
License
MIT — see LICENSE.