Hi,
 
I am trying to deploy a web service by generating code from my WSDL.
 
My WSDL is organized in multiple files -
* Service.wsdl (Contains wsdl:service and wsdl:binding sections)
* Interface.wsdl (Contains wsdl:types, wsdl:message and wsdl:portType
sections )
* And few XSD files which define XML schema of input/output for web
service methods.
 
The services.xml looks like as below:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://xfire.codehaus.org/config/1.0
<http://xfire.codehaus.org/config/1.0> ">
<service>
 
<serviceClass>com.nortel.mrf.diameter.webservices.rf.RfClientWebServiceI
mpl</serviceClass>
    <wsdlURL>file:/D:/Service.wsdl</wsdlURL>
 
<serviceFactory>org.codehaus.xfire.jaxb2.JaxbServiceFactory</serviceFact
ory>
</service>
</beans>

When I try to browse to URL for wsdl, i.e.,
http://localhost:8080/mywebservice/services/mywebservices?wsdl, I get a
following null pointer exception.
 
I found out that the error is popping form wsdl4j code.  Currently,
wsdl4j-1.6.1.jar file is packaged with XFire distribution.

Error does not appear if I use wsdl4j-1.6.2.jar.
 
It will be great if you can bundle wsdl4j-1.6.2.jar with Xfire.
 
 
================================== Excpetion details
========================================================
INFO: Pre-instantiating singletons in factory
[org.springframework.beans.factory.support.DefaultListableBeanFactory
defining beans
[xfire.customEditorConfigurer,xfire.serviceRegistry,xfire.transportManag
er,xfire,xfire.typeMappingRegistry,xfire.aegisBindingProvider,xfire.serv
iceFactory,xfire.servletController,xfire.messageServiceFactory,xfire.mes
sageBindingProvider,org.codehaus.xfire.spring.ServiceBean]; parent:
org.springframework.beans.factory.support.DefaultListableBeanFactory
defining beans []; root of BeanFactory hierarchy]

Resovling. Base: null, URI:
file:/D:/wtp-eclipse/lets-build-ws-v4/XfireWs/src/Service.wsdl

Retrieving document at 'null'.

Resovling. Base: null, URI: Interface.wsdl

May 24, 2007 6:49:49 PM
org.springframework.beans.factory.support.AbstractBeanFactory
destroySingletons

INFO: Destroying singletons in factory
{org.springframework.beans.factory.support.DefaultListableBeanFactory
defining beans
[xfire.customEditorConfigurer,xfire.serviceRegistry,xfire.transportManag
er,xfire,xfire.typeMappingRegistry,xfire.aegisBindingProvider,xfire.serv
iceFactory,xfire.servletController,xfire.messageServiceFactory,xfire.mes
sageBindingProvider,org.codehaus.xfire.spring.ServiceBean]; parent:
org.springframework.beans.factory.support.DefaultListableBeanFactory
defining beans []; root of BeanFactory hierarchy}

May 24, 2007 6:49:49 PM org.codehaus.xfire.transport.http.XFireServlet
init

SEVERE: Error initializing XFireServlet.

org.springframework.beans.factory.BeanCreationException: Error creating
bean with name 'org.codehaus.xfire.spring.ServiceBean' defined in class
path resource [META-INF/xfire/services.xml]: Initialization of bean
failed; nested exception is java.lang.NullPointerException: null

java.lang.NullPointerException

at com.ibm.wsdl.xml.WSDLReaderImpl.parseImport(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.parseDefinitions(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at
org.codehaus.xfire.service.binding.ObjectServiceFactory.create(ObjectSer
viceFactory.java:181)

at
org.codehaus.xfire.annotations.AnnotationServiceFactory.create(Annotatio
nServiceFactory.java:410)

at
org.codehaus.xfire.spring.ServiceBean.afterPropertiesSet(ServiceBean.jav
a:172)

at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac
tory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1059)

at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac
tory.createBean(AbstractAutowireCapableBeanFactory.java:363)

at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab
stractBeanFactory.java:226)

at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab
stractBeanFactory.java:147)

at
org.springframework.beans.factory.support.DefaultListableBeanFactory.pre
InstantiateSingletons(DefaultListableBeanFactory.java:275)

