No qualifying bean of type 'javax.sql.DataSource' available: expected at least 1

hky87發表於2018-08-18

No qualifying bean of type 'javax.sql.DataSource' available: expected at least 1 bean which qualifies as autowire candidate.



原因使用了預設的DataSource,但在Application中新增了 (exclude= {DataSourceAutoConfiguration. class }),去掉即可


來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/10314474/viewspace-2200345/,如需轉載,請註明出處,否則將追究法律責任。

相關文章