I have a supervised elixir app which I am running like :- MIX_ENV=dev mix run
. Now if I change the code, then how can I restart the app gracefully by not killing it first. (Just like we gracefully restart the supervisord process using HUP)
Asked
Active
Viewed 1,160 times
2

Shubham Sharma
- 175
- 2
- 16
1 Answers
0
the nitty gritty details of the actual code hot swapping you can find in the answer to this question:
Achieving code swapping in Erlang's gen_server
as to how to automate the process of reloading you can have a look at phoenix and how it does the reloading. the summary of it is it uses fs lib to monitor file system changes and invoke a process similar to the one outlined in the answer to the question above.
-
This is a good read but since I am not using gen_server, hence this does not solve my problem – Shubham Sharma Sep 16 '16 at 06:17