Search by

illuma-law / healthcheck-operations

miguelenes

Focused operations backlog health check for Spatie's Laravel Health package.

Package info

github.com/eloquage/healthcheck-operations

Language:Blade

pkg:composer/illuma-law/healthcheck-operations

Fund package maintenance!

illuma-law

Statistics

Installs: 64

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 1

v0.1.5 2026-10-23 13:54 UTC

README

Healthcheck Operations banner

Tests Latest Stable Version License

A Spatie Laravel Health check for pending Laravel One-Time Operations. It reports the queue size, oldest operation age, and a sample of filenames.

Requirements

  • PHP 8.3 or later
  • Laravel 12 or 13
  • spatie/laravel-health 1.39 or later
  • timokoerber/laravel-one-time-operations 1.x

Installation

composer require illuma-law/healthcheck-operations

Laravel discovers the service provider automatically. Publish the configuration to choose whether an old backlog should fail:

php artisan vendor:publish --tag=healthcheck-operations-config

Pending operations warn by default. Set HEALTH_OPERATIONS_REQUIRED=true to fail when the oldest operation has been waiting for at least 24 hours. If the package cannot read the operation backlog, the check fails.

Usage

Register the check in your health service provider:

use IllumaLaw\HealthCheckOperations\OperationsBacklogCheck;
use Spatie\Health\Facades\Health;

Health::checks([
    OperationsBacklogCheck::new(),
]);

No pending operations returns OK. Pending operations return Warning by default; a backlog at least 24 hours old returns Failed when the required setting is enabled.

Testing

composer test
composer analyse
vendor/bin/pint --test

License

MIT. See LICENSE.md.