You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apreq-dev@httpd.apache.org by Pratik <pr...@gmail.com> on 2008/12/16 13:10:53 UTC

Memory leak with apreq_brigade_fwrite() ?

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

Re: Memory leak with apreq_brigade_fwrite() ?

Posted by Michael Koziarski <mi...@koziarski.com>.
> That is correct.

Awesome, thanks!


-- 
Cheers

Koz

Re: Memory leak with apreq_brigade_fwrite() ?

Posted by Joe Schaefer <jo...@yahoo.com>.


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

> On Tue, Dec 16, 2008 at 1:53 PM, Joe Schaefer
> <jo...@yahoo.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.



      

Re: Memory leak with apreq_brigade_fwrite() ?

Posted by Michael Koziarski <mi...@koziarski.com>.
On Tue, Dec 16, 2008 at 1:53 PM, Joe Schaefer <jo...@yahoo.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

Re: Memory leak with apreq_brigade_fwrite() ?

Posted by Joe Schaefer <jo...@yahoo.com>.
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 <pr...@gmail.com> wrote:

> From: Pratik <pr...@gmail.com>
> Subject: Memory leak with apreq_brigade_fwrite() ?
> To: apreq-dev@httpd.apache.org
> 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