[erlang-questions] Questions about supervision

Garrett Smith <>
Tue May 3 12:57:13 CEST 2016


On Tue, May 3, 2016 at 3:51 AM, Garrett Smith <> wrote:
> Hi Oliver,
>
> On Tue, May 3, 2016 at 12:54 AM, Oliver Korpilla <> wrote:
>
>> I sometimes rely on the supervisor:which_children/1 call to find the IDs of all active groups. When inspecting all three layers of supervision I realized that processes are not cleaned up from the list of children like I expected.
>
> Inspecting supervisor state is not well supported - and it's not a
> great idea. You're better off using something like gproc [1] to
> register processes by types-of-interest and use it to enumerate them.
>
> [1] https://github.com/uwiger/gproc

I've long been in the habit of using gproc for this problem, but syn
bears mentioning as well:

https://github.com/ostinelli/syn


More information about the erlang-questions mailing list