View Source ZenMonitor.Local.State (ZenMonitor v2.1.0)
Maintains the internal state for ZenMonitor.Local
subscribers
is an ETS table that tracks local subscribers to prevent multiple monitorsbatch
is the queue of messages awaiting delivery to ZenMonitor.Local.Dispatcherlength
is the current length of the batch queue (calculating queue length is an O(n) operation, it is simple to track it as elements are added / removed)queue_emptied
is the number of times the queue has been emptied. Once this number exceeds the hibernation_threshold (seehibernation_threshold/0
) the process will hibernate
Link to this section Summary
Link to this section Types
Specs
t() :: %ZenMonitor.Local.State{ batch: :queue.queue(), length: integer(), queue_emptied: integer(), subscribers: :ets.tid() }