I am currently working on a project using the fuse service works (switchyard, ....). I have created a Spring XML configuration file (src/main/resources/META-INF/beansCDI.xml) which contains the CDI beans (beans, camelContext, ...) that i want to inject. The issue that I cannot retrieve the beans defined in beansCDI.xml to inject them in my camel route (route.xml). Also, I have tried to use ApplicationContext to load beansCDI.xml but without success. Note that using annotations (@Produces @Named) to inject beans works perfectly. But, in my case i want to use the spring DSL.
Here my beansCDI.xml [example taken from the "Camel in Action" book]:
<bean id="jms" class="org.apache.camel.component.jms.JmsComponent">
<property name="brokerURL" value="vm://localhost" />
<bean id="ftpToJmsRoute" class="camelinaction.FtpToJMSRoute" />
<routeBuilder ref="ftpToJmsRoute" />
Any suggestions would be grateful.