Bean circular reference problem modification

consider using 'getBeanNamesOfType' with the 'allowEagerInit'

 

Bean with name 'erpService' has been injected into other beans [incrementServiceImpl,companySaveService,] 

 

This issue has been frustrating for a long time.

Solution. Look at the class that has been changed recently. Solve from the new bean injection.

Comment out the injected classes one by one.

Find the problematic class. Then look at that place.

Because contractService is injected into erpService, then contractManager is injected into it.  

There  are ERPBase erpBaseImpl ; injections in several layers.

cause a circular reference.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326583910&siteId=291194637