Class PartitionTransitionImpl
java.lang.Object
io.camunda.zeebe.broker.system.partitions.impl.PartitionTransitionImpl
- All Implemented Interfaces:
PartitionTransition
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.camunda.zeebe.broker.system.partitions.PartitionTransition
PartitionTransition.CancelledPartitionTransition, PartitionTransition.FailedPartitionTransitionPreparation -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidsetConcurrencyControl(ConcurrencyControl concurrencyControl) Sets the ConcurrencyControl through which tasks are executed.toFollower(long term) Transitions to follower asynchronously by closing the current partition's components and opening a follower partition.toInactive(long term) Closes the current partition's components asynchronously.toLeader(long term) Transitions to leader asynchronously by closing the current partition's components and opening a leader partition.transitionTo(long term, RaftServer.Role role) voidupdateTransitionContext(PartitionTransitionContext transitionContext) Sets the transition context
-
Constructor Details
-
PartitionTransitionImpl
-
-
Method Details
-
toFollower
Description copied from interface:PartitionTransitionTransitions to follower asynchronously by closing the current partition's components and opening a follower partition.- Specified by:
toFollowerin interfacePartitionTransition- Parameters:
term- the current term on which the transition happens- Returns:
- an ActorFuture to be completed when the transition is complete. Completed exceptionally
with
PartitionTransition.CancelledPartitionTransitionif the partition was cancelled.
-
toLeader
Description copied from interface:PartitionTransitionTransitions to leader asynchronously by closing the current partition's components and opening a leader partition.- Specified by:
toLeaderin interfacePartitionTransition- Parameters:
term- the current term on which the transition happens- Returns:
- an ActorFuture to be completed when the transition is complete. Completed exceptionally
* with
PartitionTransition.CancelledPartitionTransitionif the partition was cancelled.
-
toInactive
Description copied from interface:PartitionTransitionCloses the current partition's components asynchronously.- Specified by:
toInactivein interfacePartitionTransition- Returns:
- an ActorFuture completed when the transition is complete. Completed exceptionally *
with
PartitionTransition.CancelledPartitionTransitionif the partition was cancelled.
-
setConcurrencyControl
Description copied from interface:PartitionTransitionSets the ConcurrencyControl through which tasks are executed.- Specified by:
setConcurrencyControlin interfacePartitionTransition- Parameters:
concurrencyControl- the concurrency control
-
updateTransitionContext
Description copied from interface:PartitionTransitionSets the transition context- Specified by:
updateTransitionContextin interfacePartitionTransition- Parameters:
transitionContext- the context to be used
-
getHealthIssue
- Specified by:
getHealthIssuein interfacePartitionTransition- Returns:
- null if transition is healthy or a
HealthIssueif not.
-
transitionTo
-