Optional Spring bean references

后端 未结 5 2139
逝去的感伤
逝去的感伤 2020-12-03 17:22

In my application I am using ContextLoaderListener to load context files from many jars using:


    contextConfigLocat         


        
5条回答
  •  刺人心
    刺人心 (楼主)
    2020-12-03 17:40

    My best guess is to use autowire-ing with required false. Don't know how you can express this in XML but using annotation configuration this would look like:

    @Autowired(required=false)
    

提交回复
热议问题