From apreqjonathan72@example.com Mon Dec 15 20:46:00 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 52572 invoked from network); 15 Dec 2008 20:46:00 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 20:46:00 -0000
Received: (qmail 55873 invoked by uid 500); 15 Dec 2008 20:46:12 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 55855 invoked by uid 500); 15 Dec 2008 20:46:12 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 55846 invoked by uid 99); 15 Dec 2008 20:46:12 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 12:46:12 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (nike.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO mail-gx0-f15.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 20:45:57 +0000
Received: by gxk8 with SMTP id 8so2724397gxk.17
        for <jonathan72@example.com>; Mon, 15 Dec 2008 12:45:37 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:mime-version:content-type:content-transfer-encoding
         :content-disposition:x-google-sender-auth;
        bh=/ThZ6q0bZhr5/5tF9YugU9xxRghNtDOX35uFgZBUAwU=;
        b=a3kbxAEqXtYbut5LQJ8No3YDuzeMnXgW146cCPsoAm7xBz11jab+oLGjzj38npKzOp
         HCgMkmxh5wF7Vy8338wqMcuMrGlGjp5Mux39q5Lnc1N8BGMXiCJUZRweZKtmjVaDWShd
         MeZ8eVFHNchD0flo30cgeQajF5Twq1pOcJBo8=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:mime-version:content-type
         :content-transfer-encoding:content-disposition:x-google-sender-auth;
        b=kAb0Kmw4Wi36NIQSPrtel9zp/Hj5GVP/6x0cTdfr91IcszDI8u9yixrSm3DWmBe8/+
         G1o8vNpOX7GAytnmPZOLQRUl2usZQq4TjhWCOPLi4lFF03OZpaMXad0tocQ7Ab9T2jEH
         DFdovZZzOCI5HRLBP/upXGfParw/luCChqK7Y=
Received: by 83.161.120.155 with SMTP id o5mr2946710wff.139.1229373936509;
        Mon, 15 Dec 2008 12:45:36 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Mon, 15 Dec 2008 12:45:36 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 21:45:36 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: jonathan72@example.com
Subject: Questions about apreq_params
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
X-Google-Sender-Auth: eac5a99cf87f2c50
X-Virus-Checked: Checked by ClamAV on apache.org

Hey guys,

first, apologies for messing up the subscribe email!

We've just started using apreq for some apache module development and
it's working out quite nicely.  However we've noticed a few strange
issues.

The first of which is that apreq_params returns NULL if we use the
following as the multipart body:

http://github.com/rails/rails/tree/master/actionpack/test/fixtures/multipart/large_text_file

  apr_table_t *request_body = apreq_params(req, r->pool);
  if (request_body == NULL)
  {
    // we are seeing this
  }


The documentation implies that it never does, which makes me wonder.
Is that just a stale piece of documentation or have we found a bug in
libapreq?  Should we be handling this case in our module or figuring
out a test case for you guys to fix in 2.10?

-- 
Cheers

Koz

From apreqjonathan72@example.com Mon Dec 15 21:42:21 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 96564 invoked from network); 15 Dec 2008 21:42:21 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 21:42:21 -0000
Received: (qmail 30520 invoked by uid 500); 15 Dec 2008 21:42:33 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 30494 invoked by uid 500); 15 Dec 2008 21:42:33 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 30480 invoked by uid 99); 15 Dec 2008 21:42:33 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 13:42:33 -0800
X-ASF-Spam-Status: No, hits=1.2 required=10.0
	tests=SPF_NEUTRAL
X-Spam-Check-By: apache.org
Received-SPF: neutral (nike.apache.org: local policy)
Received: from [83.161.120.155] (HELO EXHUB015-3.exch015.msoutlookonline.net) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 21:42:19 +0000
Received: from philip.hq.rws (83.161.120.155) by smtpx15.msoutlookonline.net
 (83.161.120.155) with Microsoft SMTP Server (TLS) id 8.1.278.0; Mon, 15 Dec
 2008 13:41:54 -0800
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 16:41:53 -0500
From: "Philip M. Gollucci" <jonathan72@example.com>
Organization: P6 Web Applications Inc.
User-Agent: Thunderbird 83.161.120.155 (X11/20080917)
MIME-Version: 1.0
To: Michael Koziarski <jonathan72@example.com>
CC: jonathan72@example.com
Subject: Re: Questions about apreq_params
References: <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
Content-Type: text/plain; charset="ISO-8859-1"; format=flowed
Content-Transfer-Encoding: 7bit
X-Virus-Checked: Checked by ClamAV on apache.org

Michael Koziarski wrote:
> Hey guys,
> 
> first, apologies for messing up the subscribe email!
> 
> We've just started using apreq for some apache module development and
> it's working out quite nicely.  However we've noticed a few strange
> issues.
> 
> The first of which is that apreq_params returns NULL if we use the
> following as the multipart body:
> 
> http://github.com/rails/rails/tree/master/actionpack/test/fixtures/multipart/large_text_file
> 
>   apr_table_t *request_body = apreq_params(req, r->pool);
>   if (request_body == NULL)
>   {
>     // we are seeing this
>   }
> 
> 
> The documentation implies that it never does, which makes me wonder.
> Is that just a stale piece of documentation or have we found a bug in
> libapreq?  Should we be handling this case in our module or figuring
> out a test case for you guys to fix in 2.10?
Clearly the function can return NULL, what documentation do you refer to ?

