Package io.aeron.cluster
Class ClusterBackup
java.lang.Object
io.aeron.cluster.ClusterBackup
- All Implemented Interfaces:
AutoCloseable
Backup component which can run remote from a cluster which polls for snapshots and replicates the log.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classConfiguration options forClusterBackupwith defaults and constants for system properties lookup.static classContext for overriding default configuration forClusterBackup.static enumDefines the type of node that this will receive log data from.static enumState of the cluster backup state machine. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe type id of theCounterused for the backup state.static final intThe type id of theCounterused for keeping track of the number of errors that have occurred.static final intThe type id of theCounterused for the live log position counter.static final intThe type id of theCounterused for the next query deadline counter. -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Get theAgentInvokerfor the cluster backup.context()Get theClusterBackup.Contextthat is used by thisClusterBackup.static ClusterBackuplaunch()Launch anClusterBackupusing a default configuration.static ClusterBackupLaunch anClusterBackupby providing a configuration context.
-
Field Details
-
BACKUP_STATE_TYPE_ID
public static final int BACKUP_STATE_TYPE_IDThe type id of theCounterused for the backup state.- See Also:
-
LIVE_LOG_POSITION_TYPE_ID
public static final int LIVE_LOG_POSITION_TYPE_IDThe type id of theCounterused for the live log position counter.- See Also:
-
QUERY_DEADLINE_TYPE_ID
public static final int QUERY_DEADLINE_TYPE_IDThe type id of theCounterused for the next query deadline counter.- See Also:
-
CLUSTER_BACKUP_ERROR_COUNT_TYPE_ID
public static final int CLUSTER_BACKUP_ERROR_COUNT_TYPE_IDThe type id of theCounterused for keeping track of the number of errors that have occurred.- See Also:
-
-
Method Details
-
launch
Launch anClusterBackupusing a default configuration.- Returns:
- a new instance of an
ClusterBackup.
-
launch
Launch anClusterBackupby providing a configuration context.- Parameters:
ctx- for the configuration parameters.- Returns:
- a new instance of an
ClusterBackup.
-
context
Get theClusterBackup.Contextthat is used by thisClusterBackup.- Returns:
- the
ClusterBackup.Contextthat is used by thisClusterBackup.
-
conductorAgentInvoker
Get theAgentInvokerfor the cluster backup.- Returns:
- the
AgentInvokerfor the cluster backup.
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-