<div class="gmail_quote">On Wed, Apr 6, 2011 at 9:30 AM, Tim Allen <span dir="ltr">&lt;<a href="mailto:screwtape@froup.com">screwtape@froup.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im">On Wed, Apr 06, 2011 at 10:16:03AM +0300, anatoly techtonik wrote:<br>
&gt; From <a href="http://twistedmatrix.com/documents/current/core/howto/udp.html" target="_blank">http://twistedmatrix.com/documents/current/core/howto/udp.html</a><br>
&gt;<br>
&gt; &quot;&quot;&quot;As you can see, the protocol is registered with the reactor. This means it<br>
&gt; may be persisted if it&#39;s added to an application...&quot;&quot;&quot;<br>
&gt;<br>
&gt; What does &#39;persisted` here mean?<br>
<br>
</div>At some point in the past, somebody decided it would be a great idea to<br>
have Twisted&#39;s &quot;twistd&quot; start applications from Python pickles; you<br>
could start up a server, configure it interactively, and when you shut<br>
it down the entire server state would be persisted in a pickle-file;<br>
when you started it up it would resume exactly as it had been when you<br>
shut it down.<br></blockquote><div><br>Whoa hang on. Without trying to hijack the thread, this is the entire premise of infobarb, the IRC bot I&#39;m building for #python-*, except s/pickle/sqlite/, so if this is a horrible idea I&#39;d like to know before I build it. <br>

</div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
The idea seems to have fallen from grace, possibly because restarting<br>
a process is often the simplest way to resolve a production problem.<br>
These days, new Twisted users are encouraged to use Python &quot;.tac&quot; files<br>
rather than &quot;.tap&quot; pickles, and I expect that sentence is just a relic<br>
of that bygone era.<br></blockquote><div><br>I suppose the problem you&#39;re suggesting is that the pickle is in a state where running the server is impossible: do you mean like the pickle is corrupted, or pickle has a bunch of settings that just can&#39;t work... ?<br>

 <br>Would this problem be fixed by implementing features like differential snapshots? Maybe a replayable or reverse-replayable event log?<br><br></div></div>cheers<div>lvh</div><br>