You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Retain merged bean definition caches when possible
Update the logic in `AbstractBeanFactory` so that caches from merged
bean definitions remain whenever possible.
Prior to this commit, all merged bean definitions would be completely
removed after bean post processing in case a processor changed the bean
type. It's fairly unlikely these days that the bean type will actually
change, so instead we now compare a subset of the old cached properties
against the newly created definition. Only if key properties have
changed do we now discard the older cached values.
Closesgh-23336
Copy file name to clipboardExpand all lines: spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.java
+4-3
Original file line number
Diff line number
Diff line change
@@ -114,6 +114,7 @@
114
114
* @author Costin Leau
115
115
* @author Chris Beams
116
116
* @author Sam Brannen
117
+
* @author Phillip Webb
117
118
* @since 13.02.2004
118
119
* @see RootBeanDefinition
119
120
* @see DefaultListableBeanFactory
@@ -646,16 +647,16 @@ else if (!this.allowRawInjectionDespiteWrapping && hasDependentBean(beanName)) {
0 commit comments