Failed to configure a DataSource: url attribute is not specified and no embedd
Failed to configure a DataSource:'url' attribute is not specified and no embeddeddatasource
无法配置DataSource:未指定’url’属性,也无法配置嵌入数据源
可能是.properties文件中datasource的配置出现错误,例如:地址值,数据库驱动,用户名,密码。
后面发现不是这个这个原因。
经过再三检查,发现是打包误写成了pom.
在springcloud项目这个打包方式是默认jar或者war包的。
误写成pom,将导致编译后,target文件下只有classes,而导致读取不了,以至于编译后没有其他目标文件夹。
因此把这个打包方式删掉或者改成jar包方式即可。