I'm using the file-watchers module to keep an eye on a directory tree and
trigger various actions whenever something changes.  I had an issue where
an exception was thrown, the thread died, and file watching therefore
stopped.  The immediate solution is to wrap a with-handlers around it so it
doesn't end up killing the thread, but this made me wonder if there's an
easy way to do this automatically?

What I'm thinking of is "Create a thread that will do something in a loop.
Ensure that the thread remains running and restart it if it dies for any
reason.  Also, make sure that it runs periodically."  I can think of a
solution involving multiple threads, channels, and polling to ensure that
the 'daemonized' threads are running, but I was wondering if there's a
built-in or existing answer.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-users/CAE8gKofBs75GCQM6FPKF3P3Asbo%3DG%3DACq%2Bg2Z49QOcRT38hRDg%40mail.gmail.com.

Reply via email to