[Twisted-Python] Re: How do I get at the Application object (usin g twistd)

Alex Levy mesozoic at polynode.com
Thu Feb 3 10:12:18 EST 2005

On Thu, Feb 03, 2005 at 09:12:30AM -0000, Jeff.Silver at edl.uk.eds.com wrote:
> It looked so elegant just to re-use the shutdown code!

But it's not reliable. If the computer crashes while the server is still
running, you may not be able to save state. If your codebase changes and you
can't unpickle it, or you want to edit configuration on a computer without
Twisted or Python installed, or... you get the idea.

It's better to just write your app-specific configuration to a text file
every N minutes, and then re-read that file on startup. It may not seem as
cool or fun or interesting, but it will save you a lot of headaches in the
long run.

Alex Levy
WWW: http://mesozoic.geecs.org/
"Never let your sense of morals prevent you from doing what is right."
 -- Salvor Hardin, Isaac Asimov's _Foundation_

More information about the Twisted-Python mailing list