Jboss 6 抛出“javax.servlet.ServletException:无法获取 /UPCServiceLayer/upcLineOfBusinessService 的目的地”

发布于 2024-12-28 23:45:34 字数 1872 浏览 0 评论 0原文

我正在使用 Jboss6 来部署使用 CXF 开发的 Web 服务。

由于 Jboss6 已经与 CXF 捆绑在一起,我没有在应用程序中使用任何 cxf jar 文件。

当我在部署后尝试访问我的 wsdl 文件时,出现以下异常

javax.servlet.ServletException: Cannot obtain destination for: /UPCServiceLayer/upcLineOfBusinessService
    org.jboss.wsf.stack.cxf.ServletControllerExt.findDestination(ServletControllerExt.java:111)
    org.jboss.wsf.stack.cxf.ServletControllerExt.invoke(ServletControllerExt.java:165)

以下是我的 jbossws-cxf.xml

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jaxws="http://cxf.apache.org/jaxws"
    xmlns:aop="http://www.springframework.org/schema/aop" 
    xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/bindings/soap http://cxf.apache.org/schemas/configuration/soap.xsd
http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
    <import resource="classpath:META-INF/cxf/cxf.xml" />
    <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
    <import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
    <import resource="classpath:../upc-spring-dao.xml"/>
    <jaxws:endpoint id="UpcLineOfBusinessServiceImpl"
        address="/upcLineOfBusinessService">
        <jaxws:implementor>
            <ref bean="upcLineOfBusinessService"></ref>
        </jaxws:implementor>
        <jaxws:invoker>
            <bean class="org.jboss.wsf.stack.cxf.InvokerJSE" />
        </jaxws:invoker>
    </jaxws:endpoint>

</beans>

请帮助我

I am using Jboss6 to deploy my webservices developed using CXF.

Since Jboss6 already bundled with CXF i am not using any cxf jar files inside my application.

When i try to access my wsdl file after deployment i am getting the following exception

javax.servlet.ServletException: Cannot obtain destination for: /UPCServiceLayer/upcLineOfBusinessService
    org.jboss.wsf.stack.cxf.ServletControllerExt.findDestination(ServletControllerExt.java:111)
    org.jboss.wsf.stack.cxf.ServletControllerExt.invoke(ServletControllerExt.java:165)

The following is my jbossws-cxf.xml

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jaxws="http://cxf.apache.org/jaxws"
    xmlns:aop="http://www.springframework.org/schema/aop" 
    xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/bindings/soap http://cxf.apache.org/schemas/configuration/soap.xsd
http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd">
    <import resource="classpath:META-INF/cxf/cxf.xml" />
    <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
    <import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
    <import resource="classpath:../upc-spring-dao.xml"/>
    <jaxws:endpoint id="UpcLineOfBusinessServiceImpl"
        address="/upcLineOfBusinessService">
        <jaxws:implementor>
            <ref bean="upcLineOfBusinessService"></ref>
        </jaxws:implementor>
        <jaxws:invoker>
            <bean class="org.jboss.wsf.stack.cxf.InvokerJSE" />
        </jaxws:invoker>
    </jaxws:endpoint>

</beans>

Please help me

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

失而复得 2025-01-04 23:45:34

您是否尝试过将 address="/upcLineOfBusinessService" 替换为 address="/UPCServiceLayer/upcLineOfBusinessService

Have you tried replacing address="/upcLineOfBusinessService" with address="/UPCServiceLayer/upcLineOfBusinessService?

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文