Could not autowire. There is more than one bean of 'DataSource' type

前端 未结 3 1746
失恋的感觉
失恋的感觉 2021-02-01 18:06

I\'m trying to Autowire a database by

@Autowired
private DataSource dataSource;

I have one datasource in my application.yml

3条回答
  •  挽巷
    挽巷 (楼主)
    2021-02-01 18:19

    Please note that Spring Boot autoconfigured beans are not supported 100% yet, see https://youtrack.jetbrains.com/issue/IDEA-139669 for progress and possible workaorunds.

提交回复
热议问题