Hi all,
I’m trying to enqueue a delayed task to a specific queue,
I know how to enqueue a message to a queue normally:
var client = new BackgroundJobClient();
var state = new EnqueuedState(queue);
client.Create(() => Console.WriteLine(msg), state);
I’m looking for the equivalent of posting a job with a time delay:
Hangfire.BackgroundJob.Schedule(() => Console.WriteLine(msg),TimeSpan.FromMinutes(3));
However, as far as I can see the Schedule method takes no EnqueuedState parameter and client.Create() takes no Timespan parameter?
Many thanks for any help.