Important if using DI container with an interface, you must put the attribute on the interface definition or it won't be recognized.
public interface IDataUpdater{ [Hangfire.AutomaticRetry(Attempts = 0, OnAttemptsExceeded = AttemptsExceededAction.Delete)] void UpdateData();}
Queue the job like this
Hangfire.RecurringJob.AddOrUpdate<IDataUpdater>(updater => updater.UpdateData(), Cron.Hourly);
Test it with throw new Exception("Test!")
within your implementation. If you've done it right you'll see this in the job history under 'deleted'.