cxf集成spring在websphere发布无法创建服务端

心境111 发布于 2015/11/27 16:39
阅读 907
收藏 0

最近用cxf集成Spring发布webservice,在tomcat下面是没有问题的,但是到was上各种问题,终于使用共享库的方式解决各种类冲突之后,却在创建service的时候报了一个异常,

spring的配置文件如下:

<?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"  
    xsi:schemaLocation="  
        http://www.springframework.org/schema/beans  
        http://www.springframework.org/schema/beans/spring-beans.xsd  
        http://cxf.apache.org/jaxws  
        http://cxf.apache.org/schemas/jaxws.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" />  
      
    <jaxws:endpoint id="dataextractionService"  
        implementor="com.isoftstone.trust.credit.dataextraction.impl.IDataExtractionImpl" address="/dataextractionService" />  
        </beans>
在tomcat下面试没有一点问题的。

在was8.0启动后就报:

Creating Service {http://impl.dataextraction.credit.trust.isoftstone.com/}IDataExtractionImplService from class com.isoftstone.trust.credit.dataextraction.IDataExtraction


[15-11-27 16:33:37:562 CST] 00001202 OldSpringSupp W   Import of META-INF/cxf/cxf-extension-soap.xml has been deprecated and is unnecessary.


[15-11-27 16:33:37:946 CST] 00001202 ServerImpl    I   Setting the server's publish address to be /dataextractionService


[15-11-27 16:33:38:417 CST] 00001202 ReflectionSer W   Failed to parse WSDL
                                 javax.wsdl.WSDLException: WSDLException (at /wsdl:definitions/wsdl:types/xs:schema/xs:schema): faultCode=PARSER_ERROR: Problem parsing 'http://www.w3.org/2006/03/addressing/ws-addr.xsd'.: java.net.UnknownHostException: www.w3.org
        at com.ibm.wsdl.xml.WSDLReaderImpl.getDocument(WSDLReaderImpl.java:2198)
        at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:830)
        at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:864)
        at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:654)
        at com.ibm.wsdl.xml.WSDLReaderImpl.parseTypes(WSDLReaderImpl.java:610)
        at com.ibm.wsdl.xml.WSDLReaderImpl.parseDefinitions(WSDLReaderImpl.java:320)
        at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(WSDLReaderImpl.java:2352)
        at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(WSDLReaderImpl.java:2338)
        at org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:261)
        at org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:206)
        at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.isEmptywsdl(ReflectionServiceFactoryBean.java:2607)
        at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.isFromWsdl(ReflectionServiceFactoryBean.java:543)
        at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.java:547)
        at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:265)
        at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:215)
        at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:102)
        at org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:159)
        at org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactoryBean.java:211)
        at org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:456)
        at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:334)
        at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:251)
        at org.apache.cxf.ws.discovery.internal.WSDiscoveryServiceImpl.startup(WSDiscoveryServiceImpl.java:238)
        at org.apache.cxf.ws.discovery.internal.WSDiscoveryServiceImpl.serverStarted(WSDiscoveryServiceImpl.java:148)
        at org.apache.cxf.ws.discovery.listeners.WSDiscoveryServerListener.startServer(WSDiscoveryServerListener.java:73)
        at org.apache.cxf.bus.managers.ServerLifeCycleManagerImpl.startServer(ServerLifeCycleManagerImpl.java:61)
        at org.apache.cxf.endpoint.ServerImpl.start(ServerImpl.java:146)
        at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:362)
        at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:251)
        at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:539)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
        at java.lang.reflect.Method.invoke(Method.java:611)
实在是找不到原因了,请高手解答。


加载中
返回顶部
顶部