marmol89/cauce

Driver-agnostic queue monitoring and advanced retry strategies for Laravel.

Maintainers

Package info

github.com/marmol89/cauce

pkg:composer/marmol89/cauce

Statistics

Installs: 0

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

dev-main 2026-06-01 20:35 UTC

This package is auto-updated.

Last update: 2026-06-01 20:37:56 UTC


README

Driver-agnostic queue monitoring and advanced retry strategies for Laravel.

Cauce gives you a clean dashboard and battle-tested retry strategies for the Laravel queue system, without the Redis-only restriction of Horizon. It works with database, Redis, SQS, Beanstalkd, RabbitMQ, or any other driver Laravel supports.

Features

  • ๐Ÿ“Š Live dashboard built with Livewire 3 + Alpine + Tailwind
  • ๐Ÿ”Œ Multi-driver โ€” works with all Laravel queue drivers (unlike Horizon)
  • ๐Ÿ” 5 retry strategies โ€” Linear, Exponential, Decorrelated Jitter, Fibonacci, and Circuit Breaker
  • ๐Ÿ“ˆ Real-time metrics โ€” throughput, runtime, success rate
  • ๐Ÿ’€ Failed job browser with one-click retry
  • ๐Ÿงน Automatic pruning of old records
  • ๐ŸŽ›๏ธ Configurable per-connection/queue tracking

Requirements

  • PHP 8.2+
  • Laravel 11.x, 12.x, or 13.x

Installation

composer require marmol89/cauce

Publish the assets and run the migrations:

php artisan cauce:install
php artisan migrate

Optionally, publish the config:

php artisan vendor:publish --tag=cauce-config

Configuration

The dashboard is available at /cauce by default. You can change the path, restrict it to specific environments, and configure retention in config/cauce.php.

Quick start

Tracking jobs

Cauce automatically tracks every job that flows through Laravel's queue system. No extra configuration needed.

Retry strategies

Apply a retry strategy to a job using the #[Retry] attribute:

use Marmol89\Cauce\Attributes\Retry;
use Marmol89\Cauce\Retry\ExponentialBackoff;

#[Retry(strategy: ExponentialBackoff::class, max: 5, base: 2, cap: 300)]
class SendInvoiceEmail implements ShouldQueue
{
    // ...
}

Or via middleware (Laravel-style):

public function middleware(): array
{
    return [
        new \Marmol89\Cauce\Middleware\ApplyRetryStrategy(
            new \Marmol89\Cauce\Retry\ExponentialBackoff(base: 2, cap: 300, max: 5)
        ),
    ];
}

Available strategies

Strategy Best for
LinearBackoff Predictable, simple retries
ExponentialBackoff Most APIs (AWS-style)
DecorrelatedJitter Avoiding thundering herd
FibonacciBackoff Gradual growth
CircuitBreaker Unstable external services

Commands

Command Description
php artisan cauce:install Publish assets and run migrations
php artisan cauce:status CLI overview of queue status
php artisan cauce:retry {id} Retry a failed job
php artisan cauce:prune Clean up old records
php artisan cauce:clear Wipe stored data

Why Cauce?

Laravel Horizon is excellent but tightly coupled to Redis. If you run queues on database, SQS, Beanstalkd, or any other driver, you're out of luck for monitoring. Cauce is driver-agnostic and adds sophisticated retry strategies on top of any queue system.

License

MIT ยฉ marmol89