commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rodney Waldhoff" <rw...@hotmail.com>
Subject Re: HTTPClient versions ...
Date Mon, 29 Oct 2001 22:34:44 GMT
>The slide version seems to have some enhancements, specifically that 
>HttpException supports storing the HTTP status code.

The only circumstance under which HTTP Client (2.0) has actually obtained an 
HTTP status code but will throw an HttpException anyway is in the case of a 
cross-server, cross-port, or cross-protocol redirect.

(Without adding a ConnectionFactory/ConnectionPool sort of interface it is 
not easy for the HttpMethod to obtain a new HttpConnection to a different 
server, port or over a different protocol, or to hand this connection back 
to the user-agent implementation. I'd like to add such an construct, but 
perhaps after the 2.0 release.)

Perhaps it would be more approriate to simply return the status code in this 
circumstance (note that HTTP Client 2.0 always returns the status code from 
the execute method), as we do we recursive redirects or unauthorized 
responses.  In fact if no one complains I'll suggest we do just that.

In general, I'd argue that if you've obtained a status code, then the HTTP 
transaction was succesful (from the protocol perspective) and there's no 
exceptional condition requiring us to break the normal application flow. 
Disagree?  Let's discuss.

>I guess that the HTTP client isn't fully split off from Slide yet or 
>something?

I think it's more the opposite--HTTP Client 2.0 *has* been fully split off 
from Slide.

The short answer is that HTTP Client 2.0 is a refactoring of the version in 
Slide, representing changes we'd like to make but that break both Slide's 
compatiblity with HTTP Client and Slide's compatibility with its clients 
(since Slide exposes the full HTTP Client API to its clients). A 
Slide-compatible 1.0 release may also be forthcoming, addressing some bugs 
identified as part of the refactoring.

>We are pretty keen to use the HTTP client as it will save us having to 
>write something pretty similar - what can we do to help get things sorted?

Jump in, the water's fine.  In addition to the above "to do", there's 
several listed in the online status file.

Note that HTTP Client 2.0 is already used by Latka, and where I work we use 
it for a couple of internal, production applications as well.

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message