From f92c6bf13a51ebec77407970cf5e822538dd709d Mon Sep 17 00:00:00 2001
From: yxFwq <1>
Date: 星期四, 09 一月 2025 08:01:23 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/asrs/task/StaEscalationScheduler.java | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/src/main/java/com/zy/asrs/task/StaEscalationScheduler.java b/src/main/java/com/zy/asrs/task/StaEscalationScheduler.java
index f9f4c0b..1d3dff4 100644
--- a/src/main/java/com/zy/asrs/task/StaEscalationScheduler.java
+++ b/src/main/java/com/zy/asrs/task/StaEscalationScheduler.java
@@ -1,7 +1,9 @@
package com.zy.asrs.task;
+import com.zy.asrs.domain.enums.LedErrorAreaType;
import com.zy.asrs.task.core.ReturnT;
import com.zy.asrs.task.handler.StaEscalationHandler;
+import com.zy.asrs.utils.LedErrorThreadUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
@@ -28,9 +30,26 @@
break;
}
}catch (Exception e){
+ LedErrorThreadUtil.ledErrorThread("2妤肩炕杞�掓枡涓婃姤erp澶辫触!绔欑偣鍙凤細"+staNo,4, LedErrorAreaType.ONE_OTHER.getDesc());
log.error("绔欑偣"+staNo+"2妤肩炕杞�掓枡淇℃伅涓婁紶澶勭悊澶辫触锛屽紓甯镐俊鎭細"+e);
}
}
}
+ @Scheduled(cron = "0/3 * * * * ? ")
+ private void executeOverturn(){//2妤肩炕杞�掓枡鍚庡洖搴撴爣璁版竻闄�
+ int[] staNos =new int[]{126,131,310,312};
+ for (int staNo : staNos){
+ try{
+ ReturnT<String> result = staEscalationHandler.start2(staNo);
+ if (result.getCode()==200){
+ break;
+ }
+ }catch (Exception e){
+ LedErrorThreadUtil.ledErrorThread("2妤肩炕杞�掓枡鍚庡洖搴撴爣璁版竻闄ゅけ璐�!绔欑偣鍙凤細"+staNo,4, LedErrorAreaType.ONE_OTHER.getDesc());
+ log.error("绔欑偣"+staNo+"2妤肩炕杞�掓枡鍚庡洖搴撴爣璁版竻闄ゅけ璐ワ紝寮傚父淇℃伅锛�"+e);
+ }
+ }
+ }
+
}
--
Gitblit v1.9.1