[Pharo-project] react on low space
bschwab at anest.ufl.edu
Tue Feb 1 13:03:17 CET 2011
#isSpaceLow will be of value only if it is called on some type of event (from the gc?) or polled in some way. When my Dolphin images have crashed due to low space, it has invariably been due to one of two things: (1) early on, improper clean up of ODBC statements; (2) loops over very large numbers of objects serialized from disk without proper attention to #release. Object Arts often insisted that finalization water marks would save the day in such situations; experience tells me otherwise.
As a general rule, I am in favor of having the system leave behind information of how it failed. In the case of low space, one *might* have to settle for knowing when a low-space condition arose; a complete set of callstacks might be helpful, assuming the system can write it under such cirumstances. The computation that goes over the cliff could easily be unrelated to the resource hog that caused the problem.
From: pharo-project-bounces at lists.gforge.inria.fr [pharo-project-bounces at lists.gforge.inria.fr] On Behalf Of Max Leske [maxleske at gmail.com]
Sent: Tuesday, February 01, 2011 6:00 AM
To: pharo-project at lists.gforge.inria.fr
Subject: Re: [Pharo-project] react on low space
I'm bumping this message. I think it's an important question and could help other developers who might have the same problem one day. The low space watcher is cool but if you don't get the chance to actually look at the stack it's pretty useless.
On 30.01.2011, at 13:10, Max Leske wrote:
Is there an easy way to react on low space? Something like:
ifTrue: [ <suspend my process> ]
The reason I'm asking is that I have a background process running that causes a low space condition but I never get around to opening the debugger and the image crashes on me. So for debugging purposes I'd like to periodically check the space that is left or alternatively be notified if low space is signalled.
More information about the Pharo-project