@ -68,7 +68,8 @@ namespace NzbDrone.Core
_kernel = new StandardKernel ( ) ;
_kernel . Bind < IDatabase > ( ) . ToMethod ( c = > Connection . GetPetaPocoDb ( Connection . MainConnectionString ) ) . InRequestScope ( ) ;
_kernel . Bind < IDatabase > ( ) . ToMethod ( c = > Connection . GetPetaPocoDb ( Connection . MainConnectionString , false ) ) . WhenInjectedInto < IJob > ( ) . InSingletonScope ( ) ;
_kernel . Bind < IDatabase > ( ) . ToMethod ( c = > Connection . GetPetaPocoDb ( Connection . MainConnectionString , false ) ) . WhenInjectedInto < IJob > ( ) ;
_kernel . Bind < IDatabase > ( ) . ToMethod ( c = > Connection . GetPetaPocoDb ( Connection . MainConnectionString , false ) ) . WhenInjectedInto < JobProvider > ( ) ;
_kernel . Bind < IDatabase > ( ) . ToMethod ( c = > Connection . GetPetaPocoDb ( Connection . LogConnectionString , false ) ) . WhenInjectedInto < SubsonicTarget > ( ) . InSingletonScope ( ) ;
_kernel . Bind < IDatabase > ( ) . ToMethod ( c = > Connection . GetPetaPocoDb ( Connection . LogConnectionString ) ) . WhenInjectedInto < LogProvider > ( ) . InRequestScope ( ) ;
}
@ -76,10 +77,10 @@ namespace NzbDrone.Core
private static void BindIndexers ( )
{
_kernel . Bind < IndexerBase > ( ) . To < NzbsOrg > ( ) .InTransientScope ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < NzbMatrix > ( ) .InTransientScope ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < NzbsRUs > ( ) .InTransientScope ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < Newzbin > ( ) .InTransientScope ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < NzbsOrg > ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < NzbMatrix > ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < NzbsRUs > ( ) ;
_kernel . Bind < IndexerBase > ( ) . To < Newzbin > ( ) ;
var indexers = _kernel . GetAll < IndexerBase > ( ) ;
_kernel . Get < IndexerProvider > ( ) . InitializeIndexers ( indexers . ToList ( ) ) ;
@ -87,15 +88,15 @@ namespace NzbDrone.Core
private static void BindJobs ( )
{
_kernel . Bind < IJob > ( ) . To < RssSyncJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < ImportNewSeriesJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < UpdateInfoJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < DiskScanJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < DeleteSeriesJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < EpisodeSearchJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < RenameEpisodeJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < PostDownloadScanJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < UpdateSceneMappingsJob > ( ) . In Transient Scope( ) ;
_kernel . Bind < IJob > ( ) . To < RssSyncJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < ImportNewSeriesJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < UpdateInfoJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < DiskScanJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < DeleteSeriesJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < EpisodeSearchJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < RenameEpisodeJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < PostDownloadScanJob > ( ) . In Singleton Scope( ) ;
_kernel . Bind < IJob > ( ) . To < UpdateSceneMappingsJob > ( ) . In Singleton Scope( ) ;
_kernel . Get < JobProvider > ( ) . Initialize ( ) ;
_kernel . Get < WebTimer > ( ) . StartTimer ( 30 ) ;