APPLICATION FAILED TO START
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).
我的项目启动失败,导致起因大抵有几种
1、配置文件对于数据库的配置信息有误
2、配置文件没有读取到
3、在启动类下面增加注解
然而网上的计划都有效,依据自查是删除了 POM 文件中的依赖导致
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-config</artifactId>
<version>2.0.0.RELEASE</version>
</dependency>
将此依赖增加回到我的项目即可解决问题