Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best practice running a Clojure background process on windows

I've got a process that will constantly run in the background, update a database, then the results can be checked in a noir based web app.

I'm currently running on windows. The currently runs as a local java process, however I'm wondering what the best practice is currently with Clojure running a background process.

I've got two possible thoughts

1 - Run the application as a local service. However I'm not sure what the best route for achieving this is on windows in the Java/Clojure world.

2 - Run and control the background process in something like Tomcat and make it is part of some sort of background process, separate from the users session. If this is viable, can anyone provide any guidance on what i should investigate to achieve this?

like image 227
Dale Avatar asked Jan 23 '26 12:01

Dale


1 Answers

Unless your process/service needs some special libraries, processing or security handling provided by tomcat, most of the time it is not worth the overhead.

Just use a java service wrapper for windows (here is how to use one: http://edn.embarcadero.com/article/32068) and you should be all set.

Note that the configuration for the service hanlder is also supporting unix so that you are portable too.!

like image 183
Nicolas Modrzyk Avatar answered Jan 27 '26 00:01

Nicolas Modrzyk



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!