실행 에러 질문..
1694
1 câu hỏi đã được viết
테스트 코드 실행으로만 따라오다가 실제 서버를 띄우고 마지막으로 살펴보려하니 아래와 같은 Err가 발생합니다 ...
[ main] h.hellospring.HelloSpringApplication : Started HelloSpringApplication in 11.777 seconds (JVM running for 13.962)
[extShutdownHook] j.LocalContainerEntityManagerFactoryBean : Closing JPA EntityManagerFactory for persistence unit 'default'
[extShutdownHook] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown initiated...
[extShutdownHook] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown completed.
EntityManager 관련하여 문제가 발생해서 바로 죽는거같은데.. 해결방법이 있을까요..?
# dependency
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
// implementation 'org.springframework.boot:spring-boot-starter-jdbc'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
runtimeOnly 'com.h2database:h2'
providedRuntime 'org.springframework.boot:spring-boot-starter-tomcat'
testImplementation('org.springframework.boot:spring-boot-starter-test') {
exclude group: 'org.junit.vintage', module: 'junit-vintage-engine'
}
}
# apllication.properties
spring.datasource.url=jdbc:h2:tcp://localhost/~/test
spring.datasource.driver-class-name=org.h2.Driver
spring.datasource.username=sa
spring.jpa.show-sql=true
spring.jpa.hibernate.ddl-auto=none
Câu trả lời 1
2
안녕하세요, dksworhkd123 님.
의존성 목록을 보니 프로젝트 생성 시 패키징을 Jar가 아닌 War로 선택하신 것으로 보이네요.
해당 의존성을 주석 처리 또는 삭제하시고 다시 실행해보시기 바랍니다.
providedRuntime 'org.springframework.boot:spring-boot-starter-tomcat'
조금이나마 도움이 되었으면 좋겠습니다.
0
답변 감사드립니다! 강의를 보며 이것저것 설정을 변경하는과정에서 외부라이브러리가 꼬인거 같습니다... 기존코드를 그대로 두고 프로젝트 루트폴더 내 .gradle, gradle 삭제후 다시 라이브러리 땡겨와서 해결했습니다..감사합니다!
..
0
84
2
Unused property.....
0
104
2
project JDK is misconfigured
0
139
2
외부 API의 ID 타입(String/UUID)과 내부 도메인의 ID 타입(Long)이 불일치할 때의 설계 정석
0
85
2
단위/통합 테스트 버전충돌 문제
0
92
2
❗️springboot 4.0.2 버전 aspectj dependency 설정❗️
0
236
1
왜 컨트롤러는 변한게 없는데 새로 만든 html 파일이 뜨나요?
0
105
2
윈도우 build test오류 질문
1
103
2
테스트 관련 공부에 대한 조언을 얻고 싶습니다
0
102
2
테스트 실행 시 에러 질문
0
296
1
name을 통한 비교와 객체를 통한 비교
0
77
1
빌드 후 libs 없음
1
132
1
윈도우 gradlew.bat 에러
0
170
1
@PostMapping("/members/new")가 동작하지 않습니다
0
91
1
java static class와 kotlin class
0
82
1
스프링 DB연결
0
129
1
소요 시간
0
89
2
ddl.sql에 빨간 밑줄
1
102
2
welcome page 에러
0
186
3
잘 모르겠습니다.
0
164
2
fail을 똑같이 쳤는데 오류가 발생해요
0
160
2
index.html Welcome page
0
127
1
프로젝트 gradle-groovy ?
0
382
1
테스트코드 메서드명 한글
0
206
2

