yada

2021-01-15T12:45:48.004800Z

I'm getting frustrated with the static nature of the routes. I'd like to be able to reload my handler in the REPL and get it picked up by the live server. I'm even okay with restarting the server, but it's a bit galling to need to re-eval the handler, the API routes, the master routes, and then (reset) on the server. I'm contrasting Pedestal's use of the :io.pedestal.server/routes key - it can be a function, which is run on each request. that's not very fast, but it's great for dev mode. it feels like using a Var for the handler in (yada/listener #'routes {:port 3000}) would work great, but looking at the code that just gets deref'd right away, not on every call.

Lu 2021-01-15T12:54:08.005600Z

Just running (reset) should get it all up to date.. I’ve never had this issue..

2021-01-15T12:58:19.005800Z

I'm not using Edge, if that makes a difference. I think it handles this with the component system.

2021-01-15T12:58:37.006Z

my (reset) is simply stopping the old server and starting it again.

borkdude 2021-01-15T13:16:01.006200Z

I'm also using reset to reload the routes

2021-01-15T13:23:33.006400Z

I got it working fairly nicely using clojure.tools.namespace.repl/refresh