How do I find erlang processes lingering in legacy code?

Using Erlang's code modification capabilities, sometimes I got the wrong code: soft_purge (module), which means that some other process is still hanging on the old code. Is there a way to find these processes? Of course, there is a bug in my case, and in order to track it I need to know which process is being delayed in the old code.

Any help is appreciated, thanks in advance.

+3


source to share


1 answer


You can use check_process_code / {2,3} to check this.



AllProcessesUsingOldModule = [Pid || 
    Pid <- processes(), 
    check_process_code(Pid, module_name)].

      

+6


source







All Articles