parent
3db15e1615
commit
d26b0db93d
|
@ -178,8 +178,7 @@ public class DisposeTaskController {
|
|||
IDArrayReq reqInfo = mr.getRequestObject(IDArrayReq.class);
|
||||
|
||||
if (reqInfo.getTaskId() == null
|
||||
|| Arrays.stream(reqInfo.getTaskId()).anyMatch(v -> v.length() == 0)
|
||||
|| Arrays.stream(reqInfo.getTaskId()).anyMatch(Objects::isNull)) {
|
||||
|| Arrays.stream(reqInfo.getTaskId()).anyMatch(v -> v.length() == 0)) {
|
||||
log.error("Request taskId params error, error:{}", mr.getMsgContent());
|
||||
return ProtocolRespDTO.result(ErrorCode.ERR_PARAMS);
|
||||
}
|
||||
|
@ -486,7 +485,7 @@ public class DisposeTaskController {
|
|||
|
||||
GetTaskReq reqInfo = mr.getRequestObject(GetTaskReq.class);
|
||||
|
||||
if (reqInfo.getId() == null || Arrays.stream(reqInfo.getId()).anyMatch(Objects::isNull)) {
|
||||
if (reqInfo.getId() == null) {
|
||||
log.error("Request id params error, error:{}", mr.getMsgContent());
|
||||
return ProtocolRespDTO.result(ErrorCode.ERR_PARAMS);
|
||||
}
|
||||
|
@ -585,7 +584,7 @@ public class DisposeTaskController {
|
|||
|
||||
IDArrayReq reqInfo = mr.getRequestObject(IDArrayReq.class);
|
||||
|
||||
if (reqInfo.getTaskId() == null || Arrays.stream(reqInfo.getTaskId()).anyMatch(Objects::isNull)) {
|
||||
if (reqInfo.getTaskId() == null) {
|
||||
log.error("Request taskId params error, error:{}", mr.getMsgContent());
|
||||
return ProtocolRespDTO.result(ErrorCode.ERR_PARAMS);
|
||||
}
|
||||
|
|
|
@ -155,7 +155,7 @@ public class TaskServiceImpl implements TaskService {
|
|||
|
||||
ErrorCode err = taskCacheManager.addTask(cacheTask);
|
||||
|
||||
log.info("Create new dispose task is running: devId:{}, disposeIp:{}, type:{}, result:{}",
|
||||
log.info("Create new dispose task: devId:{}, disposeIp:{}, type:{}, result:{}",
|
||||
task.getDeviceId(), task.getDisposeIp(), task.getType(), err.getMsg());
|
||||
|
||||
return MulReturnType.<ErrorCode, Long>builder().firstParam(err).secondParam(task.getId()).build();
|
||||
|
|
Loading…
Reference in New Issue