javax.persistence.PersistenceException: org.hibernate.InstantiationException:
No default constructor for entity: : jpabook.jpashop.domain.Address
기본 생성자가 없다는 내용이다.
JPA 에서 Entity 는 기본 생성자를 가지고 있어야 한다는 제약조건이 있는 것 같다.
해결방법
에러가 발생하는 클래스에 기본 생성자를 생성하거나 @NoArgsConstructor 를 붙이면 해결된다.
'오류 해결' 카테고리의 다른 글
[Spring Boot] Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured. 에러 (0) | 2022.12.20 |
---|---|
깃 오류 (0) | 2022.11.01 |
인터셉터 등록 후 부트스트랩 적용이 안 되는 문제 (0) | 2022.08.10 |
IntelliJ 'Build cancelled while executing task' 에러 (0) | 2022.06.29 |
Cannot resolve symbol 'springframework' 문제해결 - Intellij (0) | 2022.05.20 |