gottscj / Hangfire.Mongo

Mongo DB support for Hangfire
MIT License
259 stars 84 forks source link

Jobs Stuck in Enqueued State #380

Closed mwasson74 closed 7 months ago

mwasson74 commented 8 months ago

First posted on GitHub/HangfireIO (#2355)

I can provide any additional information that you require to help troubleshoot this with me.

Issue

Jobs are staying/stuck in the Enqueued state. The system thinks those jobs are still running and won’t enqueue them again. So in the instance from the screen shot, we have 63 unique recurring jobs that never get enqueued again. The only way I can find to get them running again is to stop the app pool, drop all **hangfire.*** collections from mongo, and then start the app pool again. (we add the recurring jobs on startup)

image

Solution State

ASP.NET Core .NET 8 Hangfire.AspNetCore Version="1.8.9" Hangfire.Console Version="1.4.2" Hangfire.Core Version="1.8.9" Hangfire.Dashboard.BasicAuthorization Version="1.0.2" Hangfire.Mongo Version="1.9.16"

The most recent stdump file: stdump_hangfire2.txt

Classes have this attribute applied: SkipWhenPreviousJobIsRunningAttribute.txt

Execute Methods have [DisableConcurrentExecution("{0}", 3)] applied

image

image

mwasson74 commented 7 months ago

Thank you for all of your expedient assistance!! 🙏