대충해도 돌아는 가지만 대충 하면 망하는 프로젝트 셋팅 일기
에러 1
Caused by: org.hibernate.service.spi.ServiceException: Unable to create requested service [org.hibernate.engine.jdbc.env.spi.JdbcEnvironment] due to: Unable to determine Dialect without JDBC metadata (please set 'jakarta.persistence.jdbc.url' for common cases or 'hibernate.dialect' when a custom Dialect implementation must be provided)
database-platform: org.hibernate.dialect.MySQLDialect 추가
spring:
application:
name: demo
jpa:
database-platform: org.hibernate.dialect.MySQLDialect
hibernate:
ddl-auto: create
show-sql: true
properties:
hibernate:
format_sql: true
에러 2
Process 'command '/Users/noel/Library/Java/JavaVirtualMachines/openjdk-22.0.1/Contents/Home/bin/java'' finished with non-zero exit value 1`
Build -> Build Tools -> Gradle 확인
Build and run using : IntelliJ IDEA
Run tests using : IntelliJ IDEA
에러3
Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.
jdbc-url 을 url: jdbc:mysql~~로 수정
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
jdbc-url: mysql://localhost:3306/test?serverTimezone=UTC&characterEncoding=UTF-8
username: root
password: 123456
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://localhost:3306/test?serverTimezone=UTC&characterEncoding=UTF-8
username: root
password: 123456
에러4
Cannot resolve symbol 'CSVFormat'
Cannot resolve symbol 'CSVParser'
implementation 'org.apache.commons:commons-csv:1.8'