private void DeleteRecurringJob(RunHangfireWorkflowDefinitionJobModel data) { var identity = data.GetIdentity(); _recurringJobManager.RemoveIfExists(identity); }
private void ScheduleRecurringJob(RunHangfireWorkflowDefinitionJobModel data, string cronExpression) { var identity = data.GetIdentity(); _recurringJobManager.AddOrUpdate <RunHangfireWorkflowDefinitionJob>(identity, job => job.ExecuteAsync(data), cronExpression); }