You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Padmathandugan <Pa...@yahoo.co.in> on 2016/03/09 10:43:24 UTC

Null Pointer Exception at WSDLServiceFactory init method

I am getting below exception while invoking the client service generated by
CXF.

Below is the piece of code where I am getting exception

public Object createStub() {
QueryCustomerOutService queryCustomerIdentification = new
QueryCustomerOutService(); //Getting exception at this line
		querybusinesspartnerIdentificationStub =
queryCustomerIdentification.getHTTPPort();
		return querybusinesspartnerIdentificationStub;
	}


osgiClassLoaderClass:class
org.apache.felix.framework.ModuleImpl$ModuleClassLoaderJava5
java.lang.NullPointerException
	at
org.apache.cxf.wsdl11.WSDLServiceFactory.<init>(WSDLServiceFactory.java:92)
	at org.apache.cxf.jaxws.ServiceImpl.initializePorts(ServiceImpl.java:199)
	at org.apache.cxf.jaxws.ServiceImpl.<init>(ServiceImpl.java:147)
	at
org.apache.cxf.jaxws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:98)
	at javax.xml.ws.Service.<init>(Service.java:36)
	at
uk.co.centrica.webservice.querycustomerservice.QueryCustomerOutService.<init>(QueryCustomerOutService.java:46)
	at
com.Package.gateway.callers.SampleCaller.createStub(SampleCaller.java:67)

I am using CXF in OSGI and deployed my aplication in Oracle weblogic server
10.3.4 and using Apache Felix as my OSGI container.

Used below code snippet

<java classname="org.apache.cxf.tools.wsdlto.WSDLToJava" fork="true">

in my ant build script to generate the client from wsdl. I am using CXF
version 2.7.2 and running the application in java 6. I have added all jars
relevant to CXF in buildpath and packaged in the OSGI bundle, added them in
classpath in manifest as well.

Anybody please help me out in resolving this issue. I tried many options as
suggested in many blogs and threads, but no luck. I am struggling with this
issue for almost 2 weeks now.

Any timely help would me much appreciated. Thanks in advance.




--
View this message in context: http://cxf.547215.n5.nabble.com/Null-Pointer-Exception-at-WSDLServiceFactory-init-method-tp5766772.html
Sent from the cxf-user mailing list archive at Nabble.com.