At 08:21 AM 3/24/2008, [EMAIL PROTECTED] wrote:
>Message: 7
>Date: Mon, 24 Mar 2008 08:21:52 -0700
>From: "Scott Windsor" <[EMAIL PROTECTED]>
>Subject: Re: [Mongrel] mongrel garbage collection
>To: mongrel-users@rubyforge.org
>Message-ID:
>         <[EMAIL PROTECTED]>
>[snip]
>Right now, my processes aren't gigantic... I'm preparing for a 'worst 
>case'
>scenario when I have a extremely large processes or memory 
>usage.  This can
>easily happen on specific applications such as an image server (using 
>image
>magick) or parsing/creating large xml payloads (a large REST 
>server).  For
>those applications, I may have a large amount of memory used for each
>request, which will increase until the GC is run.
>
>[snip]
>There may be perfectly good reasons to have intermediate object 
>creation
>(good encapsulation, usage of a another library/gem you can't modify, 
>large
>operations that you need to keep atomic).  While ideally you'd fix the
>memory usage problem, this doesn't solve all cases.

Hi Scott,

I hope this somewhat OT post is ok (feedback welcome). I've had memory 
problems with image magick too - even when it runs out of process. On 
certain (rare but reasonably sized) image files it seems to go memory 
haywire, eating too much memory and throwing my app stack into swap.

So I wrote this simple rails plug-in which is very limited in function, 
but does mostly what I needed from an image processor. Notable for your 
issue above, it lets you easily specify limits on how much memory image 
magick is allowed to consume while doing its work (thanks to Ara Howard 
on initial direction on that one). It might be interest to you:

http://www.misuse.org/science/2008/01/30/mojomagick-ruby-image-library-for-imagemagick/

Best,

Steve

_______________________________________________
Mongrel-users mailing list
Mongrel-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/mongrel-users

Reply via email to