Hi,
Did anyone can help me on how to retrieve the soap header in axis2?
Below is my service.xml file details:
<service name="TestService" style="message">
<parameter name="ServiceClass"
locked="false">ReceiverService</parameter>
<operation name="soapRec">
<messageReceiver
class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/>
<actionMapping>urn:soapRec</actionMapping>
</operation>
</service>
if i use OMElement as incoming parameter, my web service is working but i
not able to retrieve the soap header.
public OMElement soapRec(OMElement element) {}
In order to retrieve the soap header, i change the function to below
method:-
public void soapRec(SOAPEnvelope req, SOAPEnvelope resp){}
but i get this error when i call the web service:-
<?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Header
/><soapenv:Body><soapenv:Fault><faultcode>soapenv:Client</faultcode><faultstring>Raw
Xml provider supports only the methods bearing the signature public
OMElement &lt;method-name&gt;(OMElement) where the method name can
be anything</faultstring><detail><Exception>org.apache.axis2.AxisFault: Raw
Xml provider supports only the methods bearing the signature public
OMElement &lt;method-name&gt;(OMElement) where the method name can
be anything
at
org.apache.axis2.receivers.RawXMLINOutMessageReceiver.invokeBusinessLogic(RawXMLINOutMessageReceiver.java:95)
at
org.apache.axis2.receivers.AbstractInOutSyncMessageReceiver.receive(AbstractInOutSyncMessageReceiver.java:37)
at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:454)
at
org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:284)
at
org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:136)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
Is that cos by the invalid "messageReceiver" type? if yes, what shld i
change it to?
--
View this message in context:
http://www.nabble.com/How-to-retrieve-SOAP-Header-in-Axis2-tf3900058.html#a11056343
Sent from the Axis - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]