|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
On Fri, Jun 27, 2003 at 06:05:04AM -0400, Eric J. Roode wrote:
> I am developing a long-running process that will handle many disparate
> things, so I don't want to shut it down unless absolutely necessary.
> It will use OO modules written by other programmers, which may be in a
> development state. I would like for my program to detect when any of
> its included modules change, and then re-load that module (and its
> dependencies, if any).
>
> When I unload and reload, I will not be keeping any data structures
> from the module around, so I don't have to worry about (for example)
> the module's internal state or representation changing -- it will be
> a clean start.
Fork and exec, maybe with a pipe between them, is a very clean way to
do this (if you can). It has other advantages: a bad module (or module
upgrade) can't affect your long-running process.
Mon does it this way, for example.
--
Jeff
Jeff Abrahamson <http://www.purple.com/jeff/>
GPG fingerprint: 1A1A BA95 D082 A558 A276 63C6 16BF 8C4C 0D1D AE4B
-
**Majordomo list services provided by PANIX <URL:http://www.panix.com>**
**To Unsubscribe, send "unsubscribe phl" to majordomo@lists.pm.org**
|
|