搬家调试

20230922-ljl-fixBug
qiushengjie 1 year ago
parent e2fc849796
commit de0cdfa37d

@ -45,7 +45,7 @@ public class CheckAuditStatusTimeoutTaskService extends TaskBaseService {
*
*/
public int getCorePoolSiz() {
return 4;
return 1;
}
/**

@ -46,7 +46,7 @@ public class MoveMaterialAuditBufferTaskService extends TaskBaseService {
*
*/
public int getCorePoolSiz() {
return 3;
return 1;
}
/**
@ -71,7 +71,7 @@ public class MoveMaterialAuditBufferTaskService extends TaskBaseService {
}
@Async("moveMaterialAuditBufferPool")
@Scheduled(fixedRate =3000)
@Scheduled(fixedRate =2000)
@Override
public void runTask() {
super.runTask();
@ -84,7 +84,7 @@ public class MoveMaterialAuditBufferTaskService extends TaskBaseService {
public Object getTask() {
long lastBufferId = 0;
int limit = 20;
log.info("start bufferToQueue");
log.info("start moveMaterialAuditBuffer");
while (true) {
// 判断queue是否满了
int queueCnt = materialAuditStatusBufferService.count();
@ -133,7 +133,7 @@ public class MoveMaterialAuditBufferTaskService extends TaskBaseService {
} catch (Exception e) {
e.printStackTrace();
transactionManager.rollback(status);
log.info("任务执行失败 数据回滚: ", e);
log.error("任务执行失败 数据回滚: moveMaterialAuditBuffer", e);
if (e.getMessage().contains("udx_material_id")) {
List<String> materialIdList = bufferList.stream().map(MaterialAuditStatusBuffer::getMaterialId).collect(Collectors.toList());
List<String> exitMaterialIds = materialAuditStatusQueueService.getByMaterialIdList(materialIdList);
@ -143,7 +143,7 @@ public class MoveMaterialAuditBufferTaskService extends TaskBaseService {
}
}
log.info("end bufferToQueue");
log.info("end moveMaterialAuditBuffer");
return true;
}

@ -156,6 +156,7 @@ public class ProcessMovePublishToPicTaskService extends TaskBaseService {
*/
@Override
public Object getTask() {
log.info("start processMovePublishToPicTask");
MoveProductPublishToPicQueue lockMsg = lockSolidRedisQueue();
if (Objects.isNull(lockMsg)) {
E.throwMSException("locked queueMsg is null");

@ -226,10 +226,10 @@ public class ProcessProductPublishTaskService extends TaskBaseService {
*/
@Override
public Object getTask() {
long startTime = System.currentTimeMillis();
log.info("start getProductPublishQueue");
log.info("lockPublishTaskQueue start lockPublishTask");
long startTime = System.currentTimeMillis();
// 锁定任务并获取一条任务
log.info("lockPublishTaskQueue start lockPublishTask");
MoveProductPublishQueueBO queueMsg = lockProductPublishQueue();
log.info("MoveProductPublishQueueBO taskDetailId" + queueMsg.getMoveProductPublishQueueId());
if (Objects.isNull(queueMsg)) {

Loading…
Cancel
Save