Thanks everyone. I might offload some big processes into a separate
process. The background knowledge I've aquired from this thread is
going to help a lot.

I still have no flipping idea how to use heapy though!

On Apr 9, 12:30 am, Malcolm Tredinnick <malc...@pointy-stick.com>
wrote:
> On Wed, 2009-04-08 at 08:43 +0100, Andy Baker wrote:
> > Wow! So Python will eat RAM until restarted? That changes the way I am
> > thinking about this problem.
>
> Well, that's not really accurate, as you realise further down. The
> maximum amount of RAM used will not decrease. However, it won't increase
> without bound unless you actually require using a larger simultaneous
> amount.
>
> [...]
>
> > So my memory usage will always statistically converge on:
> > (Amount of RAM used by most expensive request) x (Maximum simultaneous
> > Django processes)
>
> Providing the most expensive request is likely to frequently. In many
> cases, the most expensive request could well be an outlier that only
> happens infrequently. Statistically infrequent events are a smaller
> concern, since they'll happen less than once, on average, between
> process restarts.
>
>
>
> > and nothing I do with within Django itself can reduce this.
>
> That's correct. It's not a really bad thing, since, as I mentioned, it's
> completely normal Unix process behaviour. And webservers already account
> for that with settings like the maximum number of requests per child.
> It's also one of the arguments for using multiple threads instead of
> multiple processes sometimes (the memory allocator operates on a
> per-process granularity, so can be shared between threads).
>
> Definitely something to take into consideration, but it's manageable.
>
> Regards,
> Malcolm
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to