报错信息: 


Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2019-09-17 13:29:41.132 ERROR 8108 --- [           main] o.s.b.d.LoggingFailureAnalysisReporter   : 

***************************
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).


Process finished with exit code 1

解决:我在导入依赖的时候添加了mysql和mybatis的依赖  但是在application.yml没有配置,所有只需要将数据库相关配置加上或者注释掉相关依赖即可。

Logo

为开发者提供学习成长、分享交流、生态实践、资源工具等服务,帮助开发者快速成长。

更多推荐