반응형

[Spring Boot 실습 #15] MySQL 5.7 설정 - HikariCP 설정 (application.properties)

 

1. Spring Boot MySQL 5.7 + HikariCP (application.properties)

2. 개발환경

    2.1. 개발환경

3. 실행

    3.1. 설정 파일

4. 결과

    4.1. 결과화면

 

 

1. Spring Boot MySQL 5.7 + HikariCP 설정 (application.properties)

 

 

2. 개발환경

 

2.1. 개발환경

MacOS M1 - macOS Monterey 12.0.1

IntelliJ IDEA 2021.2 (Community Edition)

 

 

3. 실행

3.1. 설정 파일

[ application.properties ]

1
2
3
4
5
6
7
8
9
10
11
12
###### Database Properties - Hikari + MySQL ###########################################
spring.datasource.hikari.driver-class-name=com.mysql.cj.jdbc.Driver
spring.datasource.hikari.jdbc-url=jdbc:mysql://{host}:{port}/{database}?useUnicode=true&characterEncoding=utf8&allowPublicKeyRetrieval=true&useSSL=false&serverTimezone=Asia/Seoul&useLegacyDatetimeCode=false
spring.datasource.hikari.username={username}
spring.datasource.hikari.password={password}
 
# MYSQL 5.7
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
spring.jpa.database.platform=mysql
spring.jpa.properties.hibernate.id.new_generator_mappings=false
spring.jpa.hibernate.ddl-auto=update
 

 

 

4. 결과

4.1. 결과화면

 

 

반응형