coolify/app/Console/Commands
Andras Bacsai b22e79caec feat(jobs): improve scheduled tasks with retry logic and queue cleanup
- Add retry configuration to CoolifyTask (3 tries, 600s timeout)
- Add retry configuration to ScheduledTaskJob (3 tries, configurable timeout)
- Add retry configuration to DatabaseBackupJob (2 tries)
- Implement exponential backoff for all jobs (30s, 60s, 120s intervals)
- Add failed() handlers with comprehensive error logging to scheduled-errors channel
- Add execution tracking: started_at, retry_count, duration (decimal), error_details
- Add configurable timeout field to scheduled tasks (60-3600s, default 300s)
- Update UI to include timeout configuration in task creation/editing forms
- Increase ScheduledJobManager lock expiration from 60s to 90s for high-load environments
- Implement safe queue cleanup with restart vs runtime modes
  - Restart mode: aggressive cleanup (marks all processing jobs as failed)
  - Runtime mode: conservative cleanup (only marks jobs >12h as failed, skips deployments)
- Add cleanup:redis --restart flag for system startup
- Integrate cleanup into Dev.php init() for development environment
- Increase scheduled-errors log retention from 7 to 14 days
- Create comprehensive test suite (unit and feature tests)
- Add TESTING_GUIDE.md with manual testing instructions

Fixes issues with jobs failing after single attempt and "attempted too many times" errors
2025-11-10 11:11:18 +01:00
..
Cloud refactor: move RestoreDatabase command to Cloud namespace 2025-11-05 14:42:12 +01:00
Generate feat: generate category for services 2025-08-18 17:28:20 +02:00
AdminDeleteUser.php Changes auto-committed by Conductor 2025-10-16 17:23:22 +02:00
CheckApplicationDeploymentQueue.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
CleanupApplicationDeploymentQueue.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
CleanupDatabase.php chore: remove webhooks table cleanup 2025-09-10 19:56:15 +02:00
CleanupNames.php feat(validation): centralize validation patterns for names and descriptions 2025-08-19 12:14:48 +02:00
CleanupRedis.php feat(jobs): improve scheduled tasks with retry logic and queue cleanup 2025-11-10 11:11:18 +01:00
CleanupStuckedResources.php feat(cleanup): add force deletion of stuck servers and orphaned SSL certificates 2025-10-09 16:37:56 +02:00
CleanupUnreachableServers.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
ClearGlobalSearchCache.php feat: add artisan command to clear global search cache 2025-10-11 13:36:14 +02:00
Dev.php feat(jobs): improve scheduled tasks with retry logic and queue cleanup 2025-11-10 11:11:18 +01:00
Emails.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
Horizon.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
HorizonManage.php refactor: streamline job status retrieval and clean up repository interface 2025-01-10 19:53:13 +01:00
Init.php feat(jobs): improve scheduled tasks with retry logic and queue cleanup 2025-11-10 11:11:18 +01:00
Migration.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
NotifyDemo.php reorder more stuff 2024-12-11 18:44:19 +01:00
RootChangeEmail.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
RootResetPassword.php fix(console): handle missing root user in password reset command 2025-03-24 18:00:31 +01:00
RunScheduledJobsManually.php feat(scheduling): add frequency filter option for manual execution of scheduled jobs 2025-07-11 15:10:43 +02:00
Scheduler.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
Seeder.php Revert "rector: arrrrr" 2025-01-07 15:31:43 +01:00
ServicesDelete.php refactor(command): improve database collection logic for deletion command by using unique identifiers and enhancing user experience 2025-09-05 17:43:19 +02:00
SyncBunny.php fix: escape shell arguments in syncBunny command execution 2025-11-06 14:57:53 +01:00
UpdateServiceVersions.php Add artisan command to update service Docker image versions 2025-10-30 08:29:11 +01:00
ViewScheduledLogs.php feat(logging): add frequency filters for scheduled logs command to support hourly, daily, weekly, and monthly job views 2025-07-11 19:26:42 +02:00