Andriy Rosa opened SPR-9819 and commented
For each method invocation for not-singleton scope bean
Interceptor got bean from bean-factory by using AbstractBeanFactory.getBean
But before getting required bean inside method getBean we have cheeking
Object sharedInstance = getSingleton(beanName);
if (sharedInstance != null && args == null) {
Inside getSingleton we have synchronized blocks.
considering that in high-load project we can have a lot of scoped-beans methods invocations, getSingleton lock all threads, and performance gone to very poor.
I'm not very good in spring-core architecture, however by my mean the most obvious solution - it push into args argument of getBean method specific arg, which will show, that we request not singleton bean for sure
P.S.: Take my apologies for my bad English.
Affects: 3.1.1
Issue Links:
0 votes, 5 watchers
Andriy Rosa opened SPR-9819 and commented
For each method invocation for not-singleton scope bean
Interceptor got bean from bean-factory by using AbstractBeanFactory.getBean
But before getting required bean inside method getBean we have cheeking
Object sharedInstance = getSingleton(beanName);
if (sharedInstance != null && args == null) {
Inside getSingleton we have synchronized blocks.
considering that in high-load project we can have a lot of scoped-beans methods invocations, getSingleton lock all threads, and performance gone to very poor.
I'm not very good in spring-core architecture, however by my mean the most obvious solution - it push into args argument of getBean method specific arg, which will show, that we request not singleton bean for sure
P.S.: Take my apologies for my bad English.
Affects: 3.1.1
Issue Links:
@SpringBeanannotation for injection ("is duplicated by")0 votes, 5 watchers