at
org.springframework.context.support.AbstractApplicationContext.refresh(A
bstractApplicationContext.java:320)

at
org.codehaus.xfire.spring.XFireConfigLoader.getXFireApplicationContext(X
FireConfigLoader.java:107)

at
org.codehaus.xfire.spring.XFireConfigLoader.loadContext(XFireConfigLoade
r.java:41)

at
org.codehaus.xfire.transport.http.XFireConfigurableServlet.loadConfig(XF
ireConfigurableServlet.java:86)

at
org.codehaus.xfire.transport.http.XFireConfigurableServlet.createXFire(X
FireConfigurableServlet.java:54)

at
org.codehaus.xfire.transport.http.XFireServlet.init(XFireServlet.java:45
)

at javax.servlet.GenericServlet.init(GenericServlet.java:211)

at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.jav
a:1105)

at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:7
57)

at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:130)

at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:178)

at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:126)

at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:105)

at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:107)

at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:1
48)

at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:86
9)

at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.proc
essConnection(Http11BaseProtocol.java:664)

at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint
.java:527)

at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollow
erWorkerThread.java:80)

at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
.java:684)

at java.lang.Thread.run(Unknown Source)

May 24, 2007 6:49:49 PM org.apache.catalina.core.StandardWrapperValve
invoke

SEVERE: Allocate exception for servlet XFireServlet

org.springframework.beans.factory.BeanCreationException: Error creating
bean with name 'org.codehaus.xfire.spring.ServiceBean' defined in class
path resource [META-INF/xfire/services.xml]: Initialization of bean
failed; nested exception is java.lang.NullPointerException: null

java.lang.NullPointerException

at com.ibm.wsdl.xml.WSDLReaderImpl.parseImport(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.parseDefinitions(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)

at
org.codehaus.xfire.service.binding.ObjectServiceFactory.create(ObjectSer
viceFactory.java:181)

at
org.codehaus.xfire.annotations.AnnotationServiceFactory.create(Annotatio
nServiceFactory.java:410)

at
org.codehaus.xfire.spring.ServiceBean.afterPropertiesSet(ServiceBean.jav
a:172)

at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac
tory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1059)

at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac
tory.createBean(AbstractAutowireCapableBeanFactory.java:363)

at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab
stractBeanFactory.java:226)

at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Ab
stractBeanFactory.java:147)

at
org.springframework.beans.factory.support.DefaultListableBeanFactory.pre
InstantiateSingletons(DefaultListableBeanFactory.java:275)

at
org.springframework.context.support.AbstractApplicationContext.refresh(A
bstractApplicationContext.java:320)

at
org.codehaus.xfire.spring.XFireConfigLoader.getXFireApplicationContext(X
FireConfigLoader.java:107)

at
org.codehaus.xfire.spring.XFireConfigLoader.loadContext(XFireConfigLoade
r.java:41)

at
org.codehaus.xfire.transport.http.XFireConfigurableServlet.loadConfig(XF
ireConfigurableServlet.java:86)

at
org.codehaus.xfire.transport.http.XFireConfigurableServlet.createXFire(X
FireConfigurableServlet.java:54)

at
org.codehaus.xfire.transport.http.XFireServlet.init(XFireServlet.java:45
)

at javax.servlet.GenericServlet.init(GenericServlet.java:211)

at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.jav
a:1105)

at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:7
57)

at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:130)

at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:178)

at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:126)

at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:105)

at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:107)

at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:1
48)

at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:86
9)

at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.proc
essConnection(Http11BaseProtocol.java:664)

at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint
.java:527)

at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollow
erWorkerThread.java:80)

at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
.java:684)

at java.lang.Thread.run(Unknown Source)

 
 
Regards,
Srikanth
 



The information contained in this electronic message and any attachments to 
this message are intended for the exclusive use of the addressee(s) and may 
contain proprietary, confidential or privileged information. If you are not the 
intended recipient, you should not disseminate, distribute or copy this e-mail. 
Please notify the sender immediately and destroy all copies of this message and 
any attachments. 

WARNING: Computer viruses can be transmitted via email. The recipient should 
check this email and any attachments for the presence of viruses. The company 
accepts no liability for any damage caused by any virus transmitted by this 
email.
 
www.wipro.com

Reply via email to