• 카테고리

    질문 & 답변
  • 세부 분야

    백엔드

  • 해결 여부

    미해결

DevTools 관련 질문

22.12.18 03:51 작성 22.12.18 03:54 수정 조회수 179

0

안녕하세요.

Thymeleaf를 이용한 html 파일 수정 후 재시작하지 않고 반영된 내용을 곧바로 확인하기 위해 아래와 같이 구성했습니다.

resources/application.yml

spring:
  profiles:
    active: local
  devtools:
    restart:
      enabled: false
  thymeleaf:
    cache: false
  • Intellij 설정

    • Run/Debug Configurations > Spring Boot > (구동중인 App)

      • On 'Update' action/On frame deactivation > Update class and resources로 설정.

    • Settings > Build, Execution, Deployment > Compiler에 "Build project automatically" 선택.

    • Settings > Advanced Settings > "Allow auto-make to start even if developed application is currently running" 선택.

위와 같이 구성해놓고 브라우저에서 화면을 띄우면 아래와 같이 간헐적으로 TemplateInputException이 나옵니다. resources/ 하위에 있는 앞단 코드를 수정한 후, 수정한 내역을 확인할 때도 간헐적으로 나옵니다.

ERROR 9104 --- [nio-8080-exec-1] o.a.c.c.C.[.[.[/].[dispatcherServlet]    : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.thymeleaf.exceptions.TemplateInputException: Error resolving template [index], template might not exist or might not be accessible by any of the configured Template Resolvers] with root cause

org.thymeleaf.exceptions.TemplateInputException: Error resolving template [index], template might not exist or might not be accessible by any of the configured Template Resolvers
	at org.thymeleaf.engine.TemplateManager.resolveTemplate(TemplateManager.java:869) ~[thymeleaf-3.0.15.RELEASE.jar:3.0.15.RELEASE]
	at org.thymeleaf.engine.TemplateManager.parseAndProcess(TemplateManager.java:607) ~[thymeleaf-3.0.15.RELEASE.jar:3.0.15.RELEASE]

그리고 위에 기재한 설정에서 On frame deactivation 설정을 아예 지워버리면, 서버를 내렸다 올려야만 변경된 내용 확인이 가능한 상황입니다.

어떠한 문제가 있는건지 전혀 감이 안오네요.

어떠한 부분을 추가로 확인해봐야하나요??

확인 후 알려주시면 감사하겠습니다.

답변 0

답변을 작성해보세요.

답변을 기다리고 있는 질문이에요.
첫번째 답변을 남겨보세요!