bugfix:获取XxlJob注解方法时,非单例bean引发的报错

pull/16/head
lizhen 5 years ago
parent 670d1ca544
commit cd68af99af

@ -81,7 +81,7 @@ public class XxlJobSpringExecutor extends XxlJobExecutor implements ApplicationC
return;
}
// init job handler from method
String[] beanDefinitionNames = applicationContext.getBeanDefinitionNames();
String[] beanDefinitionNames = applicationContext.getBeanNamesForType(Object.class, false, true);
for (String beanDefinitionName : beanDefinitionNames) {
Object bean = applicationContext.getBean(beanDefinitionName);

Loading…
Cancel
Save