Hi! does anyone know if there an equivilent to lein ring
for CLI tools ?
I never used lein ring
back when I was using Leiningen anyway.
I just start my HTTP server in my -main
function and used to lein run
-- which is now clojure -m my.entry.point
@mgrbyte What do you actually rely on lein ring
for?
Hi, sorry for the delay in reply (long weekend away).
Using lein ring for starting a ring service (jetty-adapter under the hood i guess), with the init
and handler
hooks (creating the db connection in init
).
Currently using mount
.
I'm guessing I could remove the use of lein ring
just by doing mount/start
before jetty-adapter
in main, then handling db connectivity in some mw :thinking_face:
That sounds simpler -- less "magic" via plugins.
We use Component anyway so our HTTP server is wrapped up with a start
/ stop
lifecycle anyway, which makes it really easy to work with from the REPL.