Return-Path: Delivered-To: apmail-httpd-modules-dev-archive@locus.apache.org Received: (qmail 29421 invoked from network); 3 May 2008 17:29:49 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 3 May 2008 17:29:49 -0000 Received: (qmail 12508 invoked by uid 500); 3 May 2008 17:29:50 -0000 Delivered-To: apmail-httpd-modules-dev-archive@httpd.apache.org Received: (qmail 12489 invoked by uid 500); 3 May 2008 17:29:50 -0000 Mailing-List: contact modules-dev-help@httpd.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: modules-dev@httpd.apache.org Delivered-To: mailing list modules-dev@httpd.apache.org Received: (qmail 12478 invoked by uid 99); 3 May 2008 17:29:50 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 03 May 2008 10:29:50 -0700 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: 192.115.104.17 is neither permitted nor denied by domain of margol@beamartyr.net) Received: from [192.115.104.17] (HELO sa3.bezeqint.net) (192.115.104.17) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 03 May 2008 17:29:04 +0000 Received: from localhost (sa3 [127.0.0.1]) by sa3.bezeqint.net (Bezeq International SMTP out Mail Server) with ESMTP id F15D0300A3 for ; Sat, 3 May 2008 20:14:00 +0300 (IDT) X-Virus-Scanned: amavisd-new at bezeqint.net Received: from sa3.bezeqint.net ([127.0.0.1]) by localhost (sa3.bezeqint.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ssr7rKdf1bSk for ; Sat, 3 May 2008 20:13:56 +0300 (IDT) Received: from [192.168.2.12] (bzq-79-178-138-37.red.bezeqint.net [79.178.138.37]) by sa3.bezeqint.net (Bezeq International SMTP out Mail Server) with ESMTP for ; Sat, 3 May 2008 20:13:56 +0300 (IDT) Message-ID: <481CA0E2.80702@beamartyr.net> Date: Sat, 03 May 2008 20:29:06 +0300 X-IMBH: Yes From: Issac Goldstand Organization: Mirimar Networks User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: modules-dev@httpd.apache.org Subject: Re: Reading data from Request Body - Twice!! References: <489947c0805021117i2ae8fd3bld0b41ecac16704e5@mail.gmail.com> <20080503132136.2c563cf4@grimnir> In-Reply-To: <20080503132136.2c563cf4@grimnir> X-Enigmail-Version: 0.95.6 OpenPGP: url=http://www.beamartyr.net/pubkey.asc Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Nick Kew wrote: > On Fri, 2 May 2008 14:17:54 -0400 > "Subra A Narayanan" wrote: > >> Now if the MD5 checksum passes and now I want to read the data again, >> how would i do it? I cannot use the above function again, right? >> 'ap_should_client_block' has already told the client once to send the >> entire data once. > > You need to save the data somewhere. With big uploads like that, > it would be ridiculous for either apache or your app to try and > buffer them in memory. > >> Reading the data once, computing the MD5, caching it and then reusing >> the cached data if the checksum passes is one option, but I dont want >> to do that for a variety of reasons. > > So where do you suppose all that data will be squirreled away > between computing md5 and using it the second time? > libapreq? It'll save variables and spool any uploaded files to disk for your transparently... Issac