how to retrive registered processes of user application running on a node

Vance Shipley vances@REDACTED
Tue Dec 24 19:47:18 CET 2002


On Tue, Dec 24, 2002 at 08:27:59AM +0000, Suresh S wrote:
}
}   is there any chance to know all the registered
}   processes of my application running on a node
}  
}   there is no .app file for my application


Suresh,

If you don't gave a .app file then you don't have an application. :)

If you do then application:get_key/[1|2] will report on what you defined
in your .app file:

1> application:get_key(kernel, registered).
{ok,[application_controller,
     erl_reply,
     auth,
     boot_server,
     code_server,
     disk_log_server,
     disk_log_sup,
     erl_prim_loader,
     error_logger,
     file_server,
     file_server_2,
     fixtable_server,
     global_group,
     global_name_server,
     heart,
     init,
     kernel_config,
     kernel_sup,
     net_kernel,
     net_sup,
     rex,
     user,
     os_server,
     ddll_server,
     erl_epmd,
     inet_db,
     pg2]}


This doesn't necessarily tell you the whole story though.  In some of our
applications we have many dynamic registered processes for which we cannot
predict when we write the .app file.  As I have said the above only reports
on what is in the application specification.  I have always thought that
we should be able to put patterns or prefixes in the specification so that
we could define these sorts of things (e.g. chan_fsm_[0-9][0-9]).

	-Vance



More information about the erlang-questions mailing list