Copyright © 2008-2014 Zuse Institute Berlin
Version: $Id$
Behaviours: gossip_beh.
Authors: Thorsten Schuett (schuett@zib.de), Jens V. Fischer (jensvfischer@gmail.com).
data() = any()
est_error() = float()
latency() = number()
network_coordinate() = [float()]
round() = non_neg_integer()
state() = {network_coordinate(), est_error()}
check_config/0 | Checks whether config parameters of the vivaldi process exist and are valid. |
fanout/0 | The fanout (number of peers contacted per cycle). |
get_coordinate/0 | Sends a (local) message with a vivaldi get_coordinate request to the gossip module of the requesting process' group asking for the current coordinate and confidence. |
handle_msg/2 | Handle messages Response from vivaldi_latency after finishing measuring. |
init/1 | Initiate the gossip_vivaldi module. |
integrate_data/3 | Ignored, vivaldi is a push-only scheme. |
max_cycles_per_round/0 | The maximum number of cycles per round. |
min_cycles_per_round/0 | The minimum number of cycles per round. |
notify_change/3 | Ignored, vivaldi doesn't use / implements these features. |
round_has_converged/1 | Always returns false, vivaldi does not implement rounds. |
select_data/1 | Select and prepare the data to be sent to the peer. |
select_node/1 | Returns false, i.e. |
select_reply_data/4 | Process the data from the requestor. |
shutdown/1 | Shut down the gossip_vivaldi module. |
trigger_interval/0 | The time interval in ms after which a new cycle is triggered by the gossip module. |
update_coordinate/5 | |
web_debug_info/1 | Returns a key-value list of debug infos for the Web Interface. |
trigger_interval() -> pos_integer()
The time interval in ms after which a new cycle is triggered by the gossip module.
fanout() -> pos_integer()
The fanout (number of peers contacted per cycle).
min_cycles_per_round() -> infinity
The minimum number of cycles per round. Returns infinity, as rounds are not implemented by vivaldi.
max_cycles_per_round() -> infinity
The maximum number of cycles per round. Returns infinity, as rounds are not implemented by vivaldi.
check_config() -> boolean()
Checks whether config parameters of the vivaldi process exist and are valid.
get_coordinate() -> ok
Sends a (local) message with a vivaldi get_coordinate request to the gossip module of the requesting process' group asking for the current coordinate and confidence.
init(Args :: [any()]) -> {ok, state()}
Initiate the gossip_vivaldi module.
Called by the gossip module upon startup.
The Instance information is ignored, {gossip_vivaldi, default} is always used.
Returns false, i.e. peer selection is done by the gossip module.
Select and prepare the data to be sent to the peer.
The data consists of the coordinates and confidence of this node.
Called by the gossip module at the beginning of every cycle.
The selected exchange data is to be sent back to the gossip module as a
message of the form {selected_data, Instance, ExchangeData}.
select_reply_data(PData :: data(), Ref :: pos_integer(), Round :: round(), State :: state()) -> {discard_msg | ok | retry | send_back, state()}
Process the data from the requestor.
No reply-data is selected and no select_reply_data_response is sent to
the gossip module, because vivaldi implements a push-only scheme.
Called by the behaviour module upon a p2p_exch message.
PData: exchange data from the p2p_exch request
Ref: used by the gossip module to identify the request
Round: ignored, as vivaldi does not implement round handling
integrate_data(QData :: data(), Round :: round(), State :: state()) -> {discard_msg | ok | retry | send_back, state()}
Ignored, vivaldi is a push-only scheme.
handle_msg(Msg :: comm:message(), State :: state()) -> {ok, state()}
Handle messages Response from vivaldi_latency after finishing measuring.
Always returns false, vivaldi does not implement rounds.
Ignored, vivaldi doesn't use / implements these features.
web_debug_info(State :: state()) -> {KeyValueList :: [{Key :: string(), Value :: any()}, ...], state()}
Returns a key-value list of debug infos for the Web Interface.
Called by the gossip module upon {web_debug_info} messages.
shutdown(State :: state()) -> {ok, shutdown}
Shut down the gossip_vivaldi module.
Called by the gossip module upon stop_gossip_task(CBModule).
update_coordinate(Coordinate :: network_coordinate(), RemoteError :: est_error(), Latency :: latency(), X4 :: network_coordinate(), Error :: est_error()) -> {network_coordinate(), est_error()}
Generated by EDoc, Feb 29 2016, 16:16:20.