更新 MonitorService.java
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user