Class PentahoBeanScopeValidatorPostProcessor
- java.lang.Object
-
- org.pentaho.platform.engine.core.system.objfac.spring.PentahoBeanScopeValidatorPostProcessor
-
- All Implemented Interfaces:
org.springframework.beans.factory.config.BeanFactoryPostProcessor
public class PentahoBeanScopeValidatorPostProcessor extends Object implements org.springframework.beans.factory.config.BeanFactoryPostProcessor
To maintain legacy compatibility, upon BeanFactory init we'll traverse through all beans in its containing factoryMap and for each that holds an empty scope definition we'll set it with a BeanDefinition.SCOPE_SINGLETON Contextualization: in previous spring framework 2.5.6 any non-explicit bean scope declaration would be set with default a value of BeanDefinition.SCOPE_SINGLETON; in latest spring framework 3.2.14 the scope is set with an empty string; the scope checking should now be done using the isSingleton() predicate, whose value is set to 'true' when scope is either set as 'singleton' or empty string
-
-
Constructor Summary
Constructors Constructor Description PentahoBeanScopeValidatorPostProcessor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory)
protected void
validateBeanScope(String beanName, org.springframework.beans.factory.config.BeanDefinition bd)
-
-
-
Method Detail
-
postProcessBeanFactory
public void postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory) throws org.springframework.beans.BeansException
- Specified by:
postProcessBeanFactory
in interfaceorg.springframework.beans.factory.config.BeanFactoryPostProcessor
- Throws:
org.springframework.beans.BeansException
-
validateBeanScope
protected void validateBeanScope(String beanName, org.springframework.beans.factory.config.BeanDefinition bd)
-
-