为了账号安全,请及时绑定邮箱和手机立即绑定

使用intellij idea搭建SPringboot 依赖了 mybatis 的 就报错

/ 猿问

使用intellij idea搭建SPringboot 依赖了 mybatis 的 就报错

慕粉2228388982 2018-07-24 19:11:09

https://img3.mukewang.com/5b57093b0001ee6e13660768.jpg java.lang.Object.wait(Native Method)

 java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:143)

 com.mysql.jdbc.AbandonedConnectionCleanupThread.run(AbandonedConnectionCleanupThread.java:43)

2018-07-24 18:55:36.251  INFO 2944 --- [           main] ConditionEvaluationReportLoggingListener : 


Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.

2018-07-24 18:55:36.259 ERROR 2944 --- [           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


查看完整描述

2 回答

?
柯旦v

可能是没有导入Driver相关数据库驱动包

查看完整回答
反对 回复 2018-08-28
?
流年4水0

确保yml里书写格式正确。
然后Target先删掉,maven clear,package。ide重启。第一次不好使第二次直到好使即可。

查看完整回答
反对 回复 2018-08-28

添加回答

回复

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信