hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Kalnichevski <ol...@apache.org>
Subject Re: [HttpConn] time for review
Date Fri, 19 Jan 2007 17:55:32 GMT
On Sun, 2007-01-14 at 22:25 +0100, Roland Weber wrote:
> Oleg Kalnichevski wrote:
> > On Sun, 2007-01-14 at 20:58 +0100, Roland Weber wrote:
> >> Oleg Kalnichevski wrote:
> >>
> >>> True. But I somehow I can't help thinking #open() and #update() might
> >>> suffice. Why not use #open() / #update() instead of #prepare / #open()?

> >> Ah, I get the idea. Modal behavior of open().
> >> I didn't think of that because it means calling
> >> open() with a socket that is not open :-)
> > 
> > This is the reason why I personally prefer 'bind'/'rebind' semantics to
> > 'open/'update'.  
> 
> Make sure to change the method names accordingly in your patch.
> There's HttpConnection.isOpen(), which wouldn't match with an
> open() method that does not actually open the connection.
> But I'm afraid we'd need an isBound() method to determine whether
> a call to update/rebind is permissible, which would nullify the
> advantage of loosing the prepare() method.
> 
> Btw, I think "announce" would be a better name than "prepare".
> It avoids the false assumption that preparation is mandatory.
> 

Roland,

I played around with various options and found none of them satisfactory
enough. I still think we may be able to do away with #prepare() method.
There will be no need to "announce" an unconnected socket the connection
at all we somehow manage to provide a mechanism to look up the socket by
the HTTP request. This way we could abort request's execution by simply
closing the socket. No need to muck around with the connection.

Let's move onto other issues and deal with this one later

Oleg 



> cheers,
>   Roland
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpcomponents-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: httpcomponents-dev-help@jakarta.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: httpcomponents-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpcomponents-dev-help@jakarta.apache.org


Mime
View raw message