public Task AddRecurrentJob(JobDb job) { return(_processor.Execute(() => { var foundJob = _storage.FindRecurrentJobToUpdate(job.JobKey) ?? job.Copy(); _storage.Remove(foundJob); foundJob.Cron = job.Cron; foundJob.StartAt = job.StartAt; _storage.Add(foundJob); })); }
public Task AddJob(JobDb job) { return(_processor.Execute(() => _storage.Add(job.Copy()))); }