forked from cgrand/enlive
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use dedicated daemon threads for auto-reload logic so that it doesn't prevent orderly JVM shutdown. Also names the thread 'enlive auto-reloader: $ns'. Prior to this patch, `clojure.core/future` was used to run the code that waits for file changes for a ns. `future` puts tasks on the agent-send-off thread pool, which consisits of non-daemon threads. There is no shutdown/stop logic for the auto-reload function, so auto-reload threads will run forever and prevent orderly shutdown of the JVM. Daemon threads don't block JVM shutdown, so this seems like a good place to use them.
- Loading branch information
Showing
1 changed file
with
24 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters