Closed
Description
Juergen Hoeller opened SPR-12250 and commented
The current BeanFactory.getBean
algorithm is optimized towards singleton access, always checking the singleton map for a quick check before proceeding with scope handling.
Lock-free access to non-singleton beans is equally important and seems to be easy enough to achieve: through a check on registered singleton names before going into the lock on the singleton map.
Affects: 3.2.11, 4.0.7, 4.1 GA
Issue Links:
- AbstractBeanFactory#markBeanAsCreated performance issue due to lock contention [SPR-9780] #14414 AbstractBeanFactory#markBeanAsCreated performance issue due to lock contention
- Non-singleton beans performance issue [SPR-9819] #14452 Non-singleton beans performance issue