启动SpringBoot 应用时,报异常:
Description:
Cannot determine embedded database driver class for database type NONE
如图所示:
解决办法:
在项目application.properties文件中,添加数据源相关配置:
spring.datasource.url=jdbc:mysql://localhost:3306/test
spring.datasource.username=root
spring.datasource.password=ROOT
spring.datasource.driver-class-name=com.mysql.jdbc.Driver
spring.datasource.max-idle=10
spring.datasource.max-wait=10000
spring.datasource.min-idle=5
spring.datasource.initial-size=5