Cron / Symfony-Bundle

Cron integration for symfony
MIT License
188 stars 77 forks source link

cron:start fails silently #124

Closed Ctucker9233 closed 11 months ago

Ctucker9233 commented 1 year ago

conditions: Symfony 6, easy admin, php 8, heroku

I installed the extension as outlined, except for including it in appKernel.php, because symfony 6 has no such file that I can find. I can define jobs just fine. I don't have a crontab interface, so I ran the console commands to run and start cron. The cron commands only run if I use cron:start -blocking. If there is an error, it exits cron:start. I need these commands to automatically reschedule if an error is encountered, and not stop running. Any suggestions?

github-actions[bot] commented 11 months ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

GregoireDolidonWiilog commented 4 months ago

Hello, I have the same problem. Sometimes my database is slow or unavailable and this causes the preprocess to crash. Here is a log :

[2024-04-30T14:46:05.398799+02:00] console.CRITICAL: Error thrown while running command "cron:start". Message: "SQLSTATE[HY000]: General error: 2006 MySQL server has gone away" {"exception":"[object] (Doctrine\\DBAL\\Driver\\PDO\\PDOException(code: HY000): SQLSTATE[HY000]: General error: 2006 MySQL server has gone away at /project/vendor/doctrine/dbal/src/Driver/PDO/PDOException.php:20)\n[previous exception] [object] (PDOException(code: HY000): SQLSTATE[HY000]: General error: 2006 MySQL server has gone away at /project/vendor/doctrine/dbal/src/Driver/PDO/Connection.php:112)","command":"cron:start","message":"SQLSTATE[HY000]: General error: 2006 MySQL server has gone away"} []