Worked out what is going on here, and to be honest the method is miss leading to what it actually does.
HourInterval seems that it will fire a job every n number of hours, this is correct as long as you dont go over 12 hours. If you go any higher then it will run on that hour and then again at midnight. Looks like this is down to how hangfire relies on NCrontab to determine the next execution time. NCrontab only seems to work it out within a complete 24 period. For example. I say I want it to run every 7 hours, so it will run at the following times:
0
7
14
21
then it resets
0
7
etc
etc
This either needs to be documented or fixed because it took we a while to work this out and its not what I was expecting it to do. Surely it should also take the creation time into account and use that as a starting point, i.e. I created it at 2pm, so first time it should run should be 9pm. That doesnt appear to be considered in NCrontab.
Is this something that you will be addressing or is it simply how it is?
I assume minutes and days work in the same way? i.e. don’t go over 30 mins or 14 days.