Compare commits

..

4 Commits

Author SHA1 Message Date
curry772 d79bcf8430 서브모듈 인덱스 업데이트 (elink-online-common)
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-31 10:05:48 +09:00
curry772 e049420ca3 내부 오류 시 ERROR_CODE_AUTH_FAIL로 설정되는 현상 수정 2026-07-30 13:09:34 +09:00
curry772 10bbd57c78 서브모듈 인덱스 업데이트 2026-07-30 09:15:34 +09:00
curry772 70c636d719 API 거래 uuid(TRANSACTION_UUID) 앞 prefix에 GroupInstId 추가 2026-07-27 10:41:59 +09:00
5 changed files with 15 additions and 8 deletions
@@ -51,6 +51,7 @@ public class DJBApiAdapterController implements HttpAdapterServiceKey {
@Autowired
DJBApiAdapterService service;
EAIServerManager eaiServerManager;
/**
* DJErp OAuth 조기 적용을 위한 Controller
*
@@ -89,7 +90,13 @@ public class DJBApiAdapterController implements HttpAdapterServiceKey {
ResponseEntity<String> responseEntity = null;
Properties transactionProp = new Properties();
String uuid = UUIDGenerator.getUUID().toString().replaceAll("-", "");
if(eaiServerManager == null)
eaiServerManager = EAIServerManager.getInstance();
String instid = eaiServerManager.getGroupInstId();
String uuid = instid+UUIDGenerator.getUUID().toString().replaceAll("-", "");
transactionProp.setProperty(TransactionContextKeys.TRANSACTION_UUID, uuid);
transactionProp.put(INBOUND_REQUESTED_TIME, receivedTimeStr);
@@ -154,14 +161,14 @@ public class DJBApiAdapterController implements HttpAdapterServiceKey {
responseEntity = ResponseEntity.status(e1.getStatus()).contentType(mediaType).body(responseErrorMsg);
} else if (e instanceof JwtAuthException) {
responseErrorMsg = genErrorResponseMessage(adapterGroupName, adapterName,
transactionProp, MessageUtil.ERROR_CODE_AP_ERROR, e, adptMsgType, encode, errorResponseFormat);
transactionProp, MessageUtil.ERROR_CODE_AUTH_FAIL, e, adptMsgType, encode, errorResponseFormat);
JwtAuthException e1 = (JwtAuthException) e;
this.logError(servletRequest, adapterGroupName, e1.getCode(), responseErrorMsg, transactionProp, e);
logger.error("ApiAdapterController] " + adapterGroupName + "-" + adapterName + ">>" + e.getMessage(), e);
responseEntity = ResponseEntity.status(HttpStatus.UNAUTHORIZED).contentType(mediaType).body(responseErrorMsg);
} else if (e instanceof HttpStatusException) {
responseErrorMsg = genErrorResponseMessage(adapterGroupName, adapterName,
transactionProp, MessageUtil.ERROR_CODE_AUTH_FAIL, e, adptMsgType, encode, errorResponseFormat);
transactionProp, MessageUtil.ERROR_CODE_AP_ERROR, e, adptMsgType, encode, errorResponseFormat);
logger.error("ApiAdapterController] " + adapterGroupName + "-" + adapterName + ">>" + e.getMessage());
HttpStatusException e1 = (HttpStatusException) e;
responseEntity = ResponseEntity.status(e1.getStatus()).contentType(mediaType).body(responseErrorMsg);