Module replication

Implementation of replication as redundancy strategy.

Copyright © 2014-2016 Zuse Institute Berlin,

Version: $Id$

Authors: Jan Skrzypczak (skrzypczak@zib.de).

Description

Implementation of replication as redundancy strategy

Data Types

client_value()

client_value() = any()

Function Index

get_keys/1Returns the replicas of the given key.
write_values_for_keys/2Returns a list of values (based on WriteValue) wich should be written to the Keys passed as argument.
quorum_accepted/2Returns if enough acks for majority have been collected.
quorum_denied/2Returns if enough denies for majority have been collected.
collect_newer_read_value/3Handles a new read reply of a round newer than the newest round seen in the past.
collect_older_read_value/3Handles a new read reply of a previous round.
collect_read_value/3Handles a new read reply of the current round.
get_read_value/2Returns the read value base on all previously collected read replies.
skip_write_through/1Decide whether to skip a write through based on the read value.

Function Details

get_keys/1

get_keys(Key :: rt_chord:key()) -> [rt_chord:key()]

Returns the replicas of the given key.

write_values_for_keys/2

write_values_for_keys(Keys :: [rt_chord:key()],
                      WriteValue :: client_value()) ->
                         [client_value()]

Returns a list of values (based on WriteValue) wich should be written to the Keys passed as argument

quorum_accepted/2

quorum_accepted(Key :: rt_chord:key(), AccCount :: integer()) ->
                   boolean()

Returns if enough acks for majority have been collected.

quorum_denied/2

quorum_denied(Key :: rt_chord:key(), DeniedCount :: integer()) ->
                 boolean()

Returns if enough denies for majority have been collected.

collect_newer_read_value/3

collect_newer_read_value(Collected :: client_value(),
                         NewValue :: client_value(),
                         DataType :: module()) ->
                            client_value()

Handles a new read reply of a round newer than the newest round seen in the past.

collect_older_read_value/3

collect_older_read_value(Collected :: client_value(),
                         NewValue :: client_value(),
                         DataType :: module()) ->
                            client_value()

Handles a new read reply of a previous round.

collect_read_value/3

collect_read_value(Collected :: client_value(),
                   NewValue :: client_value(),
                   DataType :: module()) ->
                      client_value()

Handles a new read reply of the current round.

get_read_value/2

get_read_value(ReadValue :: client_value(),
               ReadFilter :: prbr:read_filter()) ->
                  client_value()

Returns the read value base on all previously collected read replies

skip_write_through/1

skip_write_through(ReadValue :: client_value()) -> boolean()

Decide whether to skip a write through based on the read value


Generated by EDoc, Aug 2 2016, 13:43:21.