Sql+MSMQ Long Running Jobs Invisibility

Hey All,

We have a couple jobs that get kicked off that run for a long time (30m-2h). I’m seeing these Jobs get picked up for processing, despite already running, after 10m of processing (so a 35m job is getting picked up 4x for processing).

We’re using SQL + MSMQ for storage and have updated to the 1.6.18 of the appropriate Hangfire libraries and 2.1.0 of Hangfire.Pro.

I thought there was a new implementation of the “invisibility” logic that didn’t require us to set a big timeout? Is using MSMQ potentially changing this behavior or requiring different/additional settings? We have IIS set to restart every 24h so I don’t think it’s that.

Thanks in advance!

Just to follow up, it definitely seems like MSMQ is the culprit here as this issue completely goes away if we use SQL Storage without MSMQ.

I don’t see any options to configure the receive timeout in the MSMQ library…is this something that exists or will ever exist?

To me this sounds like you are using distributed transaction with MSDTC. The default timeout is 10min and can only be changed in the machine.config.

Search for transaction timeout machine.config and there are many places explaining in details