Show / Hide Table of Contents

Struct ElectionTimeout

Represents leader election timeout.

Inherited Members
ValueType.Equals(object)
ValueType.GetHashCode()
ValueType.ToString()
object.Equals(object, object)
object.GetType()
object.ReferenceEquals(object, object)
Namespace: DotNext.Net.Cluster.Consensus.Raft
Assembly: DotNext.Net.Cluster.dll
Syntax
public readonly struct ElectionTimeout

Properties

| Edit this page View Source

LowerValue

Gets lower possible value of leader election timeout, in milliseconds.

Declaration
public required int LowerValue { get; init; }
Property Value
Type Description
int
| Edit this page View Source

Recommended

Gets recommended election timeout.

Declaration
public static ElectionTimeout Recommended { get; }
Property Value
Type Description
ElectionTimeout
| Edit this page View Source

UpperValue

Gets upper possible value of leader election timeout, in milliseconds.

Declaration
public required int UpperValue { get; init; }
Property Value
Type Description
int

Methods

| Edit this page View Source

RandomTimeout(Random)

Generates random election timeout.

Declaration
public int RandomTimeout(Random random)
Parameters
Type Name Description
Random random

The source of random values.

Returns
Type Description
int

The randomized election timeout.

Extension Methods

BasicExtensions.IsBetween<T, TLowerBound, TUpperBound>(T, TLowerBound, TUpperBound)
BasicExtensions.IsOneOf<T>(T, ReadOnlySpan<T>)
Collection.ToAsyncEnumerator<TEnumerator, T>(TEnumerator, CancellationToken)
Collection.ToClassicEnumerator<TEnumerator, T>(TEnumerator)
Enumerator.Skip<TEnumerator, T>(ref TEnumerator, int)
ExpressionBuilder.Const<T>(T)
  • Edit this page
  • View Source
☀
☾
In this article
Back to top
Supported by the .NET Foundation
☀
☾