摘要:
一、原因分析:在多线程时使用@Autowired总是获取不到bean,原因是:new thread不在spring容器中,也就无法获得spring中的bean对象 二、解决方案:手动获取 代码实现如下: package com.test.configs; import org.springframe 阅读全文
posted @ 2020-05-11 09:12
a-du
阅读(3107)
评论(0)
推荐(2)
![]() |
资深软件工程师。关注.net、C#、MVC、Java、Spring、Spring boot、Spring cloud、Lucene、ElasticSearch、elk、spark&&ALS。 个人网站 www.a-du.net |