Return-Path: Delivered-To: apmail-httpd-apreq-dev-archive@httpd.apache.org Received: (qmail 38546 invoked by uid 500); 13 Jan 2003 09:41:56 -0000 Mailing-List: contact apreq-dev-help@httpd.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list apreq-dev@httpd.apache.org Received: (qmail 38503 invoked from network); 13 Jan 2003 09:41:55 -0000 Sender: root@localhost.localdomain Message-ID: <3E22888E.EB0B294E@netmask.it> Date: Mon, 13 Jan 2003 11:36:14 +0200 From: Eli Marmor Organization: Netmask (El-Mar) Internet Technologies X-Mailer: Mozilla 4.08 [Hebrew Support by elmar.co.il (X11; I; Linux 2.4.8-26mdk i686) MIME-Version: 1.0 To: apreq list Subject: Re: cvs tagged as v1_1 (was Re: 1.1_rc4) References: <3E1F7C59.9090506@stason.org> <3E20C97A.2020200@stason.org> <3E20D9FB.9010304@stason.org> <3E221E7E.1479672@netmask.it> <3E22248D.9080301@stason.org> <3E2224E6.770C6FF8@netmask.it> <07e101c2bae2$ad398b40$3f0aa8c0@fmenc001dev> Content-Type: text/plain; charset=iso-8859-8 Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Issac Goldstand wrote: > Eli, > Could you elaborate a bit on exactly what you would consider to be > high-level and what low-level? Are you trying to say that we could make > low-level parsers which could, for example, be plugged into an SMTP module > for Apache to look at MIME encoded messages using the same "low-level" code > as HTTP's multipart forms? I hope I'm on the right track here, and if so, I > like the idea. But could you think of a good list of items to be put in the > high-level and a list for the low-level? I don't have an existing list, but the following example may clear my idea: Let's take apreq_request_new (I use the terminology of apreq-2): The only justification of requiring the request_rec is the pool. So we can move the code of the function to a sub-function (called "apr_request_new") and leave only the following in the original function: apreq_request_t *apreq_request_new(request_rec *r) { return apr_request_new(r->pool); } (some of the fields of request_rec, like args and the headers, will have to be passed by the higher level functions to the lower level ones, or - alternatively - to be added to apreq_request_t). Of course, this is a simple example. Sometimes, it may be trickier. Especially in cases like multipart POSTs, where the parsing and handling is needed in APR (i.e. CGI, FastCGI, etc.), but the reading of the block (or - more precisely - reading from the input filter) - should be left to the higher level. But it is still easier than the effort of porting to Apache-2; Contrary to THAT effort, most of the work here is copy-paste... -- Eli Marmor marmor@netmask.it CTO, Founder Netmask (El-Mar) Internet Technologies Ltd. __________________________________________________________ Tel.: +972-9-766-1020 8 Yad-Harutzim St. Fax.: +972-9-766-1314 P.O.B. 7004 Mobile: +972-50-23-7338 Kfar-Saba 44641, Israel