Merge remote-tracking branch 'origin/jenkins_with_weblogic' of C:/KJB_DEV/eapim-bundle/bundles/251230/elink-online-common_incremental_2025-12-01.bundle into jenkins_with_weblogic
This commit is contained in:
+1
-1
@@ -725,7 +725,7 @@ public class HttpClient5AdapterServiceRest extends HttpClient5AdapterServiceSupp
|
||||
*/
|
||||
private void setNiceOnAuthHeaders(HttpUriRequestBase method, String auth) throws Exception {
|
||||
method.setHeader("Authorization",
|
||||
String.format("%s %s", "bearer", auth)); // 나이스지키미 format임
|
||||
String.format("%s %s", "bearer", auth)); // 나이스지키미 format임, bearer을 소문자로 보내야함
|
||||
String productId = PropManager.getInstance().getProperty("NiceOnProperty","productId.value");
|
||||
method.setHeader("ProductID", productId);
|
||||
//method.setHeader("Authorization",
|
||||
|
||||
+18
-2
@@ -6,6 +6,7 @@ import com.eactive.eai.adapter.AdapterVO;
|
||||
import com.eactive.eai.adapter.Keys;
|
||||
import com.eactive.eai.adapter.http.HttpMemoryLogger;
|
||||
import com.eactive.eai.adapter.http.HttpStatusException;
|
||||
import com.eactive.eai.adapter.http.dynamic.HttpAdapterServiceKey;
|
||||
import com.eactive.eai.adapter.http.dynamic.HttpAdapterServiceSupport;
|
||||
import com.eactive.eai.common.exception.ExceptionUtil;
|
||||
import com.eactive.eai.common.util.CommonLib;
|
||||
@@ -26,8 +27,11 @@ import java.net.URLDecoder;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.Enumeration;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Properties;
|
||||
import java.util.TreeMap;
|
||||
|
||||
public class HttpAdapterServiceStandard extends HttpAdapterServiceSupport
|
||||
{
|
||||
@@ -218,8 +222,20 @@ public class HttpAdapterServiceStandard extends HttpAdapterServiceSupport
|
||||
if (addData.length() > 0){
|
||||
responseData = addData + responseData;
|
||||
}
|
||||
// UI와 통신시(UTF-8) 변환오류로 ENCODE 제거
|
||||
response.setContentType("text/plain");
|
||||
|
||||
// 300응답에서 받은 Header정보 사용하기 위해 읽어옴.
|
||||
Map<String, Object> responsePropertyMap = new HashMap<String, Object>();
|
||||
responsePropertyMap = (Map<String, Object>) prop.get(OUTBOUND_PROPERTY_MAP);
|
||||
Properties responseHeaders = (Properties)responsePropertyMap.get(OUTBOUND_RESPONSE_HEADERS);
|
||||
Map<String, String> responseHeaderMap = new TreeMap<>(String.CASE_INSENSITIVE_ORDER);
|
||||
// Properties 내용을 모두 복사
|
||||
for (String name : responseHeaders.stringPropertyNames()) {
|
||||
responseHeaderMap.put(name, responseHeaders.getProperty(name));
|
||||
}
|
||||
String contentTytpe = responseHeaderMap.get("Content-Type");
|
||||
|
||||
// UI와 통신시(UTF-8) 변환오류로 ENCODE 제거
|
||||
response.setContentType(contentTytpe); // 300응답에서 받은 Content-Type을 그대로 적용.
|
||||
response.setCharacterEncoding(encode);
|
||||
response.getWriter().print(responseData);
|
||||
if (logger.isDebug()){
|
||||
|
||||
@@ -67,11 +67,9 @@ public class InflowControlManager implements Lifecycle, Bucket {
|
||||
*/
|
||||
public static Boolean isTargetOfInflowControl(EAIServerManager eaiServerManager, EAIMessage eaiMessage) {
|
||||
InterfaceMapper mapper = eaiMessage.getMapper();
|
||||
String inExDiv = MessageUtil.getInExDivision(mapper.getInExDivision(eaiMessage.getStandardMessage()),
|
||||
eaiMessage.getInternalExternalDvcd()); // 1|2
|
||||
String returnType = mapper.getSendRecvDivision(eaiMessage.getStandardMessage()); // S|R
|
||||
|
||||
if (STDMessageKeys.DIRECTION_IN.equals(inExDiv) && STDMessageKeys.SEND_RECV_CD_SEND.equals(returnType)) {
|
||||
if (STDMessageKeys.SEND_RECV_CD_SEND.equals(returnType)) {
|
||||
return Boolean.valueOf(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -1036,6 +1036,7 @@ public class RequestProcessor extends RequestProcessorSupport {
|
||||
}
|
||||
}
|
||||
|
||||
String inflowErrorMsg;
|
||||
if (blockedType.length() > 0) {
|
||||
InflowTargetVO inflowTargetVO = null;
|
||||
InflowGroupVO inflowGroupVO = null;
|
||||
@@ -1046,7 +1047,6 @@ public class RequestProcessor extends RequestProcessorSupport {
|
||||
} else {
|
||||
inflowTargetVO = bucket.getInterfaceInflowThreashold(vo.getEaiSvcCd());
|
||||
}
|
||||
String inflowErrorMsg;
|
||||
// 에러처리
|
||||
vo.setRspErrorCode(EAIMessageKeys.EAI_INFLOW_BLOCKED_CODE);
|
||||
if (inflowGroupVO != null) {
|
||||
@@ -1161,7 +1161,8 @@ public class RequestProcessor extends RequestProcessorSupport {
|
||||
if (logger.isError())
|
||||
logger.error(guidLogPrefix + " : 유량제어 비동기 에러응답송신 실패 - " + ee.toString());
|
||||
}
|
||||
return null;
|
||||
throw new HttpStatusException(eaiMsg.getRspErrMsg(), eaiMsg.getRspErrCd(),
|
||||
HttpStatus.TOO_MANY_REQUESTS.value());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1273,7 +1274,7 @@ public class RequestProcessor extends RequestProcessorSupport {
|
||||
}
|
||||
|
||||
//응답 전 표준 전문의 로직 처리 필요 한 경우를 위해 호출
|
||||
standardManager.getMessageCoordinator().coordinateBeforeResponse(standardMessage, vo, prop, inboundCharset);
|
||||
standardManager.getMessageCoordinator().coordinateBeforeResponse(retEaiMsg.getStandardMessage(), vo, prop, inboundCharset);
|
||||
|
||||
// 10. 응답 거래로그 Logging
|
||||
if(EAIMessageKeys.SYNC_SVC.equals(svcTsmtUsgTp) &&
|
||||
|
||||
@@ -22,6 +22,7 @@ public class StandardMessageUtil {
|
||||
|
||||
public static String requestProcessorClass = "com.eactive.eai.inbound.processor.RequestProcessor";
|
||||
|
||||
public static String REST_URL_ACTION0 = "com.eactive.eai.inbound.action.RestAdapterMethodUrlRequestAction";
|
||||
public static String REST_URL_ACTION1 = "com.eactive.eai.inbound.action.RestUrlAdapterGroupParseRequestAction";
|
||||
public static String REST_URL_ACTION2 = "com.eactive.eai.inbound.action.RestUrlParseRequestAction";
|
||||
|
||||
@@ -49,7 +50,7 @@ public class StandardMessageUtil {
|
||||
if (standardMessage == null) {
|
||||
// API 서비스일경우 PathVariable 지원 추가
|
||||
// ex) /api/account/{no}
|
||||
if (StringUtils.equalsAny(vo.getActionName(), REST_URL_ACTION1, REST_URL_ACTION2)) {
|
||||
if (StringUtils.equalsAny(vo.getActionName(), REST_URL_ACTION0, REST_URL_ACTION1, REST_URL_ACTION2)) {
|
||||
standardMessage = stdMessageManager.getSTDMessageForPathVariable(vo.getSelectedKey());
|
||||
}
|
||||
|
||||
@@ -79,7 +80,7 @@ public class StandardMessageUtil {
|
||||
}
|
||||
}
|
||||
|
||||
if (StringUtils.equalsAny(actionName, REST_URL_ACTION1, REST_URL_ACTION2)) {
|
||||
if (StringUtils.equalsAny(actionName, REST_URL_ACTION0, REST_URL_ACTION1, REST_URL_ACTION2)) {
|
||||
return stdMessageManager.getMatchedPathVariable(key);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user