Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Detect when a Ruby program exits
James Coglan
1/9/2009 10:28:00 AM
[Note: parts of this message were removed to make it a legal post.]
Hi all,
Is there a way to have your code notified when a Ruby process is terminated?
I'm looking for a way to serialize a bunch of in-memory data to disk
automatically when a Rails app is shut down. I might be better off storing
it in SQLite but would like to know if the in-memory option is possible
first.
Thanks,
James
http://github.c...
2 Answers
LAMBEAU Bernard
1/9/2009 10:37:00 AM
0
Your are probably looking for Kernel::at_exit
blambeau
On Fri, Jan 9, 2009 at 11:28 AM, James Coglan <jcoglan@googlemail.com> wrote:
> Hi all,
>
> Is there a way to have your code notified when a Ruby process is terminated?
> I'm looking for a way to serialize a bunch of in-memory data to disk
> automatically when a Rails app is shut down. I might be better off storing
> it in SQLite but would like to know if the in-memory option is possible
> first.
>
> Thanks,
> James
>
http://github.c...
>
James Coglan
1/9/2009 10:49:00 AM
0
[Note: parts of this message were removed to make it a legal post.]
2009/1/9 LAMBEAU Bernard <blambeau@gmail.com>
> Your are probably looking for Kernel::at_exit
Fantastic, just what I needed. Thanks!
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Detect when a Ruby program exits
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password