[Seaside] Re: Saving the Image

seaside at blit.ca seaside at blit.ca
Thu Jun 10 18:13:27 CEST 2004


In article <7B903379-B45A-11D8-AC56-000A95DB7844 at beta4.com> you write:
>On Jun 1, 2004, at 10:29 PM, Chris Reuter wrote:
>> Is it safe to just call SystemDictionary>>snapshot:andQuit: in the
>> callback and/or a looping process or is this going to cause problems?

>I've done this lots of times and never had a problem.  I've never 
>thought too hard about *why* it works, but thinking about it now, it 
>seems like all that would happen on startup is that you would resume 
>halfway through processing a long-gone request, try to give it a 
>response and find that the socket was invalid; that process would then 
>throw an exception and die silently.  Should be just fine.

Okay, thanks.

I've got the code working and tested now and everything seems to be
okay.  (I found what I thought was a bug caused by leftover
transaction state but it turned out that I'd been doing "save, then
quit" instead of "save and quit", resulting in much forehead
slapping.)

The only problem is that the transaction that triggers the shutdown
doesn't complete, so my web browser complains about a lost connection.
I can live with that, though.  I did look into doing something more
graceful--having the transaction spawn a new process to do the
shutdown--but it was sufficiently non-trivial that I gave up on it as
a waste of effort.

I only mention it here because I'm curious if anyone else has managed
to solve this.



                              --Chris


-- 
Chris Reuter                                                 http://www.blit.ca
"Many people's protestations to the contrary, the 'I' in 'RAID' does not
 actually mean 'biggest, baddest, shiniest, most expensive hardware 
 available'."              --Dave Brown


More information about the Seaside mailing list