Hi Chinthaka:

Eran Chinthaka wrote:
I have a slight problem in fully implementing AXIS2-1023. Question in
simple terms is : when a message comes to Axis servlet (assume the same
servlet handles both the REST and SOAP messages), how can we know
whether its a SOAP or a REST message *without* looking at the SOAP
message? (yes, I'm talking only about HTTP case).

If the message is SOAP 1.1, then SOAPAction header is always there. If
its SOAP 1.2 then SOAPAction *may* be in content type string, and spec
hasn't mandated that.

If its REST, then the content type can be anything.

I think the algorithm is as follows:

1) check media-type. If it's either of the well-defined ones for SOAP 1.2 (application/soap+xml, application/xop+xml), it's SOAP 1.2.

2) check for SOAPAction HTTP header.  If it's there, it's SOAP 1.1.

3) treat it as REST

Does that cover it?

--Glen

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to