Caused by: org.hibernate.AnnotationException:
No identifier specified for entity: hello.hellospring.domain.Member
import org.springframework.data.annotation.Id;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
@Entity
public class Member {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
오류를 잘 읽어 보면 AnnotationExcpertion이 발생 했음을 알 수 있다.
import org.springframework.data.annotation.Id가 import되어 있을 수 있다.
그럴 경우 import javax.persistence.Id로 수정하면 된다.
'트러블슈팅 > SPRING' 카테고리의 다른 글
[스프링] Maven build error(Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved) (2) | 2022.10.12 |
---|---|
SVN Connector 에러(SVN: '0x0400006': Validate Repository Location) (0) | 2022.10.05 |
[스프링] Maven build error (0) | 2022.01.25 |
[JAVA] JRE System Library 우선 순위 문제 (0) | 2022.01.25 |
[spring] STS에서 자바 버전 문제 (0) | 2022.01.25 |