21torr/task-manager
Small wrapper around symfony/messenger that simplifies task management in PHP/Symfony apps. Helps you define, dispatch, and handle tasks with a cleaner API while keeping Messenger under the hood. Includes documentation for quick setup and usage.
Task base class, which aligns well with Laravel’s job/queue paradigm. This ensures consistency in task handling, serialization, and logging.RegisterTasksEvent and TaskDirector patterns allow for custom task registration, validation, and post-processing, which can be leveraged for Laravel’s event system or service containers.TaskLog model).task-manager:run-worker, task-manager:log, etc.), which can be integrated into Laravel’s Artisan or used alongside existing queue workers.TaskLog::getTaskObject() is deprecated in favor of TaskDetailsNormalizer::deserializeTask()). If adopting a newer version, migration effort will be required.TaskLog model, which may conflict with existing Laravel migrations or require custom schema handling.Task class, which may require refactoring existing Laravel jobs to conform.TaskManagerInternalTask interface and task_manager_internals transport introduce internal task processing, which could complicate debugging if not properly isolated.Task base class without major refactoring?TaskLog model conflict with existing logging (e.g., Laravel’s failed_jobs table)?TaskScheduler) beyond Laravel’s built-in scheduling?TaskLog entries and asynchronous log cleaning introduce database overhead?TaskManagerInternalTask) be distinguished from user tasks in logs and monitoring?task-manager:run-worker command can replace or supplement Laravel’s queue:work, offering better task logging, retries, and scheduling.RegisterTasksEvent for dynamic task registration or validation.TaskLog model will coexist with Laravel’s failed_jobs table, but may require custom migrations to avoid conflicts.Task base class.task-manager:run-worker for new tasks.Task class.TaskScheduler, DispatchAfterRunTask).TaskLog model doesn’t conflict with Laravel’s schema.| Feature | Laravel Compatibility | Notes |
|---|---|---|
| Symfony Messenger | High | Laravel Horizon already uses it. |
| PHP 8.5+ | Medium | Blocks Laravel <10.x unless upgraded. |
| Doctrine DBAL | Medium | May conflict with Eloquent if not configured carefully. |
| ULID Task IDs | High | Better than UUIDs for distributed systems. |
| CLI Commands | High | Can coexist with Artisan commands. |
| Task Logging | Medium | May require custom handling of TaskLog vs. failed_jobs. |
| Scheduling | High | TaskScheduler can complement Laravel’s task scheduling. |
composer require 21torr/task-manager
Task class.TaskManager.queue:work with task-manager:run-worker for new tasks.TaskScheduler for custom scheduling.DispatchAfterRunTask for post-execution workflows.TaskLog cleanup settings.task_manager_internals).TaskLog provides a unified audit trail for all tasks.TaskLog model requires ongoing schema attention.Task class.failed_jobs table.TaskManagerInternalTask) may obscure logs if not filtered properly.TaskLog adds **databaseHow can I help you explore Laravel packages today?