Is there any facility for reloading routes in the ...
# http4k
d
Is there any facility for reloading routes in the debugger? Once I have a route set up I can edit its handler, rebuild and reload and see the change, but by default I currently need to restart to install a new route?
s
I’d be curious to learn as it’s not a use case I’ve faced so far. Usually, when running in-memory, restarting is quickly enough, but if there’s a smoother way (or even a REPL-like setup) that’d be worth documenting.
d
It's easy to do with a watch on the FS and a suicide pill/reload, but TBH if you use SunHttp then things should reload really quickly. We could use a watchservice to get that going: https://www.http4k.org/blog/nanoservices/#7_watch_your_fs_for_file_changes