I'm using a SOAP
web-service
developed by webservicex
server (downloaded from here) to develop a country locator application with IP address as input. Imported the jar files and java files, using the wsimport
. Now, developed a java application that returns the country name by taking the input as IP address. Everything was working as per plan, without any syntax errors.
But when executing the java program, it returned an error which I couldn't trace back(I'm a learner). I'm not sure if it is a problem with either WS
or Jar
files.
The error is as follows:
Exception in thread "main" com.sun.xml.internal.ws.fault.ServerSOAPFaultException: Client received SOAP Fault from server: System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.NullReferenceException: Object reference not set to an instance of an object.
at WebserviceX.Service.Adapter.IPAdapter.CheckIP(String IP)
at WebserviceX.Service.GeoIPService.GetGeoIP(String IPAddress)
--- End of inner exception stack trace --- Please see the server log to find more detail regarding exact cause of the failure.
at com.sun.xml.internal.ws.fault.SOAP11Fault.getProtocolException(SOAP11Fault.java:178)
at com.sun.xml.internal.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:116)
at com.sun.xml.internal.ws.client.sei.StubHandler.readResponse(StubHandler.java:238)
at com.sun.xml.internal.ws.db.DatabindingImpl.deserializeResponse(DatabindingImpl.java:189)
at com.sun.xml.internal.ws.db.DatabindingImpl.deserializeResponse(DatabindingImpl.java:276)
at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:104)
at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:77)
at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(SEIStub.java:147)
at com.sun.proxy.$Proxy31.getGeoIP(Unknown Source)
at org.giri.soap.IPcountryFinder.main(IPcountryFinder.java:20)
Can someone shed some light on why this error occurs, am I missing from normal steps in executing the program.
Is this some an error returned by the web-service
provider? If so, should I contact the service provider?
I suppose it works with limited number of ip addresses. For example, for me it works with IPs of bbc.com, google.com, but it doesn't work with facebook.com.