心跳周期小于10min时,10分钟收不到心跳才会重启

nx2024
XI.CHEN 6 months ago committed by Matthew
parent a55b4f7cf4
commit 182343541e

@ -435,7 +435,10 @@ public class MpMasterService extends Service {
FilesUtils.closeFriendly(runningFile); FilesUtils.closeFriendly(runningFile);
} }
if (mPreviousMpHbTime <= ts && ts - mPreviousMpHbTime > mMpHeartbeatDuration * 2) { long tempduration = mMpHeartbeatDuration;
if(mMpHeartbeatDuration < 600000)
tempduration = 300000;
if (mPreviousMpHbTime <= ts && ts - mPreviousMpHbTime > tempduration * 2) {
// MpApp is not running // MpApp is not running
if (ts - mTimeToStartMpApp >= 1800000) { // 30 minutes 30 * 60 * 1000 if (ts - mTimeToStartMpApp >= 1800000) { // 30 minutes 30 * 60 * 1000
MicroPhotoContext.restartMpApp(context, "MpMST Keep Alive Detection"); MicroPhotoContext.restartMpApp(context, "MpMST Keep Alive Detection");

Loading…
Cancel
Save