Section 5.1.1, 'Importing XML DSL configuration' in the below doc,
http://wildfly-extras.github.io/wildfly-camel/#_cdi
states the below,
It’s important to note that the location of the imported file must be present on the deployment classpath. Placing the file into locations such as WEB-INF will not work. However, WEB-INF/classes will work fine.
If we package the supplied quickstart, 'camel-cxf-jaxws-cdi-xml' as an EAR, the deployment of the application fails with the below message:
2018-04-16 08:35:49.807 | | ERROR [org.jboss.msc.service.fail] (MSC service thread 1-1) MSC000001: Failed to start service jboss.deployment.unit."RH-example-camel-cxf-jaxws-cdi-xml-redhat.ear".WeldStartService: org.jboss.msc.service.StartException in service jboss.deployment.unit."RH-example-camel-cxf-jaxws-cdi-xml-redhat.ear".WeldStartService: Failed to start service at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1978) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) Caused by: org.jboss.weld.exceptions.DeploymentException: WELD-001408: Unsatisfied dependencies for type CamelContext with qualifiers @ContextName at injection point [BackedAnnotatedField] @Inject @ContextName org.wildfly.camel.examples.cxf.jaxws.Application.context at org.wildfly.camel.examples.cxf.jaxws.Application.context(Application.java:0) WELD-001475: The following beans match by type, but none have matching qualifiers: - Default Camel context bean with qualifiers [@javax.enterprise.inject.Any(), @javax.enterprise.inject.Default()] at org.jboss.weld.bootstrap.Validator.validateInjectionPointForDeploymentProblems(Validator.java:362) at org.jboss.weld.bootstrap.Validator.validateInjectionPoint(Validator.java:284) at org.jboss.weld.bootstrap.Validator.validateGeneralBean(Validator.java:137) at org.jboss.weld.bootstrap.Validator.validateRIBean(Validator.java:158) at org.jboss.weld.bootstrap.Validator.validateBean(Validator.java:501) at org.jboss.weld.bootstrap.ConcurrentValidator$1.doWork(ConcurrentValidator.java:61) at org.jboss.weld.bootstrap.ConcurrentValidator$1.doWork(ConcurrentValidator.java:59) at org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:62) at org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:55) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) at org.jboss.threads.JBossThread.run(JBossThread.java:320)