로그관리 다운로드 로그 적재 수정

This commit is contained in:
2026-01-23 10:13:52 +09:00
parent 946ec893dd
commit 77c5354964
2 changed files with 5 additions and 2 deletions

View File

@@ -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/**"); // 학습데이터 다운로드
}
}

View File

@@ -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;
}