Commit 0316b882 by huangfusuper

解决快照报错的问题

parent 227d80d0
......@@ -55,7 +55,7 @@ public class DaemonScanThreadRunHelperRedisLock extends BaseDaemonScanThreadRunH
log.error("---------{}---------",e.getMessage());
}
}
sleepTime = sleepTime==null?examplesValue.UNIVERSAL_WAIT_TIME:sleepTime;
sleepTime = sleepTime==null || sleepTime<=0?examplesValue.UNIVERSAL_WAIT_TIME:sleepTime;
dateAligned(sleepTime,threadName);
}
});
......
......@@ -40,6 +40,9 @@ public class FlowStatusSnapshootServiceImpl implements FlowStatusSnapshootServic
String thisHourStr = DateUtil.dateFormat(new Date(), "HH");
String hourBefStr = String.valueOf(Integer.parseInt(thisHourStr)+1);
if (hourBefStr.length() ==1 ) {
hourBefStr = "0"+hourBefStr;
}
//20201212 12:12:12
Date date = DateUtil.strFormatDate(thisDateStr + " " + hourBefStr + ":00:00", "yyyy-MM-dd HH:mm:ss");
long between = cn.hutool.core.date.DateUtil.between(new Date(), date, DateUnit.MINUTE);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment