【SpringBoot】There is more than one bean of ‘TaskExecutor‘ type

i奇异

关注

阅读 104

2022-07-28


一、问题描述

Could not autowire. There is more than one bean of 'TaskExecutor' type.
Beans:
applicationTaskExecutor (TaskExecutionAutoConfiguration.class) taskExecutor (ApplicationConfig.java)

二、问题解决

@Qualifier("taskExecutor")
@Autowired
private TaskExecutor taskExecutor;

 

精彩评论(0)

0 0 举报