로그관리 다운로드 로그 적재 수정
This commit is contained in:
@@ -41,6 +41,7 @@ public class WebConfig implements WebMvcConfigurer {
|
||||
public void addInterceptors(InterceptorRegistry registry) {
|
||||
registry
|
||||
.addInterceptor(fileDownloadInteceptor)
|
||||
.addPathPatterns("/api/inference/download/**"); // 추론 파일 다운로드 API만 //TODO 추후 추가
|
||||
.addPathPatterns("/api/inference/download/**") // 추론 파일 다운로드
|
||||
.addPathPatterns("/api/training-data/stage/download/**"); // 학습데이터 다운로드
|
||||
}
|
||||
}
|
||||
|
||||
@@ -69,7 +69,9 @@ public class ApiResponseAdvice implements ResponseBodyAdvice<Object> {
|
||||
response.setStatusCode(apiResponse.getHttpStatus());
|
||||
|
||||
String actionType = HeaderUtil.get(servletRequest, "kamco-action-type");
|
||||
if (actionType == null) { // actionType 이 없으면 로그 저장하지 않기
|
||||
// actionType 이 없으면 로그 저장하지 않기 || download 는 FileDownloadInterceptor 에서 하기
|
||||
// (file down URL prefix 추가는 WebConfig.java 에 하기)
|
||||
if (actionType == null || actionType.equalsIgnoreCase("download")) {
|
||||
return body;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user