Weave 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

Console Command Scheduler Bundle Laravel Package

bytespin/console-command-scheduler-bundle

ByteSpin Console Command Scheduler is a Symfony 6.3+ bundle for scheduling console commands via Messenger Scheduler, logging execution time, duration and return codes to database and log files, with an EasyAdmin interface and extendable email notifications.

View on GitHub
Deep Wiki
Context7
2.1.1

Fixed

  • The "Health" badge crashed the admin index: it lived on a TextField bound to the integer id property, which EasyAdmin's TextConfigurator rejects ("can't be converted into a string"). The badge now rides the Job Title column (string property); an entry skipped by the last schedule build shows a red "invalid" badge next to its title.
2.1.0

Added

  • RecurringMessageFactory: single point of truth converting a scheduler entry into a RecurringMessage — shared by the schedule provider, the entity validator and the new lint command, so what validates is exactly what runs.
  • Fault isolation in ConsoleJobsScheduler::getSchedule(): an invalid entry no longer takes the whole schedule down — it is skipped with an error log and a SchedulerEntryFaultedEvent, and every other entry keeps running. (Previously a single bad frequency crashed the scheduler worker at boot and silently stopped ALL scheduled tasks.)
  • SchedulerEntryFaultedEvent (bytespin.scheduler.entry.faulted): hook for host applications to plug their own monitoring on skipped entries.
  • ValidSchedulerEntry constraint on the Scheduler entity: the frequency must build a real recurring message for the chosen execution type at input time. A cron expression typed into the interval field is rejected with an explicit hint instead of being accepted and killing the scheduler at runtime.
  • bytespin:scheduler:lint command: dry-runs every entry through the same factory the scheduler uses (CI, deploy pipelines, post-restore checks); exits non-zero when an enabled entry cannot run.
  • "Health" badge on the admin list: entries skipped by the last schedule build show a red "invalid" badge carrying the reason.
  • New configuration option bytespin_console_command_scheduler.scheduler.process_only_last_missed_run (default true).

Changed

  • Behavior change: when the scheduler resumes after a downtime it now runs at most ONE catch-up occurrence per task instead of replaying every missed run (cron-like semantics). Set scheduler.process_only_last_missed_run: false to restore the previous replay-everything behavior.
  • ConsoleJobsScheduler now depends on the factory, an event dispatcher, an optional logger and the missed-run flag; the command introspection moved to Factory\ConsoleCommandIntrospector.
2.0.1

Changed

  • Rewrite ConfigureBundleCommand using Symfony best practices: #[AsCommand] attribute, SymfonyStyle for user interaction, %kernel.project_dir% injection, --no-interaction support.

Removed

  • Remove PostInstallScript (dead code, raw I/O incompatible with Symfony Console).
  • Remove ext-readline dependency (no longer needed).
2.0.0

Added

  • New ScheduledConsoleCommandEvent class extending Symfony\Contracts\EventDispatcher\Event with named constants (BEFORE, LOG, SUCCESS, FAILURE, AFTER).

Changed

  • Bump minimum PHP version to 8.4.
  • Widen dependency constraints: Symfony ^7.1 || ^8, Doctrine ORM ^2.10 || ^3 || ^4, EasyAdmin ^4.6 || ^5.
  • Replace deprecated GenericEvent with ScheduledConsoleCommandEvent in handler and subscribers.
  • Migrate SchedulerEasyAdminEventSubscriber from Doctrine\Common\EventSubscriber (removed in ORM 4) to #[AsDoctrineListener] attributes.
  • Remove #[AllowDynamicProperties] across the bundle, declare properties explicitly.
  • Add explicit union types on Scheduler entity setters (DateTimeInterface|string|null).
  • Add PHPDoc generics on repositories, events, providers, and CRUD controllers.
  • Improve null safety in ConsoleJobsScheduler schedule loop.

Fixed

  • Fix copy-paste bug in PostInstallScript checking for wrong bundle name (MessengerDedupeBundle).
  • Fix corrupted Configuration.php class declaration.
  • Fix inconsistent method name casing in SchedulerEasyAdminEventSubscriber (getExecutionuntilDate → getExecutionUntilDate).
  • Fix SchedulerLog::setReturnCode() to accept int|null (was string|null only).
  • Fix SchedulerLog::setDuration() to properly cast float to string.
  • Fix ExecuteConsoleCommand::$logFile default value from "" to null.
  • Remove useless try/catch re-throws in ConsoleJobsScheduler.
  • Apply php-cs-fixer @Symfony code style across the bundle.
1.1.0

Added

  • Implemented messenger queue choice in admin interface.
1.0.15

Upgraded

  • Upgrade symfony requirement to ^7.1
1.0.12

Added

  • Add new notification system
1.0.9

Added

  • Added "No DB Log" option to Scheduler entity to allow no database logging for some events
1.0.11

Fixed

  • Fix composer dragonmantank/cron-expression requirement
1.0.10

Added

  • Implemented lock management to prevent concurrent execution of the same task when multiple workers are defined.
1.0.8

Added

  • Added 4 new events for deeper application integration : bytespin.before.scheduled.console.command, bytespin.success.scheduled.console.command, bytespin.failure.scheduled.console.command, bytespin.after.scheduled.console.command

Improved

  • Improve documentation with ByteSpin events usage example
1.0.7

Improved

  • Improve duration readability in logs
1.0.6

Fixed

  • Remove the auto loaded doctrine configuration that was hard coded with the default entity manager

Added

  • Added a console command to configure the bundle (entity manager to be used with bundle entities)

Improved

  • Updated the README.md to include new mandatory configuration steps (manual or automatic) and checks.
1.0.5

Improved

  • Sort logs by date descending in crud controller to improve readability
1.0.4

Added

  • Added bundle version in crud controllers help. The version is cached for improved performance.
1.0.3

Fixed

  • Added missing log_file parameter to entity, message, handler and crud controller.

Improved

  • Updated log file readability.
1.0.2

Changed

  • Improved error handling in console command message handler by implementing a try/catch block for better management of potential exceptions during process execution.

Fixed

  • Disabled the timeout for console command process to allow the process to run indefinitely without premature termination, addressing issues with long-running operations.

Improved

  • Updated the README.md to include instructions for manual bundle registration in bundles.php for users not utilizing Symfony Flex.
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.
ably/pubsub-server
mstfkhazaal/defender
mfonte/base62x
karnoweb/metapilot
tobya/bcsapiwrapper
swalker2/cpanel
vish4395/laravel-translation-manager
morningtrain/economic
teksite/systeminfo-laravel
atomcms/voting
run6/weather
siokas/laravelembeddirectives
adamlien/pkuuids
gilsonsouza/lara-doc-generator
manelgavalda/enrollment_mobile
unabomber/timezone
delatbabel/contacts
astritzeqiri/g-recaptcha
kevinongko/laravel-genode
developeruz/laravel-analytics