我拆过的坑cycx

查询一下!

cxf调用报错Could not find conduit initiator for address:

org.apache.cxfcxf-rt-transports-http-jetty3.0.1

依赖


<dependency>


    <groupId>org.apache.cxf</groupId>

    <artifactId>cxf-rt-frontend-jaxws</artifactId>

    <version>3.2.2</version>

</dependency>

测试代码    


@Test


    public void test1() {

        JaxWsProxyFactoryBean jaxWs = new JaxWsProxyFactoryBean();

        jaxWs.setAddress("http://192.168.8.254:11090/artesia-ux-ws/services/ArtesiaLoginService");

        jaxWs.setServiceClass(ArtesiaLoginService.class);

        ArtesiaLoginService als = (ArtesiaLoginService) jaxWs.create();

        LoginSession login = als.login("tsuper", "Passw0rd!");

        System.out.println(login.getId().getIdString());

    }


报错:


Exception in thread "main" javax.xml.ws.soap.SOAPFaultException: Could not find conduit initiator for address:


报错解决方案:


添加依赖:


<dependency>

    <groupId>org.apache.cxf</groupId>

    <artifactId>cxf-rt-transports-http</artifactId>

    <version>3.2.2</version>

</dependency>



 

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

Powered By Z-BlogPHP 1.7.3

Copyright Your WebSite.Some Rights Reserved.