geronimo-xbean-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dain Sundstrom (JIRA)" <j...@apache.org>
Subject [jira] Closed: (XBEAN-97) default-lazy-init is ignored
Date Thu, 28 Feb 2008 21:25:56 GMT

     [ https://issues.apache.org/jira/browse/XBEAN-97?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Dain Sundstrom closed XBEAN-97.
-------------------------------

    Resolution: Fixed

I believe this has been fixed.  If not please reopen with a test case that reproduces the
problem.



> default-lazy-init is ignored
> ----------------------------
>
>                 Key: XBEAN-97
>                 URL: https://issues.apache.org/jira/browse/XBEAN-97
>             Project: XBean
>          Issue Type: Bug
>          Components: spring
>            Reporter: alex322
>
> lazyInit is always false.
> Adding this snippet to org.apache.xbean.spring.context.v2c.XBeanNamespaceHandler.parseBeanFromExtensionElement
should solve the problem :
> 			BeanDefinition def = result.getBeanDefinition();
> 			if (def instanceof AbstractBeanDefinition) {
> 				AbstractBeanDefinition adef = (AbstractBeanDefinition) def;
> 				if (!element.hasAttribute(BeanDefinitionParserDelegate.LAZY_INIT_ATTRIBUTE)) {
> 					adef.setLazyInit(parserContext.isDefaultLazyInit());	
> 				}				
> 			}
> Also checking for top-level bean definition can be simplified:
> if (!parserContext.isNested())

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message