SelfStabilizingGossip

A collection of self-stabilizing gossip algorithms.

Functions

Link copied to clipboard
fun <ID : Comparable<ID>, Value : Comparable<Value>> Aggregate<ID>.gossipMax(local: Value): Value

gossipMax with a default comparator. Spreads across all (aligned) devices the current maximum Value of local, as computed by first value compared to the second.

fun <ID : Comparable<ID>, Value> Aggregate<ID>.gossipMax(local: Value, comparator: Comparator<Value>): Value

Self-stabilizing gossip-max. Spreads across all (aligned) devices the current maximum Value of local, as computed by comparator.

Link copied to clipboard
fun <ID : Comparable<ID>, Value : Comparable<Value>> Aggregate<ID>.gossipMin(local: Value): Value

gossipMin with a default comparator. Spreads across all (aligned) devices the current minimum Value of local, as computed by first value compared to the second, and then reversed.

fun <ID : Comparable<ID>, Value> Aggregate<ID>.gossipMin(local: Value, comparator: Comparator<Value>): Value

Self-stabilizing gossip-min. Spreads across all (aligned) devices the current minimum Value of local, as computed by comparator.

Link copied to clipboard
fun <ID : Comparable<ID>> Aggregate<ID>.isHappeningAnywhere(condition: () -> Boolean): Boolean

A gossip algorithm that computes whether any device is experiencing a certain condition.