fix: Exception 메세지 처리

dev
Jonguk. Lim 1 month ago
parent 7eea9fe722
commit 55cac28529

File diff suppressed because one or more lines are too long

@ -2,6 +2,7 @@ package cokr.xit.ens.modules.nice.service;
import java.util.*;
import org.apache.commons.lang3.*;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.http.*;
import org.springframework.stereotype.*;
@ -185,7 +186,7 @@ public class NiceCiAcceptService {
} catch (Exception e){
xit.setPrcsCd(IupPrcsCd.TGRF.getCode());
xit.setErrMsg(e.getMessage());
xit.setErrMsg(ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage());
niceCiMapper.updatePrcsCdAndErrorOfInputXit(xit);
}
}

@ -167,7 +167,7 @@ public class NiceCiSendBulkService {
} catch (Exception e){
xit.setPrcsCd(IupPrcsCd.FAIL.getCode());
xit.setErrMsg(e.getMessage());
xit.setErrMsg(ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage());
niceCiMapper.updatePrcsCdAndErrorOfInputXit(xit);
}
}

@ -109,10 +109,10 @@ public class NiceCiStatBulkService {
.build();
} catch (Exception e) {
log.error("NICE CI Status 조회 ERROR::{}", e.getMessage());
log.error("NICE CI Status 조회 ERROR::{}", ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage());
return EnsResponseVO.errBuilder()
.errCode(EnsErrCd.ERR999)
.errMsg(e.getMessage())
.errMsg(ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage())
.build();
}
return EnsResponseVO.okBuilder()
@ -259,7 +259,7 @@ public class NiceCiStatBulkService {
EnsException ens = (EnsException)e;
log.error("NICE CI Status 조회 ERROR::{}[{}]", ens.getMessage(), ens.getErrCd());
} else {
log.error("NICE CI Status 조회 ERROR::{}", e.getMessage());
log.error("NICE CI Status 조회 ERROR::{}", ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage());
}
}
}

@ -162,8 +162,8 @@ public class NiceCiApiService {
throw new EnsException(EnsErrCd.API_COMM_ERROR, "NICE CI Socket 서버 응답 시간 초과");
} catch (IOException e) {
log.error("NICE CI Socket 서버 응답 시간 초과: " + e.getMessage());
throw new EnsException(EnsErrCd.API_COMM_ERROR, e.getMessage());
log.error("NICE CI Socket 서버 ERROR :: {}", ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage());
throw new EnsException(EnsErrCd.API_COMM_ERROR, ObjectUtils.isNotEmpty(e.getCause())? e.getCause().getMessage() : e.getMessage());
}
return rtnMsg;
}

Loading…
Cancel
Save