You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Static methods such as BackgroundJob.Enqueue are good to demonstrate things and for quick starts. But they complicate unit tests and can not be extended using extension methods. Moreover, BackgroundJobClient can be used to batch multiple jobs without creation connection for each.
The text was updated successfully, but these errors were encountered:
Completed, API looks like BackgroundJob.* methods:
IBackgroundJobClientclient=new BackgroundJobClient();/* There are different overloads */
client.Enqueue(()=> Console.WriteLine("Hi"));
client.Schedule(()=> Console.WriteLine("Delayed"), TimeSpan.FromMinutes(5));
client.Dispose();
Static methods such as
BackgroundJob.Enqueue
are good to demonstrate things and for quick starts. But they complicate unit tests and can not be extended using extension methods. Moreover, BackgroundJobClient can be used to batch multiple jobs without creation connection for each.The text was updated successfully, but these errors were encountered: