调整心跳超时重新连接
This commit is contained in:
parent
3ea0d08ca6
commit
5ca3132c49
5
pom.xml
5
pom.xml
@ -24,7 +24,10 @@
|
|||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-starter-security</artifactId>
|
<artifactId>spring-boot-starter-security</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-starter-actuator</artifactId>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-starter-oauth2-resource-server</artifactId>
|
<artifactId>spring-boot-starter-oauth2-resource-server</artifactId>
|
||||||
|
@ -102,10 +102,10 @@ public class SwitchLostAlertMonitoringTask2 implements AlertMonitoringTask {
|
|||||||
boolean timeOver = this.timeOver(switchBuild.getReceiveTime(), guardConfig.getSwitchLostTimes());
|
boolean timeOver = this.timeOver(switchBuild.getReceiveTime(), guardConfig.getSwitchLostTimes());
|
||||||
String switchPutName = this.getDefaultName(AlertType.SWITCH_LOST, lineId, switchBuild.getRtuId());
|
String switchPutName = this.getDefaultName(AlertType.SWITCH_LOST, lineId, switchBuild.getRtuId());
|
||||||
if (saveIsLost && timeOver) {
|
if (saveIsLost && timeOver) {
|
||||||
log.info("道岔失表超时,准备报警 线路[{}] 设备[{}] 接受时间[{}] 发送时间[{}] 对应地图设备id[{}]"
|
|
||||||
, lineId, switchBuild.getId(), switchBuild.getReceiveTime(), switchBuild.getTimestamp(), turnout.getCommon().getId());
|
|
||||||
//失表超时
|
//失表超时
|
||||||
if (alertManager.putAlterDevice(lineId, switchPutName, switchBuild.getId())) {
|
if (alertManager.putAlterDevice(lineId, switchPutName, switchBuild.getId())) {
|
||||||
|
log.info("道岔失表超时,准备报警 线路[{}] 设备[{}] 接受时间[{}] 发送时间[{}] 对应地图设备id[{}]"
|
||||||
|
, lineId, switchBuild.getId(), switchBuild.getReceiveTime(), switchBuild.getTimestamp(), turnout.getCommon().getId());
|
||||||
String alertMsg = String.format("设备[%s]失表", switchBuild.getId());
|
String alertMsg = String.format("设备[%s]失表", switchBuild.getId());
|
||||||
NccAlertInfo alertInfo = this.alertInfoService.createAlert2(Optional.empty(), AlertType.SWITCH_LOST, switchBuild, alertMsg, turnout.getCommon().getId(),
|
NccAlertInfo alertInfo = this.alertInfoService.createAlert2(Optional.empty(), AlertType.SWITCH_LOST, switchBuild, alertMsg, turnout.getCommon().getId(),
|
||||||
AlertDeviceType.DEVICE_TYPE_SWITCH, false);
|
AlertDeviceType.DEVICE_TYPE_SWITCH, false);
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
server:
|
server:
|
||||||
port: 9081
|
port: 9081
|
||||||
|
shutdown: "graceful"
|
||||||
spring:
|
spring:
|
||||||
profiles:
|
profiles:
|
||||||
active: local
|
active: local
|
||||||
@ -46,10 +47,27 @@ jwt:
|
|||||||
key:
|
key:
|
||||||
pub: classpath:app.pub
|
pub: classpath:app.pub
|
||||||
prv: classpath:app.key
|
prv: classpath:app.key
|
||||||
#过滤OCC 数据中的rtu
|
occ-not-handle:
|
||||||
occ-not-handle-rtu: '{3: "81,82"}'
|
lineId: 3
|
||||||
|
#过滤OCC 数据中的rtu
|
||||||
|
filterRtuIds:
|
||||||
|
- 81
|
||||||
|
- 82
|
||||||
|
|
||||||
|
|
||||||
#长时间没有接收occ数据超时,重新获取基础数据时间(小时)
|
#长时间没有接收occ数据超时,重新获取基础数据时间(小时)
|
||||||
receive-msg-timeout: 1
|
receive-msg-timeout: 1
|
||||||
#检测硬件变化(cpu,内存)
|
#检测硬件变化(cpu,内存)
|
||||||
monitor-handware-change: true
|
monitor-handware-change: true
|
||||||
|
#management:
|
||||||
|
# endpoints:
|
||||||
|
# web:
|
||||||
|
# exposure:
|
||||||
|
# include: '*'
|
||||||
|
# server:
|
||||||
|
# port: 9081
|
||||||
|
# endpoint:
|
||||||
|
# shutdown:
|
||||||
|
# enabled: true
|
||||||
|
# health:
|
||||||
|
# show-details: always
|
||||||
|
@ -1 +1 @@
|
|||||||
Subproject commit 226023c351e10e7e07cc7c48e1dbde661091b6b5
|
Subproject commit ee5fb2079424cb1ac7a049ead18e0c50aa98606b
|
Loading…
Reference in New Issue
Block a user