Module machi_chain_manager1

The Machi chain manager, Guardian of all things related to Chain Replication state, status, and data replica safety.

Behaviours: gen_server.

Description

The Machi chain manager, Guardian of all things related to Chain Replication state, status, and data replica safety.

The Chain Manager is responsible for managing the state of Machi's "Chain Replication" state. This role is roughly analogous to the "Riak Core" application inside of Riak, which takes care of coordinating replica placement and replica repair.

For each primitive data server in the cluster, a Machi FLU, there is a Chain Manager process that manages its FLU's role within the Machi cluster's Chain Replication scheme. Each Chain Manager process executes locally and independently to manage the distributed state of a single Machi Chain Replication chain.

Machi's Chain Manager process performs similar tasks as Riak Core's claimant. However, Machi has several active Chain Manager processes, one per FLU server, instead of a single active process like Core's claimant. Each Chain Manager process acts independently; each is constrained so that it will reach consensus via independent computation & action.

Function Index

code_change/3
get_all_hosed/1
handle_call/3
handle_cast/2
handle_info/2
init/1
inner_projection_exists/1
inner_projection_or_self/1
make_chmgr_regname/1
ping/1
projection_transitions_are_sane/2
set_active/2
set_chain_members/2Set chain members list.
start_link/2
start_link/3
stop/1
terminate/2
test_calc_projection/2
test_react_to_env/1
test_read_latest_public_projection/2
test_write_public_projection/2

Function Details

code_change/3

code_change(OldVsn, S, Extra) -> any()

get_all_hosed/1

get_all_hosed(P) -> any()

handle_call/3

handle_call(Call, From, S) -> any()

handle_cast/2

handle_cast(Cast, S) -> any()

handle_info/2

handle_info(Msg, Ch_mgr) -> any()

init/1

init(X1) -> any()

inner_projection_exists/1

inner_projection_exists(P) -> any()

inner_projection_or_self/1

inner_projection_or_self(P) -> any()

make_chmgr_regname/1

make_chmgr_regname(A) -> any()

ping/1

ping(Pid) -> any()

projection_transitions_are_sane/2

projection_transitions_are_sane(Ps, RelativeToServer) -> any()

set_active/2

set_active(Pid, Boolean) -> any()

set_chain_members/2

set_chain_members(Pid, MembersDict) -> any()

Set chain members list.

NOTE: This implementation is a bit brittle, in that an author with higher rank may try to re-suggest the old membership list if it races with an author of lower rank. For now, we suggest calling set_chain_members() first on the author of highest rank and finish with lowest rank, i.e. name z* first, name a* last.

start_link/2

start_link(MyName, MembersDict) -> any()

start_link/3

start_link(MyName, MembersDict, MgrOpts) -> any()

stop/1

stop(Pid) -> any()

terminate/2

terminate(Reason, S) -> any()

test_calc_projection/2

test_calc_projection(Pid, KeepRunenvP) -> any()

test_react_to_env/1

test_react_to_env(Pid) -> any()

test_read_latest_public_projection/2

test_read_latest_public_projection(Pid, ReadRepairP) -> any()

test_write_public_projection/2

test_write_public_projection(Pid, Proj) -> any()


Generated by EDoc, May 20 2015, 11:11:34.