public abstract class LeaderElectorOptions<O extends LeaderElectorOptions<O>> extends DistributedPrimitiveOptions<O>
AsyncLeaderElector
instances.Constructor and Description |
---|
LeaderElectorOptions() |
Modifier and Type | Method and Description |
---|---|
long |
electionTimeoutMillis()
Returns the election timeout in milliseconds.
|
O |
withElectionTimeout(long electionTimeoutMillis)
Sets the election timeout in milliseconds.
|
O |
withElectionTimeout(long electionTimeout,
TimeUnit timeUnit)
Sets the election timeout.
|
applicationId, meteringEnabled, name, partitionsDisabled, readOnly, relaxedReadConsistency, revisionType, serializer, type, version, withApplicationId, withMeteringDisabled, withName, withRelaxedReadConsistency, withRevisionType, withSerializer, withUpdatesDisabled, withVersion
public O withElectionTimeout(long electionTimeoutMillis)
electionTimeoutMillis
- the election timeout in millisecondspublic O withElectionTimeout(long electionTimeout, TimeUnit timeUnit)
electionTimeout
- the election timeouttimeUnit
- the timeout time unitpublic final long electionTimeoutMillis()