msouto/redis-queue-inspector

A simple cli command to inspect Laravel Redis queues.

v0.1.3 2025-06-08 18:56 UTC

This package is auto-updated.

Last update: 2025-06-08 18:57:10 UTC


README

A simple CLI tool to inspect delayed Redis queue jobs in Laravel. Useful for debugging, auditing, and gaining visibility into scheduled or stuck jobs.

πŸ“₯ Installation

Install the package via Composer:

composer require msouto/redis-queue-inspector

Laravel will auto-discover the service provider, no manual registration needed.

πŸš€ Basic Usage

php artisan queue:inspect

This will inspect the first 50 delayed jobs in the default Redis queue.

πŸ” Options

Option Description
--queue= Comma-separated list of queue names (default: default)
--job= Filter by partial job class name
--from= Filter jobs scheduled from this date (Y-m-d)
--to= Filter jobs scheduled up to this date (Y-m-d)
--limit= Number of jobs per page (default: 50)
--page= Page number for pagination (default: 1)
--count Only return the total number of matching jobs
--identifier= Filter jobs that reference this model ID in the payload
--uuid= Filter by exact job UUID (as generated by Laravel when dispatching)
--json Output results in machine-readable JSON format

βœ… Examples

Show all delayed jobs in the default queue

php artisan queue:inspect

Show jobs in the emails queue that contain "SendWelcome" in the class name

php artisan queue:inspect --queue=emails --job=SendWelcome

View jobs scheduled from a specific date

php artisan queue:inspect --from=2025-06-01

Search jobs that reference a model ID in the payload

php artisan queue:inspect --identifier=47004

Look up a job by UUID

php artisan queue:inspect --uuid=123e4567-e89b-12d3-a456-426614174000

Only return a count of matching jobs

php artisan queue:inspect --job=SendInvoice --count

Output results in JSON format

php artisan queue:inspect --queue=emails --job=SendWelcome --limit=2 --json

πŸ“Œ Output Example

Showing 10 jobs (page 1) of 47 matching jobs.
+---------+--------------------------+--------------------------------------+---------------------+
| Queue   | Job Name                 | Job ID                               | Release At          |
+---------+--------------------------+--------------------------------------+---------------------+
| default | App\Jobs\SendWelcome     | 123e4567-e89b-12d3-a456-426614174000 | 2025-06-12 21:58:54 |
+---------+--------------------------+--------------------------------------+---------------------+
Tip: Run with --page=2 to see more.

πŸ›  Requirements

  • PHP 8.1+
  • Laravel with Redis queue driver enabled

πŸ“„ License

MIT License

πŸ‘€ Author

MΓ‘rio Souto
mario.cs1@gmail.com