啓動排程
This commit is contained in:
parent
595526ab15
commit
4085946ed8
@ -144,17 +144,17 @@ namespace BackendWorkerService
|
||||
//#endregion
|
||||
|
||||
#region 定時取得氣象API
|
||||
//services.AddSingleton<Quartz.Jobs.WeatherAPIJob>();
|
||||
//services.AddSingleton(
|
||||
//new JobSchedule(jobType: typeof(Quartz.Jobs.WeatherAPIJob), cronExpression: configuration.GetValue<string>("BackgroundServiceCron:WeatherAPIJob"))
|
||||
//);
|
||||
services.AddSingleton<Quartz.Jobs.WeatherAPIJob>();
|
||||
services.AddSingleton(
|
||||
new JobSchedule(jobType: typeof(Quartz.Jobs.WeatherAPIJob), cronExpression: configuration.GetValue<string>("BackgroundServiceCron:WeatherAPIJob"))
|
||||
);
|
||||
#endregion
|
||||
|
||||
#region 太陽能(設定每 小時 執行一次)
|
||||
//services.AddSingleton<ArchiveSolarHourJob>();
|
||||
//services.AddSingleton(
|
||||
//new JobSchedule(jobType: typeof(ArchiveSolarHourJob), cronExpression: configuration.GetValue<string>("BackgroundServiceCron:ArchiveSolarHourJob"))
|
||||
//);
|
||||
services.AddSingleton<ArchiveSolarHourJob>();
|
||||
services.AddSingleton(
|
||||
new JobSchedule(jobType: typeof(ArchiveSolarHourJob), cronExpression: configuration.GetValue<string>("BackgroundServiceCron:ArchiveSolarHourJob"))
|
||||
);
|
||||
#endregion
|
||||
|
||||
#region 太陽能(設定每 日 執行一次)
|
||||
|
Loading…
Reference in New Issue
Block a user