public class PerJobCheckpointRecoveryFactory<T extends CompletedCheckpointStore> extends Object implements CheckpointRecoveryFactory
CheckpointRecoveryFactory which creates and keeps separate CompletedCheckpointStore and CheckpointIDCounter for each JobID.| Modifier and Type | Class and Description |
|---|---|
static interface |
PerJobCheckpointRecoveryFactory.CheckpointStoreRecoveryHelper<StoreType extends CompletedCheckpointStore>
Restores or creates a
CompletedCheckpointStore, optionally using an existing one. |
| Constructor and Description |
|---|
PerJobCheckpointRecoveryFactory(PerJobCheckpointRecoveryFactory.CheckpointStoreRecoveryHelper<T> checkpointStoreRecoveryHelper) |
PerJobCheckpointRecoveryFactory(PerJobCheckpointRecoveryFactory.CheckpointStoreRecoveryHelper<T> checkpointStoreRecoveryHelper,
Supplier<CheckpointIDCounter> checkpointIDCounterPerJobFactory) |
| Modifier and Type | Method and Description |
|---|---|
CheckpointIDCounter |
createCheckpointIDCounter(org.apache.flink.api.common.JobID jobId)
Creates a
CheckpointIDCounter instance for a job. |
CompletedCheckpointStore |
createRecoveredCompletedCheckpointStore(org.apache.flink.api.common.JobID jobId,
int maxNumberOfCheckpointsToRetain,
SharedStateRegistryFactory sharedStateRegistryFactory,
Executor ioExecutor,
org.apache.flink.core.execution.RestoreMode restoreMode)
Creates a RECOVERED
CompletedCheckpointStore instance for a job. |
static <T extends CompletedCheckpointStore> |
withoutCheckpointStoreRecovery(IntFunction<T> storeFn) |
public PerJobCheckpointRecoveryFactory(PerJobCheckpointRecoveryFactory.CheckpointStoreRecoveryHelper<T> checkpointStoreRecoveryHelper)
public PerJobCheckpointRecoveryFactory(PerJobCheckpointRecoveryFactory.CheckpointStoreRecoveryHelper<T> checkpointStoreRecoveryHelper, Supplier<CheckpointIDCounter> checkpointIDCounterPerJobFactory)
@VisibleForTesting public static <T extends CompletedCheckpointStore> CheckpointRecoveryFactory withoutCheckpointStoreRecovery(IntFunction<T> storeFn)
public CompletedCheckpointStore createRecoveredCompletedCheckpointStore(org.apache.flink.api.common.JobID jobId, int maxNumberOfCheckpointsToRetain, SharedStateRegistryFactory sharedStateRegistryFactory, Executor ioExecutor, org.apache.flink.core.execution.RestoreMode restoreMode)
CheckpointRecoveryFactoryCompletedCheckpointStore instance for a job. In this context,
RECOVERED means, that if we already have completed checkpoints from previous runs, we should
use them as the initial state.createRecoveredCompletedCheckpointStore in interface CheckpointRecoveryFactoryjobId - Job ID to recover checkpoints formaxNumberOfCheckpointsToRetain - Maximum number of checkpoints to retainsharedStateRegistryFactory - Simple factory to produce SharedStateRegistry
objects.ioExecutor - Executor used to run (async) deletes.restoreMode - the claim mode with which the job is restoring.CompletedCheckpointStore instance for the jobpublic CheckpointIDCounter createCheckpointIDCounter(org.apache.flink.api.common.JobID jobId)
CheckpointRecoveryFactoryCheckpointIDCounter instance for a job.createCheckpointIDCounter in interface CheckpointRecoveryFactoryjobId - Job ID to recover checkpoints forCheckpointIDCounter instance for the jobCopyright © 2014–2025 The Apache Software Foundation. All rights reserved.