how to hot load a new version rabbitmq source code #9126
-
can I hot load a new version rabbitmq source code when I change some code? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
In general this is not supported. @mkuratczyk may have some tricks up his sleeves, though. |
Beta Was this translation helpful? Give feedback.
-
With the caveat that this is strictly for development purposes, yes, you can, although in some cases it's not sufficient (eg. if you change initialization code of a gen_server process, you will need to restart it after loading the new code). There are multiple ways to achieve that - manually or with erlang_ls: https://github.com/rabbitmq/contribute/wiki/Bazel#hot-code-reloading. Manually, it's mostly about:
I've never seen that terminate RabbitMQ. With erlang_ls, you can have it reload the module on file save in your editor (it's also possible to set it up with just your editor, ultimately it's the same |
Beta Was this translation helpful? Give feedback.
With the caveat that this is strictly for development purposes, yes, you can, although in some cases it's not sufficient (eg. if you change initialization code of a gen_server process, you will need to restart it after loading the new code). There are multiple ways to achieve that - manually or with erlang_ls: https://github.com/rabbitmq/contribute/wiki/Bazel#hot-code-reloading.
Manually, it's mostly about:
-c dbg
with bazel, I don't remember how to do that withmake
)c(module).
from the shellI've never seen that terminate RabbitMQ.
With erlang_ls, you can have it reload the module on file save in your editor (it's also possible to set it up with just…