I am about 2 hours into my “hangfire” journey from a fresh google search for .Net background job handler, so this idea may be way against the grain. I have a client app (which happens to be an OWIN console app–but disregard that fact for a moment) that I need to queue up long running, server based jobs. Hangfire, from the server perspective, is exactly what I want/need. Where I choked on a bone this morning is when I saw the job queueing api:
var jobId = BackgroundJob.Enqueue( () => LongComplicatedCodeFatTask() );
I see that I can simply omit the server from the client, but surely I am not alone in my thinking that “sharing code base between client and server” is not always a great idea. I am thinking about creating a “client API” codebase for my client where LongComplicatedCodeFatTask() is just an empty stub function. Am I asking for trouble with this scheme?