public class KubernetesCheckpointRecoveryFactory extends Object implements CheckpointRecoveryFactory
CompletedCheckpointStore
and CheckpointIDCounter
.Constructor and Description |
---|
KubernetesCheckpointRecoveryFactory(FlinkKubeClient kubeClient,
Configuration configuration,
Executor executor,
java.util.function.Function<JobID,String> function,
String lockIdentity)
Create a KubernetesCheckpointRecoveryFactory.
|
Modifier and Type | Method and Description |
---|---|
CheckpointIDCounter |
createCheckpointIDCounter(JobID jobID)
Creates a
CheckpointIDCounter instance for a job. |
CompletedCheckpointStore |
createCheckpointStore(JobID jobID,
int maxNumberOfCheckpointsToRetain,
ClassLoader userClassLoader)
Creates a
CompletedCheckpointStore instance for a job. |
public KubernetesCheckpointRecoveryFactory(FlinkKubeClient kubeClient, Configuration configuration, Executor executor, java.util.function.Function<JobID,String> function, String lockIdentity)
kubeClient
- Kubernetes clientconfiguration
- Flink configurationexecutor
- IO executor to run blocking callsfunction
- Function to get the ConfigMap name for checkpoint.lockIdentity
- Lock identity of current HA servicepublic CompletedCheckpointStore createCheckpointStore(JobID jobID, int maxNumberOfCheckpointsToRetain, ClassLoader userClassLoader) throws Exception
CheckpointRecoveryFactory
CompletedCheckpointStore
instance for a job.createCheckpointStore
in interface CheckpointRecoveryFactory
jobID
- Job ID to recover checkpoints formaxNumberOfCheckpointsToRetain
- Maximum number of checkpoints to retainuserClassLoader
- User code class loader of the jobCompletedCheckpointStore
instance for the jobException
public CheckpointIDCounter createCheckpointIDCounter(JobID jobID)
CheckpointRecoveryFactory
CheckpointIDCounter
instance for a job.createCheckpointIDCounter
in interface CheckpointRecoveryFactory
jobID
- Job ID to recover checkpoints forCheckpointIDCounter
instance for the jobCopyright © 2014–2021 The Apache Software Foundation. All rights reserved.