Skip to content
This repository has been archived by the owner on Aug 13, 2022. It is now read-only.

Commit

Permalink
[#1] application.yml 분리
Browse files Browse the repository at this point in the history
  • Loading branch information
Hosick committed Jan 13, 2021
1 parent 46d6308 commit 954407f
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 37 deletions.
9 changes: 9 additions & 0 deletions src/main/resources/application-default.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# 애플리케이션 실행시 local profile을 사용한다. (미적용시 default)
# org.hibernate.SQL : 로거를 이용한 쿼리문 출력
# org.hibernate.type.descriptor.sql : ?로 표시된 쿼리 파라미터 값을 로그로 출력
spring:
profiles:
active: local
logging.level:
org.hibernate.SQL: debug
org.hibernate.type: trace
10 changes: 10 additions & 0 deletions src/main/resources/application-dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# ddl-auto (validate) : 엔티티와 테이블이 정상적으로 매핑되었는지만 확인한다. (테스트단계와 스테이징 서버에서 사용)
spring:
profiles: dev

jpa:
hibernate:
ddl-auto: validate
properties:
hibernate:
format_sql: true
16 changes: 16 additions & 0 deletions src/main/resources/application-local.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# ddl-auto (create) : 개발 초기 환경에서 사용. 애플리케이션 로딩 시점에 모든 테이블을 drop 후 새로 생성, 애플리케이션 서버 종료 후에도 DB 보존 (개발 초기단계에 사용)
# format_sql : query의 출력 내용을 서식에 맞게 가독성을 향상시켜 출력
spring:
profiles: local
datasource:
url: jdbc:h2:tcp://localhost/~/shoeactions
username: sa
password:
driver-class-name: org.h2.Driver

jpa:
hibernate:
ddl-auto: create
properties:
hibernate:
format_sql: true
37 changes: 0 additions & 37 deletions src/main/resources/application.yml

This file was deleted.

0 comments on commit 954407f

Please sign in to comment.