| RecurringJobScheduler Class |
Namespace: Hangfire.Server
The RecurringJobScheduler type exposes the following members.
| Name | Description | |
|---|---|---|
| RecurringJobScheduler |
Initializes a new instance of the RecurringJobScheduler
class with default background job factory.
| |
| RecurringJobScheduler(IBackgroundJobFactory) |
Initializes a new instance of the RecurringJobScheduler
class with custom background job factory.
|
| Name | Description | |
|---|---|---|
| Execute | ||
| ToString | Returns a string that represents the current object. (Overrides ObjectToString.) |
This background process polls the recurring job schedule for recurring jobs ready to be enqueued. Interval between scheduler polls is hard-coded to 1 minute as a compromise between frequency and additional stress on job storage.
| Use custom background processes if you need to schedule recurring jobs with frequency less than one minute. Please see the IBackgroundProcess interface for details. |
Recurring job schedule is based on Set and Hash data structures of a job storage, so you can use this background process as an example of a custom extension.
Multiple instances of this background process can be used in separate threads/processes without additional configuration (distributed locks are used). However, this only adds support for fail-over, and does not increase the performance.
| If you are using custom filter providers, you need to pass a custom IBackgroundJobFactory instance to make this process respect your filters when enqueueing background jobs. |