commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bob Waldrop <rlwald...@yahoo.com>
Subject RE: [HttpClient][Request] Ability to debranch some logic
Date Fri, 02 Aug 2002 22:43:11 GMT
Yes.  Helpful and nice.  The loan won't work out for
this property, though.  Unfortunately, the owner
occupancy ratio is too low.  Only 12/42 are owner
occupied.

Thanks for the help!

--bob w.

--- Vincent Massol <vmassol@octo.com> wrote:
> dIon,
> 
> Thanks. I am probably blind but I can't find an
> example of any 401 test
> in the URL you provided (authentication). I can test
> all response codes
> fine with HttpClient except 401, hence my initial
> email.
> 
> Here is the HttpClient code that is involved (I
> think) :
> 
>             if (HttpStatus.SC_UNAUTHORIZED ==
> statusCode) {
>                 Header wwwauth =
> getResponseHeader("WWW-Authenticate");
>                 if (null != wwwauth) {
> [some code to send another request to authenticate]
> 
> I haven't followed closely the code but I don't see
> any code to debranch
> this. For redirects it works fine as the code is :
> 
>             } else if
> (HttpStatus.SC_MOVED_TEMPORARILY == statusCode ||
>                HttpStatus.SC_MOVED_PERMANENTLY ==
> statusCode ||
>                HttpStatus.SC_TEMPORARY_REDIRECT ==
> statusCode) {
>                 if (getFollowRedirects()) {
> [...]
> 
> thus getFollowRedirects() returns false is
> HttpClient is set not to
> follow redirects.
> 
> As I don't follow all the code for authentication,
> can someone from
> HttpClient tell me if it is possible to test a 401
> response coming from
> the server without HttpClient intercepting it ?
> 
> Thanks
> -Vincent
> 
> > -----Original Message-----
> > From: dion@multitask.com.au
> [mailto:dion@multitask.com.au]
> > Sent: 02 August 2002 04:10
> > To: Jakarta Commons Developers List
> > Subject: RE: [HttpClient][Request] Ability to
> debranch some logic
> > 
> > "Vincent Massol" <vmassol@octo.com> wrote on
> 08/02/2002 12:36:55 AM:
> > 
> > > Hi dIon,
> > >
> > > No I haven't. Where should I look at exactly ?
> Are you saying that
> you
> > > are able to write Latka test for 401 HTTP
> responses ?
> > 
> > Should be able to.....
> > 
> > here's a sample....
> > 
> > http://cvs.apache.org/viewcvs/jakarta-
> >
>
commons/latka/src/jelly/latka.jelly?rev=1.19&content-
> > type=text/vnd.viewcvs-markup
> > 
> > It all relies on httpclient under the covers
> though...........
> > >
> > > Thanks
> > > -Vincent
> > --
> > dIon Gillard, Multitask Consulting
> > Work:      http://www.multitask.com.au
> > Developers:
> http://adslgateway.multitask.com.au/developers
> 
> 
> 
> --
> To unsubscribe, e-mail:  
> <mailto:commons-dev-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:commons-dev-help@jakarta.apache.org>
> 


__________________________________________________
Do You Yahoo!?
Yahoo! Health - Feel better, live better
http://health.yahoo.com

--
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