Return-Path: Delivered-To: apmail-jakarta-httpcomponents-dev-archive@www.apache.org Received: (qmail 40341 invoked from network); 7 Apr 2007 09:45:39 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 7 Apr 2007 09:45:39 -0000 Received: (qmail 36847 invoked by uid 500); 7 Apr 2007 09:45:45 -0000 Delivered-To: apmail-jakarta-httpcomponents-dev-archive@jakarta.apache.org Received: (qmail 36821 invoked by uid 500); 7 Apr 2007 09:45:45 -0000 Mailing-List: contact httpcomponents-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "HttpComponents Project" Delivered-To: mailing list httpcomponents-dev@jakarta.apache.org Received: (qmail 36808 invoked by uid 99); 7 Apr 2007 09:45:45 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 07 Apr 2007 02:45:45 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (herse.apache.org: local policy) Received: from [62.2.95.247] (HELO smtp.hispeed.ch) (62.2.95.247) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 07 Apr 2007 02:45:38 -0700 Received: from [192.168.1.102] (84-75-116-76.dclient.hispeed.ch [84.75.116.76]) (authenticated bits=0) by smtp.hispeed.ch (8.12.11.20060308/8.12.11/taifun-1.0) with ESMTP id l379j61n018420 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) for ; Sat, 7 Apr 2007 11:45:16 +0200 Subject: Re: Handling content-transfer-encoding encoding and multipart requests with httpcomponents From: Oleg Kalnichevski To: HttpComponents Project In-Reply-To: References: Content-Type: text/plain Date: Sat, 07 Apr 2007 11:45:05 +0200 Message-Id: <1175939106.31683.2.camel@okhost> Mime-Version: 1.0 X-Mailer: Evolution 2.8.1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV version 0.88.7, clamav-milter version 0.88.7 on smtp-02.tornado.cablecom.ch X-Virus-Status: Clean X-DCC-spamcheck-02.tornado.cablecom.ch-Metrics: smtp-02.tornado.cablecom.ch 1378; Body=1 Fuz1=1 Fuz2=1 X-Virus-Checked: Checked by ClamAV on apache.org On Sat, 2007-04-07 at 04:17 +0200, Jochen Wiedmann wrote: > Hi, > > I am writing this as a followup to > > http://issues.apache.org/jira/browse/FILEUPLOAD-131 > > This issue request is about handling content-transfer-encoding with > commons-fileupload. > > In this request, Oleg Kalnichevski explains: > > > I doubt HttpCore would be of any use here, as it does not (and is not supposed to) > > provide any content codecs. You probably may want to take a closer look at > > Commons Codec, which provides two content transfer codecs mentioned in > > RFC1521: quoted-printable and base64. Some efforts will have to spent on > > getting those codecs to work with I/O streams, though. > > I have studied the charta of the HttpComponents and find this > statement most possibly caused by the following sentence: > > Jakarta HttpComponents MUST be content agnostic. The project DOES NOT > develop components intended to produce or consume content of HTTP messages. > > I would like to ask to rethink this opinion, at least partially:The > httpclient project provides support for creation of multipart > requests. This support is still content agnostic, apart from the fact > that a very widespread packaging mechanism is used. > > IMO, the server side should at least support the same level that the > client side does. The content encoding and, in particular, the > content-transfer-encoding cannot be viewed as independent from the > HTTP protocol. Supporting typical cases like multipart/form-data > should at least be provided as a sample implementation. > > If you cannot agree with my opinion, I'd like to ask how you would > handle such cases like multipart parsing in your own code. What MIME > or other libraries would you use or recommend? > > > Thanks, > > Jochen Hi Jochen, The HttpComponents charter was made so restrictive primarily to please some Tomcat folks who viewed the project as promoting unnecessary competition within ASF. Lots of things changed since those days. ASF now hosts projects that directly compete with one another, so a revision of the charter is certainly due. Having said that, I personally think we should stay focused on HTTP aspects and depend on external libraries for things such as content coding. The original plan with regards to the multipart encoding was and still is to factor it out of HttpClient and move it to Commons Codec. There is already a project to that end [1] which unfortunately got stalled. We have never had any multipart decoding / parsing code in HttpClient in the first place, so I wanted to approach FileUpload folks with a request to contribute their multipart decoding code to Codec to make the multipart codec feature-complete. Commons Codec already provides BASE64 and quoted-printable codecs needed for the content-transfer-encoding support. To me it would also make sense to develop mulpitart coding / decoding code out of Commons Codec. I also beleive Apache JAMES provides a complete MIME library of its own, which _may_ already have a complete set of codecs needed for the content-transfer-encoding support. I hope this makes our position clearer. Cheers Oleg [1] http://svn.apache.org/repos/asf/jakarta/commons/dormant/codec-multipart/ --------------------------------------------------------------------- To unsubscribe, e-mail: httpcomponents-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: httpcomponents-dev-help@jakarta.apache.org