Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Short Schedule Laravel Package

spatie/laravel-short-schedule

Run Laravel Artisan commands at sub-minute intervals (every second or even 0.5s). Adds a short-scheduler powered by a ReactPHP event loop, running separately from schedule:run so high-frequency tasks don’t block or get delayed.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • High-frequency task automation: Enables scheduling Artisan commands at sub-minute intervals (e.g., every 0.5 seconds), addressing use cases like real-time data processing, live updates, or latency-sensitive workflows where Laravel’s native scheduler (limited to 1-minute granularity) is insufficient.
  • Decoupling from Laravel’s scheduler: Runs independently of the standard schedule:run process, preventing delays or bottlenecks caused by long-running tasks in the primary scheduler.
  • Microservices/background processing: Ideal for systems requiring parallel execution of short-lived tasks (e.g., IoT telemetry ingestion, ad-tech bidding, or financial tickers) without blocking the main application.
  • Build vs. buy: Avoids reinventing a ReactPHP-based event loop for sub-second scheduling, leveraging a battle-tested, open-source solution with 650+ stars and active maintenance.
  • Roadmap alignment: Supports Laravel 13 (PHP 8.3+) and integrates with modern features like maintenance mode, environment constraints, and composite scheduling logic.

When to Consider This Package

  • Avoid if:
    • Tasks require >1-minute intervals: Use Laravel’s native scheduler for simplicity.
    • High memory/CPU overhead is unacceptable: Each task runs in a separate process; monitor resource usage closely.
    • Cross-platform constraints: Requires PHP 8.3+ and Laravel 12/13 (dropped support for older versions).
    • Complex dependencies: Tasks with heavy I/O or blocking operations may still delay the event loop (offload to queues for these cases).
  • Look elsewhere if:
    • You need distributed task coordination: Consider tools like Redis + Laravel Queues or cron-based solutions.
    • Real-time guarantees are critical: This package uses best-effort timing (ReactPHP’s event loop may introduce minor jitter).
    • Multi-language support is required: PHP-only solution.

How to Pitch It (Stakeholders)

For Executives: "This package lets us run critical background tasks at sub-second intervals—e.g., processing real-time user actions or financial trades—without slowing down our main application. It’s a drop-in solution that replaces manual cron hacks or custom scripts, reducing technical debt and improving reliability. With minimal overhead (MIT-licensed, actively maintained), it’s a low-risk way to unlock high-frequency automation."

For Engineers: *"Laravel’s scheduler tops out at 1-minute granularity, but spatie/laravel-short-schedule fills that gap using ReactPHP’s event loop. Key benefits:

  • Non-blocking: Tasks run in separate processes; slow jobs won’t delay others.
  • Flexible constraints: Schedule tasks by time, environment, or custom logic (e.g., when(fn() => $condition)).
  • Production-ready: Designed for long-running deployments (supports Supervisor, memory leak safeguards).
  • Extensible: Hook into events for observability or queue off heavy work. Tradeoff: Slightly higher resource usage than cron, but far more precise and maintainable. Recommended for latency-sensitive workflows like live dashboards or event-driven systems."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
nexmo/api-specification
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
ecotone/kafka
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata