Wildfly 8.2无法加载jbossws-cxf-client模块

时间:2015-03-05 14:17:45

标签: jboss cxf wildfly

我正在开发一个包含Soap客户端并且需要访问cxf客户端实施的Web应用程序,因为我们必须对远程端点的不同调用使用不同的证书。

Wildfly附带了一个模块jbossws-cxf-client,该模块依赖于所需的所有不同cxf模块。这个模块也有maven版本。

在maven模块pom文件中,我们有一个依赖项,如下所示:

<dependency>
    <groupId>org.jboss.ws.cxf</groupId>
    <artifactId>jbossws-cxf-client</artifactId>
    <version>4.3.2.Final</version>
    <scope>provided</scope>
</dependency>

请注意,该版本已与wildfly 8.2发行说明中提及的版本匹配:http://wildfly.org/news/2014/11/20/WildFly82-Final-Released/

部署我们的应用程序时,我们会从日志中收到以下消息:

14:22:12,492 INFO  [org.jboss.weld.Bootstrap] (weld-worker-1) WELD-000119: Not generating any bean definitions from nl.topicuszorg.lsp.service.MultipleCertificatePingStubServiceImpl because of underlying class loading error: Type org.apache.cxf.transport.Conduit from [Module "deployment.kdplus-lsphub-server-1.1-SNAPSHOT.war:main" from Service Module Loader] not found.  If this is unexpected, enable DEBUG logging to see the full error.
14:22:12,689 INFO  [org.apache.deltaspike.core.util.ProjectStageProducer] (MSC service thread 1-2) Computed the following DeltaSpike ProjectStage: Production
14:22:13,628 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC000001: Failed to start service jboss.deployment.unit."kdplus-lsphub-server-1.1-SNAPSHOT.war".WeldStartService: org.jboss.msc.service.StartException in service jboss.deployment.unit."kdplus-lsphub-server-1.1-SNAPSHOT.war".WeldStartService: Failed to start service
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1904) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_25]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_25]
    at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_25]
Caused by: org.jboss.weld.exceptions.DeploymentException: WELD-001408: Unsatisfied dependencies for type PingStubService with qualifiers @Default
  at injection point [BackedAnnotatedField] @Inject nl.topicuszorg.lsp.service.PingPongServiceImpl.pingStubService
  at nl.topicuszorg.lsp.service.PingPongServiceImpl.pingStubService(PingPongServiceImpl.java:0)

真正的问题记录为INFO,奇怪的是。无法加载org.apache.cxf.transport.Conduit。这是org.apache.cxf模块的一部分,应该通过加载jbossws-cxf-client模块来传递加载。

它应该没有必要,但我们也在jboss-deployment-structure.xml中隐含地声明模块依赖

<?xml version="1.0" encoding="UTF-8"?>
<jboss-deployment-structure>
    <deployment>
        <excludes>
        </excludes>
        <dependencies>
            <module name="org.slf4j"/>
            <module name="org.apache.cxf"/>
            <module name="jbossws-cxf-client"/>
            <module name="org.apache.cxf.impl"/>
        </dependencies>
    </deployment>
</jboss-deployment-structure>

模块似乎没有加载,我不知道为什么。我找不到检查哪些模块已加载的方法。

这里出了什么问题?

1 个答案:

答案 0 :(得分:1)

事实证明,我必须将我的jboss-deployment-structure.xml从META-INF移动到WEB-INF目录。 长号...