feat(1.3.0-beta2): 修复retryStatus为NULL问题
This commit is contained in:
parent
c3d594fc41
commit
1e0095c6de
@ -57,9 +57,10 @@ public class JobTaskBatchHandler {
|
||||
@Transactional
|
||||
public boolean handleResult(CompleteJobBatchDTO completeJobBatchDTO) {
|
||||
Assert.notNull(completeJobBatchDTO.getTaskType(), ()-> new SnailJobServerException("taskType can not be null"));
|
||||
Assert.notNull(completeJobBatchDTO.getRetryStatus(), ()-> new SnailJobServerException("retryStatus can not be null"));
|
||||
|
||||
// 非重试流量幂等处理
|
||||
if(!completeJobBatchDTO.getRetryStatus()) {
|
||||
if(Boolean.FALSE.equals(completeJobBatchDTO.getRetryStatus())) {
|
||||
// 幂等处理
|
||||
Long countJobTaskBatch = jobTaskBatchMapper.selectCount(new LambdaQueryWrapper<JobTaskBatch>()
|
||||
.eq(JobTaskBatch::getId, completeJobBatchDTO.getTaskBatchId())
|
||||
|
@ -49,6 +49,7 @@ public class RunningJobPrepareHandler extends AbstractJobPrepareHandler {
|
||||
JobOperationReasonEnum jobOperationReasonEnum = JobOperationReasonEnum.NONE;
|
||||
CompleteJobBatchDTO completeJobBatchDTO = JobTaskConverter.INSTANCE.completeJobBatchDTO(prepare);
|
||||
completeJobBatchDTO.setJobOperationReason(jobOperationReasonEnum.getReason());
|
||||
completeJobBatchDTO.setRetryStatus(Boolean.FALSE);
|
||||
if (jobTaskBatchHandler.handleResult(completeJobBatchDTO)) {
|
||||
blockStrategy = BlockStrategyEnum.CONCURRENCY.getBlockStrategy();
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user