axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kusuma Atmakuri <>
Subject Axis 1.6.2 - NPE when invoking CommonsHTTPTransportSender
Date Mon, 19 Jan 2015 14:56:21 GMT

While trying to upgrade to Axis 1.6.2, I ran into an issue - NPE is thrown
when invoking CommonsHTTPTransportSender. Below is the stack trace.

*Exception in thread "main" java.lang.NullPointerException*
*    at
*    at org.apache.axis2.engine.AxisEngine.send(*
*    at
*    at
*    at

Tried creating the context in different ways but nothing had helped.
When googled, found a couple of threads on the same issue but that was to
do with the older versions of Axis.
When checked out the source, found the following in send() method of
org.apache.axis2.engine.AxisEngine. Shouldn't the sender be initialized
before invoked? Or *transportOut *should have returned an initialized
sender, right?

*TransportOutDescription transportOut = msgContext.getTransportOut();*
*if (transportOut == null) {*
*    throw new AxisFault("Transport out has not been set");*
*TransportSender sender = transportOut.getSender();*
*// This boolean property only used in client side fireAndForget invocation*
*//It will set a property into message context and if some one has set the*
*//property then transport sender will invoke in a diffrent thread*
*if (Utils.isClientThreadNonBlockingPropertySet(msgContext)) {*
*    msgContext.getConfigurationContext().getThreadPool().execute(*
*            new TransportNonBlockingInvocationWorker(msgContext, sender));*
*} else {*
*    sender.invoke(msgContext);*

Can someone please throw some light on this? Am I missing something here?
What should be the work around?


Thank you!

View raw message