Merge pull request #161 from ZengLiangl/main

fix: Check failure data from 2 minutes ago
This commit is contained in:
zongzibinbin 2024-01-13 12:19:14 +08:00 committed by GitHub
commit e1fd59b7a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,7 +22,7 @@ public class SecureInvokeRecordDao extends ServiceImpl<SecureInvokeRecordMapper,
public List<SecureInvokeRecord> getWaitRetryRecords() {
Date now = new Date();
//查2分钟前的失败数据避免刚入库的数据被查出来
DateTime afterTime = DateUtil.offsetMinute(now, (int) SecureInvokeService.RETRY_INTERVAL_MINUTES);
DateTime afterTime = DateUtil.offsetMinute(now, -(int) SecureInvokeService.RETRY_INTERVAL_MINUTES);
return lambdaQuery()
.eq(SecureInvokeRecord::getStatus, SecureInvokeRecord.STATUS_WAIT)
.lt(SecureInvokeRecord::getNextRetryTime, new Date())