-
[Java] spring boot jar_cached tmp 파일이 계속 증가할 때기술과 산업/언어 및 프레임워크 2020. 5. 6. 19:39728x90
1. 문제 상황
리본 클라이언트로 핑(Ping)을 swagger-ui.html 주소로 보낼 때 호출 될 때마다 약 2MB짜리 jar_cached 임시 파일을 생성함.
2. Spring boot, properties
기본 값은 classpath:/META-INF/resources/,classpath:/resources/, classpath:/static/,classpath:/public/ 순서로 되어있다.
3. 해결
아래 내용에서 처럼 순서를 변경해주거나 별도의 ping-pong 컨트롤러를 하나 만들어 주면된다.
spring:
resources:
static-locations:
- classpath:/resources/,classpath:/META-INF/resources/,classpath:/static/,classpath:/public/
728x90'기술과 산업 > 언어 및 프레임워크' 카테고리의 다른 글
[C++] 입출력 속도 해결 cout, cin (0) 2021.03.23 [C++] 디버깅으로 배열에 담긴 값 확인 (2) 2021.03.23 Gradle 사용시 커스텀 라이브러리 업데이트가 잘 안될경우 (1) 2019.07.26 [Java] Creating a Fat Jar or Executable jar in Gradle (1) 2019.07.26 [Java] System Properties (0) 2019.07.26