[erlang-questions] [clarify] Limits and overhead of monitors

Bjorn Gustavsson bjorn@REDACTED
Mon Jun 9 16:01:57 CEST 2008


Jay Nelson <jay@REDACTED> writes:

> Has anyone determined the answer to any of the following questions:
> 
> 1) Is a practical limit to the number of monitors a single process  
> can hold?

There is no theoretical limit. The practical limit probably depends
on the application and the amount of memory in the computer.

>       - I assume they are fairly static, so just the memory to store  
> them?
>       - how are they stored?

The endpoints for each monitor are stored in AVL trees. A monitor requires
about 10 words at each endpoint.

>       - any problems if I have 100K processes in an everyone  
> monitoring everyone configuration?

If one process dies, 100,000 processes will each get one DOWN message
and become runnable. It could take some time for the system run all those
processes. 

> 2) How much overhead difference is there between a local monitor and  
> remote node process monitor?
>
>       - The pinging between nodes shouldn't need to propagate, just  
> the failure to ping a node

Correct.

/Bjorn
-- 
Björn Gustavsson, Erlang/OTP, Ericsson AB



More information about the erlang-questions mailing list