java.lang.ClassCastException: com.sun.xml.internal.messaging.saaj.soap.ver1_1.Envelope1_1Impl cannot be cast to org.apache.axis.message
FIRST SOLUTION: (for administrators; is a global solution)
Set the system property when invoking Java process :
-Djavax.xml.soap.MessageFactory=org.apache.axis.soap.MessageFactoryImpl
SECOND SOLUTION: (for developers; is a local solution)
a ) Locate in the source code of your application the place where de message factory is instantied to create SOAP messages:
MessageFactory.newInstance() // --> javax.xml.soap.MessageFactory
b) Replace this expression (MessageFactory.newInstance()) with:
new org.apache.axis.soap.MessageFactoryImpl()
Set the system property when invoking Java process :
-Djavax.xml.soap.MessageFactory=org.apache.axis.soap.MessageFactoryImpl
SECOND SOLUTION: (for developers; is a local solution)
a ) Locate in the source code of your application the place where de message factory is instantied to create SOAP messages:
MessageFactory.newInstance() // --> javax.xml.soap.MessageFactory
b) Replace this expression (MessageFactory.newInstance()) with:
new org.apache.axis.soap.MessageFactoryImpl()
thanks Simple answer
ReplyDelete