title: CXF 2.7.0 web service deployment in Wildfly 10
body: <p>Goal - Migrating EAR application from JBoss EAP 5 to Wildfly 10</p>
  
  <p>Issue : Code has CXF 2.7.0 web service client code (to call third party web service) and its added to the EAR/lib folder. But during deployment, I am getting below exception</p>
  
  <h1>log:</h1>
  
  <pre><code>2016-02-26 12:17:48,075 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC000001: Failed to start service jboss.deployment.unit."rts-comcast-01.01.75.ear".WeldStartService: org.jboss.msc.service.StartException in service jboss.deployment.unit."rts-comcast-01.01.75.ear".WeldStartService: Failed to start service
  at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1904)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
  at java.lang.Thread.run(Thread.java:745) Caused by: org.jboss.weld.exceptions.DefinitionException: WELD-000071: Managed bean with a parameterized bean class must be @Dependent: class org.apache.cxf.jaxrs.provider.DataBindingProvider
  at org.jboss.weld.bean.ManagedBean.checkType(ManagedBean.java:208)
  at org.jboss.weld.bean.AbstractBean.initializeAfterBeanDiscovery(AbstractBean.java:107)
  at org.jboss.weld.bean.ManagedBean.initializeAfterBeanDiscovery(ManagedBean.java:122)
  at org.jboss.weld.bootstrap.ConcurrentBeanDeployer$AfterBeanDiscoveryInitializerFactory.doWork(ConcurrentBeanDeployer.java:136)
  at org.jboss.weld.bootstrap.ConcurrentBeanDeployer$AfterBeanDiscoveryInitializerFactory.doWork(ConcurrentBeanDeployer.java:127)
  at org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:63)
  at org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:56)
  at java.util.concurrent.FutureTask.run(FutureTask.java:266)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
  at java.lang.Thread.run(Thread.java:745)
  at org.jboss.threads.JBossThread.run(JBossThread.java:320)
  </code></pre>
  
  <h1>beans-xml</h1>
  
  <p>I have added below beans-xml to the META-INF and WEB-INF as well</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;beans xmlns="http://xmlns.jcp.org/xml/ns/javaee"  
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"  
    xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/beans_1_1.xsd"  
    bean-discovery-mode="annotated"&gt;  
  </code></pre>
  
  <p> </p>
  
  <h1>Alternate try</h1>
  
  <p>I was in a doubt whether the given libs are getting loaded to the application and want confirm my dependencies are good. so made a sample web application and loaded all the CXF jar files this time to WEB-INF/lib folder itself and deployed this time also the same issue as mentioned above</p>
  
  <h1>CXF version in Wildfly 10</h1>
  
  <p>Wildfly 10 comes with CXF 3.1.4, but i have given my needed jars in my lib folder and did not mention any container provided CXF modules, to ensure CXF version in libs to load.</p>
  
  <p>Could some provide an insight where I am doing wrong? Thanks for your help</p>
  
  <p>After searching for a while i added the below config changes in jboss-deployment-strucutre.xml and still having issues. Please use this link for detailed information
  <a href="https://developer.jboss.org/thread/268163" rel="nofollow">https://developer.jboss.org/thread/268163</a></p>