From b7c9fe646df3045bfb9c960726ade6e9a26bcc7d Mon Sep 17 00:00:00 2001 From: hou27 Date: Thu, 23 Jun 2022 22:38:09 +0900 Subject: [PATCH] Apply log4jdbc --- README.md | 4 ++-- src/main/resources/application.yml | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 4e2af9a..3b29fee 100644 --- a/README.md +++ b/README.md @@ -31,8 +31,8 @@ public AuthenticationManager authenticationManager(AuthenticationConfiguration a # Profile Set ```application.yml``` to use ```.dev.env``` file -``` +```yaml spring: config: import: optional:file:.dev.env[.properties] -``` +``` \ No newline at end of file diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index 5ecc497..a4d1878 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -5,8 +5,10 @@ spring: import: optional:file:.dev.env[.properties] # Database datasource: - driver-class-name: org.postgresql.Driver - url: jdbc:postgresql://localhost:5432/${DB_NAME} +# driver-class-name: org.postgresql.Driver + driver-class-name: net.sf.log4jdbc.sql.jdbcapi.DriverSpy # log4jdbc 사용을 위한 driver +# url: jdbc:postgresql://localhost:5432/${DB_NAME} + url: jdbc:log4jdbc:postgresql://localhost:5432/${DB_NAME} # log4jdbc 사용을 위한 'log4jdbc:' 추가 username: postgres password: ${DB_PW} # jpa properties