Extended process registry.
Authors: Ulf Wiger ([email protected]
).
This module implements an extended process registry
For a detailed description, see gproc/doc/erlang07-wiger.pdf.
code_change/4 | |
demonitor/2 | |
elected/2 | |
elected/3 | |
from_leader/3 | |
get_leader/0 | Returns the node of the current gproc leader. |
give_away/2 | |
handle_DOWN/3 | |
handle_call/4 | |
handle_cast/3 | |
handle_info/2 | |
handle_info/3 | |
handle_leader_call/4 | |
handle_leader_cast/3 | |
init/1 | |
leader_call/1 | |
leader_cast/1 | |
monitor/2 | |
mreg/2 | |
munreg/2 | |
reg/1 | |
reg/4 | Class = n - unique name | p - non-unique property | c - counter | a - aggregated counter | r - resource property | rc - resource counter. |
reg_or_locate/3 | |
reg_other/5 | Class = n - unique name | a - aggregated counter | r - resource property | rc - resource counter Value = term() Attrs = [{Key, Value}]. |
reg_shared/3 | |
reset_counter/1 | |
set_attributes/2 | |
set_attributes_shared/2 | |
set_value/2 | |
set_value_shared/2 | |
start_link/0 | |
start_link/1 | |
surrendered/3 | |
sync/0 | Synchronize with the gproc leader. |
terminate/2 | |
unreg/1 | |
unreg_other/2 | |
unreg_shared/1 | |
update_counter/3 | |
update_counters/1 | |
update_shared_counter/2 |
code_change(FromVsn, S, Extra, E) -> any()
demonitor(Key, Ref) -> any()
elected(S, E) -> any()
elected(S, E, Node) -> any()
from_leader(Ops, S, E) -> any()
get_leader() -> node()
Returns the node of the current gproc leader.
give_away(Key, To) -> any()
handle_DOWN(Node, S, E) -> any()
handle_call(X1, From, S, E) -> any()
handle_cast(Msg, S, X3) -> any()
handle_info(X1, S) -> any()
handle_info(Msg, S, E) -> any()
handle_leader_call(X1, From, S, E) -> any()
handle_leader_cast(X1, S, E) -> any()
init(Opts) -> any()
leader_call(Req) -> any()
leader_cast(Msg) -> any()
monitor(Key, Type) -> any()
mreg(T, KVL) -> any()
munreg(T, Keys) -> any()
reg(Key) -> any()
reg(Key, Value, Attrs, Op) -> any()
Class = n - unique name | p - non-unique property | c - counter | a - aggregated counter | r - resource property | rc - resource counter
reg_or_locate(Key, Value, Pid) -> any()
reg_other(Key::{Class, g, Key}, Pid::pid(), Value, Attrs, Op::reg | unreg) -> true
Class = n - unique name | a - aggregated counter | r - resource property | rc - resource counter Value = term() Attrs = [{Key, Value}]
reg_shared(Key, Value, Attrs) -> any()
reset_counter(Key) -> any()
set_attributes(Key, Attrs) -> any()
set_attributes_shared(Key, Attrs) -> any()
set_value(Key, Value) -> any()
set_value_shared(Key, Value) -> any()
start_link() -> any()
start_link(Nodes) -> any()
surrendered(State, X2, E) -> any()
sync() -> true
Synchronize with the gproc leader
This function can be used to ensure that data has been replicated from the
leader to the current node. It does so by asking the leader to ping all
live participating nodes. The call will return true
when all these nodes
have either responded or died. In the special case where the leader dies
during an ongoing sync, the call will fail with a timeout exception.
(Actually, it should be a leader_died
exception; more study needed to find
out why gen_leader times out in this situation, rather than reporting that
the leader died.)
terminate(Reason, S) -> any()
unreg(Key) -> any()
unreg_other(Key, Pid) -> any()
unreg_shared(Key) -> any()
update_counter(Key, Pid, Incr) -> any()
update_counters(List) -> any()
update_shared_counter(Key, Incr) -> any()