public enum DeactivatedCheckpointCompletedCheckpointStore extends Enum<DeactivatedCheckpointCompletedCheckpointStore> implements CompletedCheckpointStore
CompletedCheckpointStore if checkpointing has been disabled.
Consequently, no component should use methods other than CompletedCheckpointStore.shutdown(org.apache.flink.api.common.JobStatus, org.apache.flink.runtime.checkpoint.CheckpointsCleaner).| 枚举常量和说明 |
|---|
INSTANCE |
LOG| 限定符和类型 | 方法和说明 |
|---|---|
CompletedCheckpoint |
addCheckpointAndSubsumeOldestOne(CompletedCheckpoint checkpoint,
CheckpointsCleaner checkpointsCleaner,
Runnable postCleanup)
Adds a
CompletedCheckpoint instance to the list of completed checkpoints. |
List<CompletedCheckpoint> |
getAllCheckpoints()
Returns all
CompletedCheckpoint instances. |
int |
getMaxNumberOfRetainedCheckpoints()
Returns the max number of retained checkpoints.
|
int |
getNumberOfRetainedCheckpoints()
Returns the current number of retained checkpoints.
|
SharedStateRegistry |
getSharedStateRegistry()
Returns the
SharedStateRegistry used to register the shared state. |
boolean |
requiresExternalizedCheckpoints()
This method returns whether the completed checkpoint store requires checkpoints to be
externalized.
|
void |
shutdown(org.apache.flink.api.common.JobStatus jobStatus,
CheckpointsCleaner checkpointsCleaner)
Shuts down the store.
|
static DeactivatedCheckpointCompletedCheckpointStore |
valueOf(String name)
返回带有指定名称的该类型的枚举常量。
|
static DeactivatedCheckpointCompletedCheckpointStore[] |
values()
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。
|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOfgetLatestCheckpoint, getLatestCheckpointIdpublic static final DeactivatedCheckpointCompletedCheckpointStore INSTANCE
public static DeactivatedCheckpointCompletedCheckpointStore[] values()
for (DeactivatedCheckpointCompletedCheckpointStore c : DeactivatedCheckpointCompletedCheckpointStore.values()) System.out.println(c);
public static DeactivatedCheckpointCompletedCheckpointStore valueOf(String name)
name - 要返回的枚举常量的名称。IllegalArgumentException - 如果该枚举类型没有带有指定名称的常量NullPointerException - 如果参数为空值public CompletedCheckpoint addCheckpointAndSubsumeOldestOne(CompletedCheckpoint checkpoint, CheckpointsCleaner checkpointsCleaner, Runnable postCleanup) throws Exception
CompletedCheckpointStoreCompletedCheckpoint instance to the list of completed checkpoints.
Only a bounded number of checkpoints is kept. When exceeding the maximum number of retained checkpoints, the oldest one will be discarded.
After FLINK-24611, SharedStateRegistry.unregisterUnusedState(long) should be called here to subsume unused state.
Note, the CompletedCheckpoint passed to
SharedStateRegistry.registerAllAfterRestored(org.apache.flink.runtime.checkpoint.CompletedCheckpoint, org.apache.flink.runtime.jobgraph.RestoreMode) or SharedStateRegistryFactory.create(java.util.concurrent.Executor, java.util.Collection<org.apache.flink.runtime.checkpoint.CompletedCheckpoint>, org.apache.flink.runtime.jobgraph.RestoreMode) must be the same object as the input parameter, otherwise
the state may be deleted by mistake.
After FLINK-25872, CheckpointsCleaner.cleanSubsumedCheckpoints(long, java.util.Set<java.lang.Long>, java.lang.Runnable, java.util.concurrent.Executor) should be called explicitly here.
addCheckpointAndSubsumeOldestOne 在接口中 CompletedCheckpointStoreExceptionpublic void shutdown(org.apache.flink.api.common.JobStatus jobStatus,
CheckpointsCleaner checkpointsCleaner)
throws Exception
CompletedCheckpointStoreThe job status is forwarded and used to decide whether state should actually be discarded
or kept. SharedStateRegistry.unregisterUnusedState(long) and CheckpointsCleaner.cleanSubsumedCheckpoints(long, java.util.Set<java.lang.Long>, java.lang.Runnable, java.util.concurrent.Executor) should be called here to subsume unused state.
shutdown 在接口中 CompletedCheckpointStorejobStatus - Job state on shut downcheckpointsCleaner - that will cleanup completed checkpoints if neededExceptionpublic List<CompletedCheckpoint> getAllCheckpoints() throws Exception
CompletedCheckpointStoreCompletedCheckpoint instances.
Returns an empty list if no checkpoint has been added yet.
getAllCheckpoints 在接口中 CompletedCheckpointStoreExceptionpublic int getNumberOfRetainedCheckpoints()
CompletedCheckpointStorepublic int getMaxNumberOfRetainedCheckpoints()
CompletedCheckpointStorepublic boolean requiresExternalizedCheckpoints()
CompletedCheckpointStorerequiresExternalizedCheckpoints 在接口中 CompletedCheckpointStorepublic SharedStateRegistry getSharedStateRegistry()
CompletedCheckpointStoreSharedStateRegistry used to register the shared state.Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.