1、解决SnowflakeIdHeler.NextId()空引用问题

2、将Agv心跳检测服务移至自定义定时服务,统一维护管理
This commit is contained in:
yang.lee
2023-10-16 13:53:33 +08:00
parent 9597c9b3e5
commit 66242f929d
10 changed files with 163 additions and 204 deletions

View File

@@ -65,10 +65,9 @@ public class Startup : AppStartup
//注册任务消息通知 added by ly on 20230814
services.AddTaskMessageNotify();
SnowflakeIdHelper.InitYitIdWorker();
//定时任务
services.AddHostedService<TimedTaskBackgroundService>();
//Agv心跳监听服务
//services.AddHostedService<AgvHeartbeatMonitorService>();
}
@@ -116,7 +115,7 @@ public class Startup : AppStartup
endpoints.MapControllerRoute(name: "default", pattern: "{controller=Home}/{action=Index}/{id?}");
});
SnowflakeIdHelper.InitYitIdWorker();
//SnowflakeIdHelper.InitYitIdWorker();
bool isStartTimeJob = App.GetConfig<bool>("IsStartTimeJob");
if (isStartTimeJob)