更新 MonitorService.java
parent
4e4084e15d
commit
2bd7e21741
|
|
@ -58,8 +58,8 @@ public class MonitorService {
|
|||
long timeDifferenceMillis = currentTimeMillis - device.getLastOnlineTime();
|
||||
long timeDifferenceSeconds = timeDifferenceMillis / 1000;
|
||||
if (timeDifferenceSeconds > device.getTimeOutPeriod()) {
|
||||
logger.info("currentTimeMillis: {},device LastOnlineTime: {},时间差: {},设备超时时间: {}",currentTimeMillis,
|
||||
device.getLastOnlineTime(),timeDifferenceSeconds,device.getTimeOutPeriod());
|
||||
logger.info("Device offline. SN: {}, LastOnlineTime: {}, TimeDifference: {}, TimeoutPeriod: {}",
|
||||
device.getSN(), device.getLastOnlineTime(), timeDifferenceSeconds, device.getTimeOutPeriod());
|
||||
updateStatus(device, 0); // 设备离线
|
||||
logger.info("Update the device status to offline.");
|
||||
sendNotification(device);
|
||||
|
|
|
|||
Loading…
Reference in New Issue