seong
Vs에서 Spring JPA 셋팅하기 본문
1. STS의 propertis > yml로 변경
yml은 propertis보다 경량화가 되어 있고, 실제 만들었을때 가독성이 좋다.
2. yml 설정
server:
port: 8000
servlet:
context-path: /
spring:
datasource:
url: jdbc:h2:mem:test
driver-class-name: org.h2.Driver
username: sa
password:
h2:
console:
enabled: true
jpa:
hibernate:
ddl-auto: create
output:
ansi:
enabled: always
logging:
level:
root: DEBUG
'JPA' 카테고리의 다른 글
Spring의 OSIV 정책 (0) | 2022.10.24 |
---|---|
JPA의 Repository (0) | 2022.10.24 |
JPA 마리아 DB에서 오토 시퀀스 작성 - GenerationType.IDENTITY (0) | 2022.10.21 |
JPA 자바코드로 테이블생성하기 (0) | 2022.10.21 |
VS에서 DB H2 -> MariaDB로 변경 (0) | 2022.10.21 |