I have a IIS8.5/Win2012 installation with 10 fairly heavily used websites on it that I want to install Hangfire in to support tasks/jobs from all sites. The use would be for many small tasks like email subscription reminders, abandoned shopping cart emails, etc. with a smattering of tasks requiring more cycles like polling a table of URLs for FaceBook LIKE numbers.
The questions I have are:
- Should one Hangfire be installed as a windows service supporting all websites or one Hangfire instance for each website?
Obviously from an efficiency viewpoint, the one Hangfire service option would be most desirable but then it is necessary to figure out how to pass through an identifier indicating which of the 10 different databases to obtain the data to process a task against.
On the other hand, the load from 10 different Hangfire processes should not be too costly but toss on the IIS life-cycle and resource problems and the web server might end up working much harder.
- At what point do you create a dedicated Hangfire server? Is there some sort of general rules or best practices that suggest what volume of tasks, or number of requests might require a dedicated Hangfire server?
Any comments or previous experience would be most appreciated.