遇到问题
Description:
Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.
Reason: Failed to determine a suitable driver class
Action:
Consider the following:
If you want an embedded database (H2, HSQL or Derby), please put it on the classpath.
If you have database settings to be loaded from a particular profile you may need to activate it (no profiles are currently active).
已解决,
解决方法:启动类@SpringBootApplication(exclude= {DruidDataSourceAutoConfigure.class}),注意是DruidDataSourceAutoConfigure,不是DataSourceAutoConfiguration.class
看错误信息应该是你的properties配置文件中没有配置数据源吧
spring.datasource.dynamic.datasource.master.url
看你都发了无数次了,做一次好人吧,拿去自己改一下数据源的配置就行了
链接: https://pan.baidu.com/s/1WeyLNisRLlbKVUwlXB4fSQ 提取码: rqq2 复制这段内容后打开百度网盘手机App,操作更方便哦