修复因为心跳重发导致的心跳间隔异常
parent
ef5018de2d
commit
4162706ec4
|
@ -78,8 +78,10 @@ public class KeepaliveNotifyMessageHandler extends SIPRequestProcessorParent imp
|
||||||
device.setKeepaliveIntervalTime(60);
|
device.setKeepaliveIntervalTime(60);
|
||||||
}else {
|
}else {
|
||||||
long lastTime = DateUtil.yyyy_MM_dd_HH_mm_ssToTimestamp(device.getKeepaliveTime());
|
long lastTime = DateUtil.yyyy_MM_dd_HH_mm_ssToTimestamp(device.getKeepaliveTime());
|
||||||
|
if (System.currentTimeMillis()/1000-lastTime > 10) {
|
||||||
device.setKeepaliveIntervalTime(new Long(System.currentTimeMillis()/1000-lastTime).intValue());
|
device.setKeepaliveIntervalTime(new Long(System.currentTimeMillis()/1000-lastTime).intValue());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
device.setKeepaliveTime(DateUtil.getNow());
|
device.setKeepaliveTime(DateUtil.getNow());
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue