exbackoff v0.0.1 Exbackoff
Summary
Functions
Starts a timer from the `backoff()’ argument, using erlang:start_timer/3. No reference tracking is done, and this is left to the user. This function is purely a convenience function
Reads the current backoff value
Just do the increments by hand!
init function when the user doesn’t feel like using a timer provided by this library
init function when the user feels like using a timer provided by this library
Just do the random increments by hand! Choose delay uniformly from [0.5 * Time, 1.5 * Time] as recommended in: Sally Floyd and Van Jacobson, The Synchronization of Periodic Routing Messages, April 1994 IEEE/ACM Transactions on Networking. http://ee.lbl.gov/papers/sync_94.pdf
Swaps between the states of the backoff
Types
backoff :: %Exbackoff{current: pos_integer, dest: pid, max: max, start: pos_integer, type: :normal | :jitter, value: any}
Functions
Specs
fire(backoff) :: reference
Starts a timer from the `backoff()’ argument, using erlang:start_timer/3. No reference tracking is done, and this is left to the user. This function is purely a convenience function.
Specs
init(pos_integer, max) :: backoff
init function when the user doesn’t feel like using a timer provided by this library
Specs
init(pos_integer, max, pid | nil, any | nil) :: backoff
init function when the user feels like using a timer provided by this library
Specs
rand_increment(pos_integer) :: pos_integer
Just do the random increments by hand! Choose delay uniformly from [0.5 * Time, 1.5 * Time] as recommended in: Sally Floyd and Van Jacobson, The Synchronization of Periodic Routing Messages, April 1994 IEEE/ACM Transactions on Networking. http://ee.lbl.gov/papers/sync_94.pdf