added scheduled task for UpdateSceneMappingCommand

This commit is contained in:
Keivan Beigi 2013-09-12 15:41:50 -07:00
commit 21fd12e1a6
14 changed files with 16 additions and 58 deletions

View file

@ -4,6 +4,7 @@ using System.Linq;
using NLog;
using NzbDrone.Core.Configuration;
using NzbDrone.Core.Configuration.Events;
using NzbDrone.Core.DataAugmentation.Scene;
using NzbDrone.Core.Indexers;
using NzbDrone.Core.Instrumentation.Commands;
using NzbDrone.Core.Lifecycle;
@ -50,6 +51,7 @@ namespace NzbDrone.Core.Jobs
new ScheduledTask{ Interval = 1, TypeName = typeof(DownloadedEpisodesScanCommand).FullName},
new ScheduledTask{ Interval = 60, TypeName = typeof(ApplicationUpdateCommand).FullName},
new ScheduledTask{ Interval = 1*60, TypeName = typeof(TrimLogCommand).FullName},
new ScheduledTask{ Interval = 3*60, TypeName = typeof(UpdateSceneMappingCommand).FullName},
new ScheduledTask{ Interval = 1, TypeName = typeof(TrackedCommandCleanupCommand).FullName}
};
@ -89,7 +91,7 @@ namespace NzbDrone.Core.Jobs
public void HandleAsync(ConfigSavedEvent message)
{
var rss = _scheduledTaskRepository.GetDefinition(typeof (RssSyncCommand));
var rss = _scheduledTaskRepository.GetDefinition(typeof(RssSyncCommand));
rss.Interval = _configService.RssSyncInterval;
_scheduledTaskRepository.Update(rss);
}