Springboot配置druid报错Failed to bind properties under 'spring.datasource' to javax.sql.DataSource

springboot在使用druid时,引入了druid的数据源,在配置文件application.yml中配置了相关配置后,还配置了druid的过滤器,如果过滤器中有log4j,一定要在pom文件中加入log4j的依赖

filters: stat,wall,log4j

  还需要配置log4j

<dependency>
	<groupId>log4j</groupId>
	<artifactId>log4j</artifactId>
	<version>1.2.17</version>
</dependency>

  

posted @ 2020-02-15 21:26  Samuel-Leung  阅读(380)  评论(0编辑  收藏  举报