数据库地址:127.0.0.1端口:3306 账户:root 密码:root 配置没问题,但idea启动报错Could not create connection to database server。原因是少个参数,设置下时区
serverTimezone=UTC
完成链接:
spring:
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://127.0.0.1:3306/test/useUnicode=true&characterEncoding=UTF-8&serverTimezone=UTC
username: root
password: root