Return-Path: Delivered-To: apmail-jakarta-httpclient-dev-archive@www.apache.org Received: (qmail 81738 invoked from network); 13 Mar 2006 23:08:08 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 13 Mar 2006 23:08:08 -0000 Received: (qmail 2433 invoked by uid 500); 13 Mar 2006 23:08:07 -0000 Delivered-To: apmail-jakarta-httpclient-dev-archive@jakarta.apache.org Received: (qmail 2414 invoked by uid 500); 13 Mar 2006 23:08:07 -0000 Mailing-List: contact httpclient-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "HttpClient Project" Reply-To: "HttpClient Project" Delivered-To: mailing list httpclient-dev@jakarta.apache.org Received: (qmail 2403 invoked by uid 99); 13 Mar 2006 23:08:07 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 13 Mar 2006 15:08:07 -0800 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=RCVD_IN_SORBS_WEB X-Spam-Check-By: apache.org Received-SPF: neutral (asf.osuosl.org: local policy) Received: from [195.186.18.65] (HELO mail19.bluewin.ch) (195.186.18.65) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 13 Mar 2006 15:08:06 -0800 Received: from [192.168.0.4] (81.62.1.153) by mail19.bluewin.ch (Bluewin 7.2.071) id 43E4A50D00C04653 for httpclient-dev@jakarta.apache.org; Mon, 13 Mar 2006 23:07:45 +0000 Subject: Re: [HttpComponents][HttpCore] EntityGenerator and EntityWriter interfaces revisited From: Oleg Kalnichevski To: HttpClient Project In-Reply-To: <44157667.3010005@dubioso.net> References: <1142193739.22315.7.camel@localhost.localdomain> <44157667.3010005@dubioso.net> Content-Type: text/plain Date: Tue, 14 Mar 2006 00:07:43 +0100 Message-Id: <1142291264.8397.15.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.4.1 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N On Mon, 2006-03-13 at 14:40 +0100, Roland Weber wrote: > Hi Oleg, > > > One of the complaints about HttpCore API we have been unable to resolve > > so far is an asymmetry between the process of entity serialization > > (represented by the EntityWriter interface) and that of entity > > de-serialization (represented by the EntityGenerator interface) was . > > Did I complain loudly? I thought that was just in my mind :-) You did mention that as an API deficiency at some point of time while we were discussing the possibility of moving the transfer encoding handling code from the HTTP connection classes to the HTTP request / response interceptors. > Seriously, I had also spend some brief thoughts about that point, > but I don't remember reading anything about it on the mailing list. > I guess you have gathered feedback elsewhere. > > > (1) Rename EntityWriter to HttpEntitySerializer and EntityGenerator to > > HttpEntityDeserializer (I am open to different (better) names). > > Fine by me. No better names jump into my mind. > > > (2) The HttpEntitySerializer will be required to set (override if > > needed) the 'Transfer-Encoding' and 'Content-Length' headers to ensure > > the integrity of the underlying HTTP connection > > The Transfer-Encoding header is the responsibility of the transport > layer, I have no problem with having it set by the serializer. For the > Content-Length header, I would prefer to see an exception thrown if an > inappropriate header has been set explicitly. For both, actually. > Agreed. I'll start hacking on it tomorrow Oleg --------------------------------------------------------------------- To unsubscribe, e-mail: httpclient-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: httpclient-dev-help@jakarta.apache.org