axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "keith chapman" <keithgchap...@gmail.com>
Subject Re: Axis 2.0 Content-type
Date Tue, 02 Oct 2007 16:29:30 GMT
Hi,

The SOAPaction is an attribute which can be used to dispatch a message. If a
service advertises that it uses a SOAPAction you can set it in the client so
that the client sends it in the request. As SOAPaction is mandatory in SOAP
1.1 request you should atleast have the following header

SOAPAction: ""

What is the client that your using. If its axis2 it does the above (Add an
empty SOAPaction if its not specified) if the request is SOAP 1.1.

Thanks,
Keith

On 10/2/07, Ganesan, Chandru <chandru.ganesan@hp.com> wrote:
>
>
> Hi Keith
>
> Thanks for the quick response.
>
> As you've guessed correctly the request does not contain a SOAPAction. I'm
> not quite clear about what should the value of SOAPAction be so that Axis
> 2.0 treats it as SOAP 1.1 request. As I'm researching this topic,
> appreciate your thoughts on it.
>
> Thanks
> Chandru Ganesan
>
>
>  ------------------------------
> *From:* keith chapman [mailto:keithgchapman@gmail.com]
> *Sent:* Tuesday, October 02, 2007 10:59 AM
> *To:* axis-user@ws.apache.org
> *Subject:* Re: Axis 2.0 Content-type
>
> No you dont need to modify your axis2.xml leave it as it was. Can you
> check the SOAP request you sent. I'm sure it does not contain the SOAPAction
> header. In SOAP 1.1 the SOAPAction is mandatory and axis2 uses this as a
> key to differentiate  between REST request and SOAP 1.1 request (As some
> REST request uses  text/xml as the contentType). The reason your response
> was application/xml is because Axis2 treated  your request as a REST request
> and responded accordingly.
>
> Thanks,
> Keith.
>
> On 10/2/07, Ganesan, Chandru <chandru.ganesan@hp.com> wrote:
> >
> >
> > Hi
> >
> > When I send a SOAP request to Axis 2.0 service the response contains
> > content-type=application/xml in the HTTP header. This causes WSDL/SOAP
> > client tool to throw an exception as it doesn't understand the
> > content-type of application/xml. For SOAP 1.1 it expects
> > content-type=text/xml. I  modified the Axis2.xml to include following
> > lines. But this still doesn't return  content-type=text/xml. Am I
> > missing something in the Axis2.xml so that content-type of text/xml can
> > be returned in the response.
> >
> > Appreciate your input very much.
> >
> > Modified Axis2.xml contains following lines for text/xml:
> > =========================================================
> > <messageBuilders>
> > <messageBuilder contentType="text/xml"
> > class=""/>
> > <messageBuilder contentType=""
> > class=""/>
> > <messageBuilder contentType="multipart/form-data"
> > class=""/>
> > </messageBuilders>
> >
> >
> > SOAP response
> > =============
> > "HTTP/1.1 200 OK[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Via: 1.1 HOUWEBPROXY03[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Connection: Keep-Alive[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Proxy-Connection: Keep-Alive[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Transfer-Encoding: chunked[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Date: Mon, 01 Oct 2007 19:37:41 GMT[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Content-Type: application/xml; charset=utf-8[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Cache-Control: no-cache="set-cookie"[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "Set-Cookie:
> > JSESSIONID=zLGnHBMF7LRLqfr59qZ8TGWQXyHx6j7qh1BBTZyGQRXjsZn3Wb9n!16440382
> > 36; path=/[\r][\n]"
> > 128708 DEBUG [ class ro.sync.ui.application.A.J ] httpclient.wire.header
> > - << "X-Powered-By: Servlet/2.4 JSP/2.0[\r][\n]"
> >
> >
> > thanks
> > Chandru Ganesan
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-user-help@ws.apache.org
> >
> >
>
>
> --
> Keith Chapman
> WSO2 Inc.
> Oxygen for Web Services Developers.
> http://wso2.org/
>
>


-- 
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/

Mime
View raw message