how to unimport something

Alex Martelli aleaxit at yahoo.com
Sun Feb 18 06:09:15 EST 2001


"Sean 'Shaleh' Perry" <shaleh at valinux.com> wrote in message
news:mailman.982488021.18367.python-list at python.org...
    [snip]
> It is possible for each step to take as long as a day or two (it could be
given

Then a checkpoint/restart architecture, rather than the ability to unload
code modules (which seems to offer little benefit), would seem to be the
key requirement -- if current goes away after 30 hours, you don't want
to waste all the processing you've already done by having to restart
from scratch.  Each 'restart' will only load the modules it needs, so,
rather than 'unloading', once you have the checkpoint/restart part
perfected, you might want at crucial points to stop 'this' process and
start 'another' one from the checkpoint -- process start/stop times are
NOT going to matter, given your timescale is several hours or more,
even on a heavy-process platform such as Windows or VMS, much less
on Unix.  Suitable for cp/rs might be mmap'ped files, so that the
switchover may actually pay no substantial overhead -- but the key
issue, as always in checkpoint/restart, is to identify the minimal useful
amount of *state* to be saved/reloaded.


Alex






More information about the Python-list mailing list