This week's book giveaway is in the HTML/CSS/JavaScript forum.
We're giving away four copies of Practical SVG and have Chris Coyier on-line!
See this thread for details.
Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Axis2, Tomcat 5.5.25Null pointer exception thrown when using HTTPS client connection.

Steve Wu
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I configure my Tomcat5.5.25 for SSL connection. I can access my Axis2 Webservices through "https://localhost:8443/mytest/services/LoginService".

I setup a client to use HTTPS to call a web service method as follow:

System.setProperty( "", "C:/keystore_certs/client.keystore");
System.setProperty("", "changeit");

AuthenticationServiceStub stub = new AuthenticationServiceStub(https://localhost:8443/mytest/services/LoginService);
// initialize data here

// web service call

When I made this call I get the following exception on the client console:

.apache.axis2.AxisFault: java.lang.NullPointerException
at org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(
at org.apache.axis2.description.OutInAxisOperationClient.handleResponse(
at org.apache.axis2.description.OutInAxisOperationClient.send(
at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(
at org.apache.axis2.client.OperationClient.execute(

Here's the exception thatis thrown in Tomcat console:

at org.apache.axis2.engine.DispatchPhase.fillContextsFromSessionContext(
at org.apache.axis2.engine.DispatchPhase.loadContexts(
at org.apache.axis2.engine.DispatchPhase.checkPostConditions(
at org.apache.axis2.engine.Phase.invoke(
at org.apache.axis2.engine.AxisEngine.invoke(
at org.apache.axis2.engine.AxisEngine.receive(
at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(
at org.apache.axis2.transport.http.AxisServlet.doPost(
at javax.servlet.http.HttpServlet.service(
at javax.servlet.http.HttpServlet.service(
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
at org.apache.catalina.core.StandardWrapperValve.invoke(
at org.apache.catalina.core.StandardContextValve.invoke(
at org.apache.catalina.core.StandardHostValve.invoke(
at org.apache.catalina.valves.ErrorReportValve.invoke(
at org.apache.catalina.core.StandardEngineValve.invoke(
at org.apache.catalina.connector.CoyoteAdapter.service(
at org.apache.coyote.http11.Http11Processor.process(
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(
at org.apache.tomcat.util.threads.ThreadPool$

But if I had a browser asscessing my services in HTTPS mode as (https://localhost:8443/mytest/Services/), the above client call succeed.

My question are:
1) why do I have the browser open in order to make a HTTPS webservice call?
2) Am I missing some configuration in Axis2 or Tomcat that can initialize or esteblish HTTPS connection?

Always! Wait. Never. Shut up. Look at this tiny ad.
the new thread boost feature: great for the advertiser and smooth for the coderanch user
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!