APREQ_DECLARE(apr_table_t *)apreq_params(apreq_handle_t *req, apr_pool_t *p)
{
     const apr_table_t *args, *body;
     apreq_args(req, &args);
     apreq_body(req, &body);

     if (args != NULL)
         if (body != NULL)
             return apr_table_overlay(p, args, body);
         else
             return apr_table_copy(p, args);
     else
         if (body != NULL)
             return apr_table_copy(p, body);
         else
             return NULL;

}



-- 
------------------------------------------------------------------------
Philip M. Gollucci (jonathan72@example.com) c: 613.365.0671
Consultant - P6M7G8 Inc.  http://p6m7g8.net
Senior System Admin - RideCharge, Inc.  http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.

From apreqjonathan72@example.com Mon Dec 15 21:55:48 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 4193 invoked from network); 15 Dec 2008 21:55:48 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 21:55:48 -0000
Received: (qmail 48090 invoked by uid 500); 15 Dec 2008 21:56:01 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 48064 invoked by uid 500); 15 Dec 2008 21:56:01 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 48055 invoked by uid 99); 15 Dec 2008 21:56:01 -0000
Received: from athena.apache.org (HELO athena.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 13:56:01 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (athena.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO wf-out-1314.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 21:55:40 +0000
Received: by wf-out-1314.google.com with SMTP id 24so2638604wfg.15
        for <jonathan72@example.com>; Mon, 15 Dec 2008 13:55:20 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:cc:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references
         :x-google-sender-auth;
        bh=cOvZyDGZMlJ5SFhMtMBlmrRSdXuS6v1f5EWFWoO5SM8=;
        b=BBSAF2T6RSarfOSk/YqGBOej/mY6H488OO3AMyeJFJuQljPPB38bGKJ7OjgjC87Dru
         M9hPsD2ZOF518ds3/mkQLznW/Ax1SOfW6//6cOZLP6fDIO2iNSodoWziG5JjVyQq5884
         MHjQPKIBSEDtmYdYTNY8za8P5XVwOSXNDZZj4=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references:x-google-sender-auth;
        b=xFOGYdeP12+iIORyN1/8VDgPTGYRYSrPWKG4U0W+HUYkEdOZyQl5Ud/LoxC1sjCt6c
         UWKO5JJaDJOZTus1+3CGfPDXHh81fPdhQDtVyoK9d4gtyjGv4Q+ODx5PLf/ee6G5fzS7
         DWnsA0lESuT8W2yrUDnJnN90nyBkKRkbOVgwg=
Received: by 83.161.120.155 with SMTP id d13mr2967081wfc.196.1229378120596;
        Mon, 15 Dec 2008 13:55:20 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Mon, 15 Dec 2008 13:55:20 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 22:55:20 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: "Philip M. Gollucci" <jonathan72@example.com>
Subject: Re: Questions about apreq_params
Cc: jonathan72@example.com
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
	 <jonathan72@example.com>
X-Google-Sender-Auth: f9f611bab3e417b3
X-Virus-Checked: Checked by ClamAV on apache.org

> Clearly the function can return NULL, what documentation do you refer to ?
>
> APREQ_DECLARE(apr_table_t *)apreq_params(apreq_handle_t *req, apr_pool_t *p)
> {
>    const apr_table_t *args, *body;
>    apreq_args(req, &args);
>    apreq_body(req, &body);
>
>    if (args != NULL)
>        if (body != NULL)
>            return apr_table_overlay(p, args, body);
>        else
>            return apr_table_copy(p, args);
>    else
>        if (body != NULL)
>            return apr_table_copy(p, body);
>        else
>            return NULL;
>
> }

The source doc in 2.08 that I have downloaded locally:

/**
 * Returns a table containing key-value pairs for the full request
 * (args + body).
 *
 * @param req request handle
 * @param p   allocates the returned table.
 *
 * @return table representing all available params; is never NULL.
 */
APREQ_DECLARE(apr_table_t *) apreq_params(apreq_handle_t *req, apr_pool_t *p);




-- 
Cheers

Koz

From apreqjonathan72@example.com Mon Dec 15 22:29:15 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 35261 invoked from network); 15 Dec 2008 22:29:15 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 22:29:15 -0000
Received: (qmail 2684 invoked by uid 500); 15 Dec 2008 22:29:27 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 2563 invoked by uid 500); 15 Dec 2008 22:29:27 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 2554 invoked by uid 99); 15 Dec 2008 22:29:27 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 14:29:27 -0800
X-ASF-Spam-Status: No, hits=1.2 required=10.0
	tests=SPF_NEUTRAL
X-Spam-Check-By: apache.org
Received-SPF: neutral (nike.apache.org: local policy)
Received: from [83.161.120.155] (HELO exhub015-1.exch015.msoutlookonline.net) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 22:29:11 +0000
Received: from philip.hq.rws (83.161.120.155) by smtpx15.msoutlookonline.net
 (83.161.120.155) with Microsoft SMTP Server (TLS) id 8.1.278.0; Mon, 15 Dec
 2008 14:28:48 -0800
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 17:28:47 -0500
From: "Philip M. Gollucci" <jonathan72@example.com>
Organization: P6 Web Applications Inc.
User-Agent: Thunderbird 83.161.120.155 (X11/20080917)
MIME-Version: 1.0
To: Michael Koziarski <jonathan72@example.com>
CC: jonathan72@example.com
Subject: Re: Questions about apreq_params
References: <jonathan72@example.com> <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
Content-Type: text/plain; charset="ISO-8859-1"; format=flowed
Content-Transfer-Encoding: 7bit
X-Virus-Checked: Checked by ClamAV on apache.org

