This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Web Services and the fly likes Axis and HTTP code = 100 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Web Services
Bookmark "Axis and HTTP code = 100" Watch "Axis and HTTP code = 100" New topic

Axis and HTTP code = 100

JeanLouis Marechaux
Ranch Hand

Joined: Nov 12, 2001
Posts: 906
Hi all,

I need your help here to figure out a problem I'm facing with Axis.

I have an Axis client (version 1.1). It sends a request to a provider, and the provider sends back a response. (Until now, everything is ok and quite simple).
Using TCPMon, I can se the provider sends 2 http response s. First a HTTP 100 (Continue), then a HTTP 200 OK

But my axis client raises an AxisFault while processing the response.
at org.apache.axis.transport.http.HTTPSender.readFromSocket( Code))

Sounds like my Axis client is not able to deal with HTTP 100 (Continue)....

Any idea to solve this problem ???

Thanks in advance

/ JeanLouis<br /><i>"software development has been, is, and will remain fundamentally hard" (Grady Booch)</i><br /> <br />Take a look at <a href="" target="_blank" rel="nofollow">Agile OpenUP</a> in the Eclipse community
JeanLouis Marechaux
Ranch Hand

Joined: Nov 12, 2001
Posts: 906
after some reserch whithin AXIS source code, it sounds like http 100 (continue) is not really supported by axis if the request had no Expect : 100-continue header.

If this is true (I'm not quite sure), then it is an axis bug, as the http W3c spec mentions a server can return a http 100 status code even if the client had not required it...
JeanLouis Marechaux
Ranch Hand

Joined: Nov 12, 2001
Posts: 906
I would like to find a workround to my problem,

Does anybody know how to configure/use the Axis client to have "Expect : 100-continue" in each header request ??
JeanLouis Marechaux
Ranch Hand

Joined: Nov 12, 2001
Posts: 906
Workaround 1 :
Send SOAP request in HTTP 1.0, so that the server is not allowed to return a HTTP 100 Continue status.
This is not a good idea as WS-I discourage the use of HTTP 1.0 (1.1 is prefered)

Workaround 2 :
Send the SOAP request with a Expect : 100 -Continue header. Then Axis source code work fine and is able to deal with 100-Continue response

Nevertheless, with W/A 2, you need to enable the Axis chunk mode....
Balaji Loganathan
author and deputy

Joined: Jul 13, 2001
Posts: 3150
Thanks for updating Jean

Spritle Software Blogs
Have you checked out Aspose?
subject: Axis and HTTP code = 100
It's not a secret anymore!