Skip to content
This repository has been archived by the owner on Aug 9, 2022. It is now read-only.

Latest commit

 

History

History
155 lines (87 loc) · 4.02 KB

forseti_locks.md

File metadata and controls

155 lines (87 loc) · 4.02 KB

Module forseti_locks

Behaviours: locks_leader.

Function Index

add_call/2
choose_node/0
code_change/4
elected/3
find/2
from_leader/3
get/3
get_metrics/0
handle_DOWN/3
handle_call/4
handle_cast/3
handle_info/3
handle_leader_call/4
handle_leader_cast/3
init/1
start_link/1
stop/0
surrendered/3
terminate/2

Function Details

add_call/2


add_call(Name::call_name(), Call::call()) -> ok

choose_node/0


choose_node() -> node()

code_change/4

code_change(OldVsn, State, Election, Extra) -> any()

elected/3

elected(State, Election, Pid) -> any()

find/2


find(Name::call_name, Key::key()) -> {ok, pid()} | undefined

from_leader/3

from_leader(State, OldState, Election) -> any()

get/3


get(Name::call_name(), Key::key(), Args::[term()]) -> {ok, pid()} | {error, reason()}

get_metrics/0


get_metrics() -> [{node(), pos_integer()}]

handle_DOWN/3

handle_DOWN(Pid, State, Election) -> any()

handle_call/4

handle_call(Request, From, State, Election) -> any()

handle_cast/3

handle_cast(Msg, State, Election) -> any()

handle_info/3

handle_info(Info, State, Election) -> any()

handle_leader_call/4

handle_leader_call(Request, From, State, Election) -> any()

handle_leader_cast/3

handle_leader_cast(Request, State, Election) -> any()

init/1

init(X1) -> any()

start_link/1


start_link(Nodes::[atom()]) -> {ok, pid()} | {error, term()}

stop/0


stop() -> ok

surrendered/3

surrendered(State, X2, Election) -> any()

terminate/2

terminate(Reason, State) -> any()