Okay that documentation is both correct an incorrect.

Its a stop gab.  When you give no body and no args, you'll get a NULL, 
but in reality you should never need to do this.  I'll take suggestions 
on how to word that correctly.

--------------------------------------------------------------------------
-AaB03x
Content-Disposition: form-data; name="foo"

bar
--AaB03x
Content-Disposition: form-data; name="file"; filename="file.txt"
Content-Type: text/plain

foo
--AaB03x--
---------------------------------------------------------------------------

In the meantime, I'm not convinced you are using the API quite correctly.

Can you have a look at the code in module/t/c-modules/*
in particular,

	o mod_apreq_request_test.c - basic case
	o mod_apreq_upload_test.c - file uploads

At miniumm, you should be checking the RV code of apreq_args == 
APR_SUCCESS. I'm betting its not that for you and if you decode the 
number to a string you'll find your problem.







-- 
------------------------------------------------------------------------
Philip M. Gollucci (jonathan72@example.com) c: 613.365.0671
Consultant - P6M7G8 Inc.  http://p6m7g8.net
Senior System Admin - RideCharge, Inc.  http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.

From apreqjonathan72@example.com Mon Dec 15 22:37:28 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 38200 invoked from network); 15 Dec 2008 22:37:28 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 22:37:28 -0000
Received: (qmail 10086 invoked by uid 500); 15 Dec 2008 22:37:41 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 10058 invoked by uid 500); 15 Dec 2008 22:37:41 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 10048 invoked by uid 99); 15 Dec 2008 22:37:41 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 14:37:41 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (nike.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO wf-out-1314.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 22:37:26 +0000
Received: by wf-out-1314.google.com with SMTP id 24so2655970wfg.15
        for <jonathan72@example.com>; Mon, 15 Dec 2008 14:37:05 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:cc:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references
         :x-google-sender-auth;
        bh=YHn1fww6C/txzVqmlxTJ8DR3er8aL+/EwN+buyz3G6o=;
        b=nna8vogRL8hyRef3WbYInuJTC5zaM7U2QajrOA/Q/3JqbRi7aAW4V/SwBnlgaO7i1O
         J7DgmcvDQ0D6Ow9rzDa2Xo1Cn3jY3w0V7hLSmOJPzeP0fA5NKud3VB7MDdd00nop4Qwx
         JcDYfwPRzQmhyQCOJcBukDhew0dlKdQo9iuak=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references:x-google-sender-auth;
        b=d/qqN6UM+417qTKgDnQRZLXfA33Vle67xGWahb+ckB/NB4H4c6cq5s0qxnPFsaJKXv
         gDsto51edF7p9AsslEMUzfMhYlFmM+kVwIDHH0BZt7sKot3ePMe1Dx/EJkBKa537th7I
         UWjybyABgdFJqcKAKfm/BM1mI77VFROfmKAMU=
Received: by 83.161.120.155 with SMTP id r11mr2991998wfa.73.1229380625577;
        Mon, 15 Dec 2008 14:37:05 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Mon, 15 Dec 2008 14:37:05 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 23:37:05 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: "Philip M. Gollucci" <jonathan72@example.com>
Subject: Re: Questions about apreq_params
Cc: jonathan72@example.com
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
	 <jonathan72@example.com> <jonathan72@example.com>
X-Google-Sender-Auth: 227bbd61b7628b03
X-Virus-Checked: Checked by ClamAV on apache.org

On Mon, Dec 15, 2008 at 11:28 PM, Philip M. Gollucci
<jonathan72@example.com> wrote:
> Okay that documentation is both correct an incorrect.
>
> Its a stop gab.  When you give no body and no args, you'll get a NULL, but
> in reality you should never need to do this.  I'll take suggestions on how
> to word that correctly.

I'll have a think and get back to you.

> In the meantime, I'm not convinced you are using the API quite correctly.
>
> Can you have a look at the code in module/t/c-modules/*
> in particular,
>
>        o mod_apreq_request_test.c - basic case
>        o mod_apreq_upload_test.c - file uploads
>
> At miniumm, you should be checking the RV code of apreq_args == APR_SUCCESS.
> I'm betting its not that for you and if you decode the number to a string
> you'll find your problem.

My expectation was that I could safely call apreq_params and have that
return the the table of all the parameters in the request.  But
looking at how that function is implemented (discarding the RV codes)
it's not really all that useful.  I believe the test script I was
using was malformed so that's probably what's going on.

So should apreq_params be deprecated given the lack of RV checking?
It seems that it's not possible to use it safely? I can easily
implement that same 'overlay or copy' logic (with error checking)
myself, but this function will probably still trip up the next unlucky
traveller.  Any ideas on a best fix for the library, rather than just
my own module?

-- 
Cheers

Koz

From apreqjonathan72@example.com Mon Dec 15 22:46:42 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 52049 invoked from network); 15 Dec 2008 22:46:42 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 22:46:42 -0000
Received: (qmail 20500 invoked by uid 500); 15 Dec 2008 22:46:54 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 20470 invoked by uid 500); 15 Dec 2008 22:46:54 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 20461 invoked by uid 99); 15 Dec 2008 22:46:54 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 14:46:54 -0800
X-ASF-Spam-Status: No, hits=1.2 required=10.0
	tests=SPF_NEUTRAL
X-Spam-Check-By: apache.org
Received-SPF: neutral (nike.apache.org: local policy)
Received: from [83.161.120.155] (HELO EXHUB015-3.exch015.msoutlookonline.net) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 22:46:40 +0000
Received: from philip.hq.rws (83.161.120.155) by smtpx15.msoutlookonline.net
 (83.161.120.155) with Microsoft SMTP Server (TLS) id 8.1.278.0; Mon, 15 Dec
 2008 14:46:18 -0800
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 17:46:17 -0500
From: "Philip M. Gollucci" <jonathan72@example.com>
Organization: P6 Web Applications Inc.
User-Agent: Thunderbird 83.161.120.155 (X11/20080917)
MIME-Version: 1.0
To: Michael Koziarski <jonathan72@example.com>
CC: jonathan72@example.com
Subject: Re: Questions about apreq_params
References: <jonathan72@example.com>	 <jonathan72@example.com> <jonathan72@example.com> <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
Content-Type: text/plain; charset="ISO-8859-1"; format=flowed
Content-Transfer-Encoding: 7bit
X-Virus-Checked: Checked by ClamAV on apache.org

Michael Koziarski wrote:
> So should apreq_params be deprecated given the lack of RV checking?
> It seems that it's not possible to use it safely? I can easily
> implement that same 'overlay or copy' logic (with error checking)
> myself, but this function will probably still trip up the next unlucky
> traveller.  Any ideas on a best fix for the library, rather than just
> my own module?
It should definitely not be deprecated.  Its kind of 'core' to the module.



-- 
------------------------------------------------------------------------
Philip M. Gollucci (jonathan72@example.com) c: 613.365.0671
Consultant - P6M7G8 Inc.  http://p6m7g8.net
Senior System Admin - RideCharge, Inc.  http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.

From apreqjonathan72@example.com Mon Dec 15 23:01:04 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 71029 invoked from network); 15 Dec 2008 23:01:04 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 23:01:04 -0000
Received: (qmail 41954 invoked by uid 500); 15 Dec 2008 23:01:16 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 41935 invoked by uid 500); 15 Dec 2008 23:01:16 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 41926 invoked by uid 99); 15 Dec 2008 23:01:16 -0000
Received: from athena.apache.org (HELO athena.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 15:01:16 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (athena.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO yw-out-1718.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 23:00:56 +0000
Received: by yw-out-1718.google.com with SMTP id 6so1234638ywa.84
        for <jonathan72@example.com>; Mon, 15 Dec 2008 15:00:35 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:cc:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references
         :x-google-sender-auth;
        bh=KwFpjRSf0yR1kVELg+nGsiZxne3UKTT9rTdhgQGYKSI=;
        b=W44Rz6dvsSksLx9OejntYY4BxtKdBhEFFR9WeQD0yFqyZ7LUpb1lhXAbBwbXQkLqcO
         x3EyD5HkUWDcQ26sFp4NxKff9wxTmBM8pBd2ZGiN7piCqjI43bxakAxq6bN35MCSURlq
         IeZGBiCY8iALrakhouEoC9UORtFM9MXgzh5lo=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references:x-google-sender-auth;
        b=izRVQt6wCdN89lfJvWy/3ZZlgJF1AvN1oniTXl+GbGec0WneLghyi9NYIj3w/E1x/m
         /I/TAGdnVa/PdVrqfCHM7k2Y9vRfzGsA6S1YtszkRAjplITVNE5aSTC7S/T6eLJdZljl
         HH3mYuGzA9bSy4WG8SuWK15KFc+o5TjBtB1+I=
Received: by 83.161.120.155 with SMTP id v14mr2986905wfe.274.1229382035134;
        Mon, 15 Dec 2008 15:00:35 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Mon, 15 Dec 2008 15:00:35 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Tue, 16 Dec 2008 00:00:35 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: "Philip M. Gollucci" <jonathan72@example.com>
Subject: Re: Questions about apreq_params
Cc: jonathan72@example.com
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
	 <jonathan72@example.com> <jonathan72@example.com>
	 <jonathan72@example.com>
	 <jonathan72@example.com>
X-Google-Sender-Auth: d3f7b6aa9f4c40c0
X-Virus-Checked: Checked by ClamAV on apache.org

> It should definitely not be deprecated.  Its kind of 'core' to the module.

But unless I'm mistaken, it'll just silently fail in these situations
with malformed bodies?  What would be the suggested action in that
situation?  something like this?

if (content_body == NULL)
{
   // try apreq_args and log the failure
   // try apreq_body and log the failure
}

At present we're just treating these as Bad Requests?

-- 
Cheers

Koz

From apreqjonathan72@example.com Mon Dec 15 23:16:18 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 83297 invoked from network); 15 Dec 2008 23:16:17 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 15 Dec 2008 23:16:17 -0000
Received: (qmail 67055 invoked by uid 500); 15 Dec 2008 23:16:29 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 66894 invoked by uid 500); 15 Dec 2008 23:16:28 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 66684 invoked by uid 99); 15 Dec 2008 23:16:27 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 15:16:26 -0800
X-ASF-Spam-Status: No, hits=1.2 required=10.0
	tests=SPF_NEUTRAL
X-Spam-Check-By: apache.org
Received-SPF: neutral (nike.apache.org: local policy)
Received: from [83.161.120.155] (HELO EXHUB015-3.exch015.msoutlookonline.net) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Dec 2008 23:16:12 +0000
Received: from philip.hq.rws (83.161.120.155) by smtpx15.msoutlookonline.net
 (83.161.120.155) with Microsoft SMTP Server (TLS) id 8.1.278.0; Mon, 15 Dec
 2008 15:15:50 -0800
Message-ID: <jonathan72@example.com>
Date: Mon, 15 Dec 2008 18:15:49 -0500
From: "Philip M. Gollucci" <jonathan72@example.com>
Organization: P6 Web Applications Inc.
User-Agent: Thunderbird 83.161.120.155 (X11/20080917)
MIME-Version: 1.0
To: Michael Koziarski <jonathan72@example.com>
CC: jonathan72@example.com
Subject: Re: Questions about apreq_params
References: <jonathan72@example.com>	 <jonathan72@example.com> <jonathan72@example.com>	 <jonathan72@example.com>	 <jonathan72@example.com> <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
Content-Type: text/plain; charset="ISO-8859-1"; format=flowed
Content-Transfer-Encoding: 7bit
X-Virus-Checked: Checked by ClamAV on apache.org

Michael Koziarski wrote:
>> It should definitely not be deprecated.  Its kind of 'core' to the module.
> 
> But unless I'm mistaken, it'll just silently fail in these situations
> with malformed bodies?  What would be the suggested action in that
> situation?  something like this?
I think step one is to come up with a test that reproduces the break in 
the docs.  Commit it as 'skip', then fix the code so the test passes 
ensuring we don't break anything else in the process.

-- 
------------------------------------------------------------------------
Philip M. Gollucci (jonathan72@example.com) c: 613.365.0671
Consultant - P6M7G8 Inc.  http://p6m7g8.net
Senior System Admin - RideCharge, Inc.  http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.

From apreqjonathan72@example.com Tue Dec 16 12:11:24 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 14632 invoked from network); 16 Dec 2008 12:11:24 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 16 Dec 2008 12:11:24 -0000
Received: (qmail 3459 invoked by uid 500); 16 Dec 2008 12:11:30 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 3435 invoked by uid 500); 16 Dec 2008 12:11:29 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 3393 invoked by uid 99); 16 Dec 2008 12:11:29 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 04:11:29 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (nike.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO mail-bw0-f13.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 12:11:13 +0000
Received: by bwz6 with SMTP id 6so558815bwz.0
        for <jonathan72@example.com>; Tue, 16 Dec 2008 04:10:53 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:to
         :subject:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references;
        bh=u9TzuhwDDyBYx0Enk3aHOmM/kdPWIEvRq0LXeqB3gmc=;
        b=AuCwUiL0Z9zBKUbw1YIxumw3QdBx3dZK1PAVcdmyFoWLjCc9xmv4BltxCMCxHy49Re
         HaJtEKHb/1hvgBzIudOnZ69WEb34lHxqpA33tf8+3Ghv+4eciK3vgyh9zupD6hc1Tfg4
         vOW96tIxRyfv2zfC/+Xk1wZhThA59/uzxClZ8=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:to:subject:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references;
        b=tX8zDeZIFV0C8uLxfQyFYTh+3HolkR49UZkq9PRzBXyNu0gcVMeOU9omcPNU9ldH02
         ZlD/8XK2448mV3tt4qJXjgjGNRCJysWl2eSokul7ADzw9ZKwPIs7hgsP6QGerg0gqCow
         RytFyTsQ2Mw+6Q0hUQE8RI/fGk1P7urtTQivU=
Received: by 83.161.120.155 with SMTP id q20mr2918094bkn.209.1229429453211;
        Tue, 16 Dec 2008 04:10:53 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Tue, 16 Dec 2008 04:10:53 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Tue, 16 Dec 2008 12:10:53 +0000
From: Pratik <jonathan72@example.com>
To: jonathan72@example.com
Subject: Memory leak with apreq_brigade_fwrite() ?
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
X-Virus-Checked: Checked by ClamAV on apache.org

Hi all,

I was going through the docs of RC1/trunk and for
apreq_brigade_fwrite(), docs have the following remark :

    @remarks This function leaks a bucket brigade into bb->p whenever
the final bucket in bb is a spool bucket.

Is this still the case ? We're using apreq_brigade_fwrite() inside our
module and I can see the memory usage rising slightly every time I
upload a file larger than any of the previously uploaded files.

Any suggestions/work around ?

-- 
Cheers!
- Pratik
http://m.onkey.org

From apreqjonathan72@example.com Tue Dec 16 12:53:57 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 29920 invoked from network); 16 Dec 2008 12:53:57 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 16 Dec 2008 12:53:57 -0000
Received: (qmail 55829 invoked by uid 500); 16 Dec 2008 12:54:10 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 55710 invoked by uid 500); 16 Dec 2008 12:54:10 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 55701 invoked by uid 99); 16 Dec 2008 12:54:10 -0000
Received: from athena.apache.org (HELO athena.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 04:54:10 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (athena.apache.org: local policy)
Received: from [83.161.120.155] (HELO web54401.mail.yahoo.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with SMTP; Tue, 16 Dec 2008 12:53:48 +0000
Received: (qmail 1153 invoked by uid 60001); 16 Dec 2008 12:53:26 -0000
DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws;
  s=s1024; d=yahoo.com;
  h=X-YMail-OSG:Received:X-Mailer:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type:Message-ID;
  b=rdzK70s7fqB/90gTaSHFCLGr3SCYvT1sognxPzAIF4aL1CXytHJwC6LiTzpm6mXyPFsq5EMPDM7qgQLonqThJWQjvHaKua4EzW8BPIY6hpI/LjbmyMklk4210LfAsgkObQ4e93TdFh05N2pHn/xEy5ceG3VlHKhO42hrEV9dDr8=;
X-YMail-OSG: x5y0L3MVM1mQXWkJHlvKB3rxakBBSIa8tLo9mXWJzcvMUBRBmh5xg5p5KcAeYe3dtGNqugI51vvsTzTY3yYOyArzqfU9q2j9EPvW1Uibej_3ucJtig7jpboHHE63FGp5NfcXoSeJEl1PDea8xDES7okv.2fq5zpf4LnXVDW_Z1VZkV6Q0X2Lx4rlbD2_WLYqP6nb2z8iFOps6Xrxh74TRyekH4za
Received: from [83.161.120.155] by web54401.mail.yahoo.com via HTTP; Tue, 16 Dec 2008 04:53:26 PST
X-Mailer: YahooMailWebService/0.7.260.1
Date: Tue, 16 Dec 2008 04:53:26 -0800 (PST)
From: Joe Schaefer <jonathan72@example.com>
Reply-To: jonathan72@example.com
Subject: Re: Memory leak with apreq_brigade_fwrite() ?
To: jonathan72@example.com, Pratik <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Message-ID: <jonathan72@example.com>
X-Virus-Checked: Checked by ClamAV on apache.org

The "leak" of a bucket brigade into the pool shouldn't be
noticable.  The problem with all previous releases is that
apreq_brigade_fwrite would leak badly when dealing with
spool buckets- the current RC/trunk should fix that problem.


--- On Tue, 12/16/08, Pratik <jonathan72@example.com> wrote:

> From: Pratik <jonathan72@example.com>
> Subject: Memory leak with apreq_brigade_fwrite() ?
> To: jonathan72@example.com
> Date: Tuesday, December 16, 2008, 7:10 AM
> Hi all,
> 
> I was going through the docs of RC1/trunk and for
> apreq_brigade_fwrite(), docs have the following remark :
> 
>     @remarks This function leaks a bucket brigade into
> bb->p whenever
> the final bucket in bb is a spool bucket.
> 
> Is this still the case ? We're using
> apreq_brigade_fwrite() inside our
> module and I can see the memory usage rising slightly every
> time I
> upload a file larger than any of the previously uploaded
> files.
> 
> Any suggestions/work around ?
> 
> -- 
> Cheers!
> - Pratik
> http://m.onkey.org


      

From apreqjonathan72@example.com Tue Dec 16 14:10:23 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 79272 invoked from network); 16 Dec 2008 14:10:23 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 16 Dec 2008 14:10:23 -0000
Received: (qmail 74467 invoked by uid 500); 16 Dec 2008 14:10:34 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 74451 invoked by uid 500); 16 Dec 2008 14:10:34 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 74442 invoked by uid 99); 16 Dec 2008 14:10:34 -0000
Received: from athena.apache.org (HELO athena.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 06:10:34 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (athena.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO yw-out-1718.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 14:10:14 +0000
Received: by yw-out-1718.google.com with SMTP id 6so1328437ywa.84
        for <jonathan72@example.com>; Tue, 16 Dec 2008 06:09:53 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:cc:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references
         :x-google-sender-auth;
        bh=Q6dg/279kLFGCGXzjVfKYVSEoEc4+qsQB7frd3fe5SA=;
        b=QGPPkhlCYdrMHODBPvuU2O3l0eaxGun4t3B6AqcR+TiKByteNqlnAkIiLSdPfHcpzQ
         ftneCpK7RlnhOSoU6noUCH75RS7ijARR33uFlFtBwqOYbJPJSBTI3QBVoaS5H112xHi6
         BYxAFsc0mm76OdQ/DcS6uGSH54adVTAehX1Sk=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references:x-google-sender-auth;
        b=i7ZG1OP/kGhzGT9XHheKMVc4Ub8nOOjlb2Byfz0eeHdas64tz1okfPAQZLaL0Jby+t
         S0AopzKlTZy2IK6hl/hEQICmnBS3bSKcZXzR3WJyVOYJzN9+YTPJDlwEY2vw3VvgkovJ
         uYWN8mtoOL4C0p8XPMV7LgaRFPNHDgInwEb2E=
Received: by 83.161.120.155 with SMTP id i8mr369266wfg.192.1229436592847;
        Tue, 16 Dec 2008 06:09:52 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Tue, 16 Dec 2008 06:09:52 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Tue, 16 Dec 2008 15:09:52 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: jonathan72@example.com
Subject: Re: Memory leak with apreq_brigade_fwrite() ?
Cc: jonathan72@example.com, Pratik <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
	 <jonathan72@example.com>
X-Google-Sender-Auth: 404bded7186295b6
X-Virus-Checked: Checked by ClamAV on apache.org

On Tue, Dec 16, 2008 at 1:53 PM, Joe Schaefer <jonathan72@example.com> wrote:
> The "leak" of a bucket brigade into the pool shouldn't be
> noticable.  The problem with all previous releases is that
> apreq_brigade_fwrite would leak badly when dealing with
> spool buckets- the current RC/trunk should fix that problem.

yeah, we definitely noticed the leak in in 2.08.  With 2.10RC we're
still seeing a very very minor increase in the memory usage of our
apache works, but it could well just be white noise that we're
noticing because of that leak reference in the docs.

So am I correct in understanding that that bucket is only 'leaked' in
the sense that it's no longer needed, it's still cleaned up when the
pool cleans up?

-- 
Cheers

Koz

From apreqjonathan72@example.com Tue Dec 16 14:11:18 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 79749 invoked from network); 16 Dec 2008 14:11:18 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 16 Dec 2008 14:11:18 -0000
Received: (qmail 74692 invoked by uid 500); 16 Dec 2008 14:11:30 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 74674 invoked by uid 500); 16 Dec 2008 14:11:30 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 74665 invoked by uid 99); 16 Dec 2008 14:11:30 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 06:11:30 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (nike.apache.org: local policy)
Received: from [83.161.120.155] (HELO web54404.mail.yahoo.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with SMTP; Tue, 16 Dec 2008 14:11:16 +0000
Received: (qmail 34407 invoked by uid 60001); 16 Dec 2008 14:10:54 -0000
DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws;
  s=s1024; d=yahoo.com;
  h=X-YMail-OSG:Received:X-Mailer:Date:From:Reply-To:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Message-ID;
  b=K5+Hb8mFyO29Rg7R5BwAFoETZXcs7DTEyk78ClUDx8tWVwaEcZDtPgBQL7pgjybKsMf99jPblwyc6qRpvKRrQmaXns5nNckRlyMqdXSmuDPN+gpd6g1Z94gYUX/40WRc6c+kWhdRI6P2YPPrTyKclbpaQ9WwehmyTmJc8/SwX5E=;
X-YMail-OSG: tGLGU9gVM1nbyukhc5tdEPhdDoGtlM_eZZln76q6Tm1.oP_HtgwikVDrfTBd5XY18EL.gEUluGapPTLz7zQT.qDyMuADrp7d8dXffXwXh3pQyNy06kHC62IdO7JayO.DUcjWyhoC.sV91cTKt77pQyKWDBD3GrPxUYhaH2DNqj8J9Yg8KY.K809LMUCQri8ZxONBHEQCbkLECOc-
Received: from [83.161.120.155] by web54404.mail.yahoo.com via HTTP; Tue, 16 Dec 2008 06:10:54 PST
X-Mailer: YahooMailWebService/0.7.260.1
Date: Tue, 16 Dec 2008 06:10:54 -0800 (PST)
From: Joe Schaefer <jonathan72@example.com>
Reply-To: jonathan72@example.com
Subject: Re: Memory leak with apreq_brigade_fwrite() ?
To: Michael Koziarski <jonathan72@example.com>
Cc: jonathan72@example.com, Pratik <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Message-ID: <jonathan72@example.com>
X-Virus-Checked: Checked by ClamAV on apache.org




--- On Tue, 12/16/08, Michael Koziarski <jonathan72@example.com> wrote:

> On Tue, Dec 16, 2008 at 1:53 PM, Joe Schaefer
> <jonathan72@example.com> wrote:
> > The "leak" of a bucket brigade into the pool
> shouldn't be
> > noticable.  The problem with all previous releases is
> that
> > apreq_brigade_fwrite would leak badly when dealing
> with
> > spool buckets- the current RC/trunk should fix that
> problem.
> 
> yeah, we definitely noticed the leak in in 2.08.  With
> 2.10RC we're
> still seeing a very very minor increase in the memory usage
> of our
> apache works, but it could well just be white noise that
> we're
> noticing because of that leak reference in the docs.
> 
> So am I correct in understanding that that bucket is only
> 'leaked' in
> the sense that it's no longer needed, it's still
> cleaned up when the
> pool cleans up?

That is correct.



      

From apreqjonathan72@example.com Tue Dec 16 14:12:00 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 80196 invoked from network); 16 Dec 2008 14:12:00 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 16 Dec 2008 14:12:00 -0000
Received: (qmail 75088 invoked by uid 500); 16 Dec 2008 14:12:13 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 74965 invoked by uid 500); 16 Dec 2008 14:12:13 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 74956 invoked by uid 99); 16 Dec 2008 14:12:13 -0000
Received: from nike.apache.org (HELO nike.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 06:12:13 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (nike.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO wf-out-1314.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 14:11:58 +0000
Received: by wf-out-1314.google.com with SMTP id 24so2983132wfg.15
        for <jonathan72@example.com>; Tue, 16 Dec 2008 06:11:37 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:cc:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references
         :x-google-sender-auth;
        bh=+FaLCKdI3Q/blT9KF7hpD0cdubAOfu+fdSILVoESg2Q=;
        b=ta/tmTkX3IJ85/3leDDOHFXRATWkUVRNCz++/2FiaX9Bf5o/i1MjkzeqgcF6H12MaJ
         nLtNjLtpozjFU/lOHM/qLGuDYIqePNweEJOmwNLqnB49bbPMZgg4xTynzzSwBABcvrIC
         dZjf2cSgVQJB1aRkTtd8rVb3ysns5O2Xee+qw=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references:x-google-sender-auth;
        b=ZMWaLEjP6MinaVYb8cXsRjOsw0++15wX8rlQTgsjkvrkqxz/mktegeFp4UXGQZa4Ii
         iA/ZeOeP+k4ftLy978ihQu5Uuu77veFzxsHVKrUshEFRLwJLhwBnYccSyUlPevHcmHk5
         R3uX6SyhvMAot2VcIRCbeKcMtGS37qpHgn8r8=
Received: by 83.161.120.155 with SMTP id z5mr3306781wfb.334.1229436697007;
        Tue, 16 Dec 2008 06:11:37 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Tue, 16 Dec 2008 06:11:36 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Tue, 16 Dec 2008 15:11:36 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: jonathan72@example.com
Subject: Re: Memory leak with apreq_brigade_fwrite() ?
Cc: jonathan72@example.com, Pratik <jonathan72@example.com>
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
	 <jonathan72@example.com>
X-Google-Sender-Auth: 49a91febcfd9ae35
X-Virus-Checked: Checked by ClamAV on apache.org

> That is correct.

Awesome, thanks!


-- 
Cheers

Koz

From apreqjonathan72@example.com Tue Dec 16 14:15:09 2008
Return-Path: <apreqjonathan72@example.com>
Delivered-To: jonathan72@example.com
Received: (qmail 81716 invoked from network); 16 Dec 2008 14:15:09 -0000
Received: from hermes.apache.org (HELO mail.apache.org) (83.161.120.155)
  by minotaur.apache.org with SMTP; 16 Dec 2008 14:15:09 -0000
Received: (qmail 81171 invoked by uid 500); 16 Dec 2008 14:15:22 -0000
Delivered-To: jonathan72@example.com
Received: (qmail 81144 invoked by uid 500); 16 Dec 2008 14:15:22 -0000
Mailing-List: contact jonathan72@example.com; run by ezmlm
Precedence: bulk
List-Post: <mailto:jonathan72@example.com>
List-Help: <mailto:jonathan72@example.com>
List-Unsubscribe: <mailto:jonathan72@example.com>
List-Id: <apreq-dev.httpd.apache.org>
Delivered-To: mailing list jonathan72@example.com
Received: (qmail 81135 invoked by uid 99); 16 Dec 2008 14:15:22 -0000
Received: from athena.apache.org (HELO athena.apache.org) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 06:15:22 -0800
X-ASF-Spam-Status: No, hits=-0.0 required=10.0
	tests=SPF_PASS
X-Spam-Check-By: apache.org
Received-SPF: pass (athena.apache.org: domain of jonathan72@example.com designates 83.161.120.155 as permitted sender)
Received: from [83.161.120.155] (HELO wf-out-1314.google.com) (83.161.120.155)
    by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Dec 2008 14:15:00 +0000
Received: by wf-out-1314.google.com with SMTP id 24so2984349wfg.15
        for <jonathan72@example.com>; Tue, 16 Dec 2008 06:14:40 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from:sender
         :to:subject:cc:in-reply-to:mime-version:content-type
         :content-transfer-encoding:content-disposition:references
         :x-google-sender-auth;
        bh=dUmcctvdoTqKrv49LpD/R6+szf6av7fuua7Dg1lU9hg=;
        b=G1E/Ajl7gMKuk1m+AfED0GGJ6QkITV+6s+ws21khcE+RtW1jpdZVUElAaQenZ0CshU
         QPtICpswEddJYuMr11PQFq+aTEb2q/+vhIFtKFI/WvMQ6H9uLfPKPcc3M4WkpTME9j8E
         vj7cRbnsjIVK9fDpysJalKqKguCq7iLHYpqRM=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version
         :content-type:content-transfer-encoding:content-disposition
         :references:x-google-sender-auth;
        b=LjkUfz3XkJJIvtwK6rqzIR3QhlVUAuRIMco4n2P2cGSXeItRVD6Yh5ZubG2Su2YurN
         gFlye32geBVRJStkdAM5LtjEQ6yBy9gviJWfwxrsOJFqmMBe+KhptGw137DC4zXz9Y1U
         ojT5cJtcLguiIARGFyZinvb8Tjs5AvNM69pVQ=
Received: by 83.161.120.155 with SMTP id 20mr3323154wfn.79.1229436880385;
        Tue, 16 Dec 2008 06:14:40 -0800 (PST)
Received: by 83.161.120.155 with HTTP; Tue, 16 Dec 2008 06:14:40 -0800 (PST)
Message-ID: <jonathan72@example.com>
Date: Tue, 16 Dec 2008 15:14:40 +0100
From: "Michael Koziarski" <jonathan72@example.com>
Sender: jonathan72@example.com
To: "Philip M. Gollucci" <jonathan72@example.com>
Subject: Re: Questions about apreq_params
Cc: jonathan72@example.com
In-Reply-To: <jonathan72@example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <jonathan72@example.com>
	 <jonathan72@example.com> <jonathan72@example.com>
	 <jonathan72@example.com>
	 <jonathan72@example.com>
	 <jonathan72@example.com>
	 <jonathan72@example.com>
X-Google-Sender-Auth: 8bd212e196d49f4a
X-Virus-Checked: Checked by ClamAV on apache.org

On Tue, Dec 16, 2008 at 12:15 AM, Philip M. Gollucci
<jonathan72@example.com> wrote:
> Michael Koziarski wrote:
>>>
>>> It should definitely not be deprecated.  Its kind of 'core' to the
>>> module.
>>
>> But unless I'm mistaken, it'll just silently fail in these situations
>> with malformed bodies?  What would be the suggested action in that
>> situation?  something like this?
>
> I think step one is to come up with a test that reproduces the break in the
> docs.  Commit it as 'skip', then fix the code so the test passes ensuring we
> don't break anything else in the process.

OK, I'm about to spend a week travelling but I've added this to my
TODO list.  I'm far from an expert with this stuff so apologies if it
takes me a little while.  At the very least I'll get us a request body
which repeatedly triggers it.

> --
> ------------------------------------------------------------------------
> Philip M. Gollucci (jonathan72@example.com) c: 613.365.0671
> Consultant - P6M7G8 Inc.  http://p6m7g8.net
> Senior System Admin - RideCharge, Inc.  http://ridecharge.com
> 1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C
>
> Work like you don't need the money,
> love like you'll never get hurt,
> and dance like nobody's watching.
>



-- 
Cheers

Koz


{'source': 'Apache Software Foundation Public Mail Archives'}