- Is resque/php-resque a Laravel package or does it have a Laravel queue driver?
- resque/php-resque is a standalone PHP port of Ruby Resque, not a Laravel package. It ships no service provider, facade, or Illuminate queue driver, so installing it with Composer will not register anything with Laravel. To use it in a Laravel app you either run it as a sidecar worker process or write a custom driver implementing Illuminate\Contracts\Queue\Queue. It is not a drop-in replacement for Laravel's queue system.
- How do I install resque/php-resque and what PHP extensions does it need?
- Install it with composer require resque/php-resque. It requires ext-redis (phpredis), ext-pcntl, and ext-posix, so it runs on Linux and Unix systems only. Windows and many serverless runtimes are not supported because workers fork per job and need long-lived processes. Make sure your container base image includes those extensions before deploying.
- Can I use resque/php-resque with Laravel 10, 11, or 12?
- The package is framework-agnostic and can run on PHP 8.1+ alongside Laravel 10, 11, or 12. Laravel compatibility is not provided through a first-party driver; it depends on how you integrate it, either as a sidecar service or through a custom queue driver. Validate your PHP version against the package release notes before committing. The Linux-only extension requirements remain a constraint regardless of Laravel version.
- How do I integrate php-resque with Laravel: sidecar workers or a custom queue driver?
- There are two realistic paths. The low-effort path runs php-resque workers as a separate deployment that boots enough of Laravel's container to resolve job classes, which is fast to prove but duplicates deployment and configuration concerns. The native path implements Illuminate\Contracts\Queue\Queue with push, pop, size, and later methods, plus a worker that maps to Laravel's Worker and Job contracts so events, middleware, and failed() hooks work. Teams estimate roughly 3 to 6 engineer-weeks for the custom driver including tests and failure-path parity.
- Does php-resque interoperate with Ruby Resque and share the same Redis queues?
- Yes. php-resque uses the same Redis list keys such as resque:queue:<name> and the same JSON job payloads as Ruby Resque, so PHP and Ruby workers can consume from one queue. That payload-level interoperability is the main genuine differentiator for polyglot estates or teams migrating off a Rails and Resque backend. If you do not actually need Ruby interop today, that advantage largely disappears.
- Does php-resque support delayed jobs, retries with backoff, and visibility timeouts?
- No. php-resque follows Resque's at-least-once model with a manual or plugin retry queue, and it has no native delayed jobs, retry backoff policies, or visibility timeout. Anything resembling Horizon's retry, timeout, and backoff behavior has to be built or accepted as a gap. If you need those features out of the box, Laravel's redis driver plus Horizon is the safer default.
- How should I configure Redis for php-resque so it doesn't conflict with Laravel queues?
- Use a dedicated Redis database index or a distinct key prefix so resque:* keys never collide with Laravel's queues:* and laravel_database_* keys. Set maxmemory-policy to noeviction on the Redis instance backing the queue, because an LRU or allkeys-random policy can silently evict jobs and cause hard-to-diagnose outages. Do not share an eviction-prone Redis instance with cache workloads.
- How do I run and supervise php-resque workers in production?
- Workers are long-lived, fork-per-job processes, so run them under a supervisor such as systemd, Supervisor, or a Kubernetes deployment with restart policies. Because each job forks a child process, watch for memory growth, orphaned or zombie children, and signal-handling edge cases. Serverless platforms that cannot host long-lived forking workers are a poor fit without re-architecture. Decide which team owns the worker runtime before launch.
- Is php-resque secure, and what are the risks of trusting job payloads from Redis?
- Job class names are read from Redis and instantiated, and payloads are not signed. That makes a compromised or shared Redis instance a remote code execution surface, not just a data leak. Lock down Redis with authentication, network isolation, and ACLs, and never let untrusted tenants write to the job queues. Treat queue access as equivalent to code execution access.
- How does php-resque compare to Laravel's Redis queue driver and Horizon, and is it actively maintained?
- Laravel's redis driver with Horizon gives you native retries, backoff, timeouts, metrics, and a dashboard, while php-resque gives you Resque payload compatibility but far less tooling. Choose php-resque only when Ruby Resque interoperability is a real current requirement; otherwise it is usually the wrong default. Maintenance is a risk because it has a small maintainer base around 233 stars and is community-maintained, though a March 2025 release signals recent activity. Be prepared to vendor or fork it if it lands on your critical path.