org.osgi.service.blueprint.container.ComponentDefinitionException: Unable to find a matching factory method createBean on class com.mycompany.BeanFactory
Issue
Trying to create a transaction decorated bean using a Factory class in blueprint results in
org.osgi.service.blueprint.container.ComponentDefinitionException: Unable to find a matching factory method
createBean on class com.mycompany.BeanFactory for arguments
[org.apache.aries.blueprint.container.BeanRecipe$UnwrapperedBeanHolder@2ae73efd] when instanciating bean extBean
The blueprint definition would be similar to
<bean id="factoryBean" class="com.mycompany.BeanFactory"/>
<bean id="simpleBean" class="com.mycompany.SimpleBean">
<tx:transaction method="*" value="Required" />
</bean>
<bean id="extBean" factory-ref="factoryBean" factory-method="createBean">
<argument ref="simpleBean"/>
</bean>
Environment
- Fuse ESB Enterprise 7.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
