I have a ASP.NET Core project that uses HangFire to run recurring jobs. For some reason HangFire stops after some time and logs as follows:
2022-08-11 10:42 Debug Hangfire Server is stopping...
2022-08-11 10:42 Information Server sdu-ituadev0a:8060:badc3a3e caught stopping signal...
2022-08-11 10:42 Debug Execution loop ServerWatchdog:01472bd9 stopped in 0,0718 ms
2022-08-11 10:42 Debug Execution loop RecurringJobScheduler:686f412f stopped in 0,2737 ms
2022-08-11 10:42 Debug Execution loop CountersAggregator:b9d8a1e6 stopped in 0,3949 ms
2022-08-11 10:42 Information Server sdu-ituadev0a:8060:badc3a3e caught stopped signal...
2022-08-11 10:42 Debug Execution loop ServerJobCancellationWatcher:bc51023d stopped in 2,4785 ms
2022-08-11 10:42 Debug Execution loop ExpirationManager:d7372429 stopped in 2,7121 ms
2022-08-11 10:42 Debug Execution loop SqlServerHeartbeatProcess:29d236f2 stopped in 11,5211 ms
2022-08-11 10:42 Debug Execution loop DelayedJobScheduler:534fec47 stopped in 11,6591 ms
It shuts down and then no jobs are executed and no heartbeats are sent.
I want it to run forever. What am I missing?
The application sets:
- Preload enabled to true
- Startmode to Always running
- Idle timeout to 0
- doAppInitAfterRestart to true
I currently do not set hostName and initializationPage but I invoke /hangfire after deployment.
It runs under IIS 10
Thanks in advance.
Kind regards
Søren