Class ForStNativeFullSnapshotStrategy<K>
java.lang.Object
org.apache.flink.state.forst.snapshot.ForStSnapshotStrategyBase<K,ForStSnapshotStrategyBase.ForStNativeSnapshotResources>
org.apache.flink.state.forst.snapshot.ForStNativeFullSnapshotStrategy<K>
- Type Parameters:
K- type of the backend keys.
- All Implemented Interfaces:
AutoCloseable,org.apache.flink.api.common.state.CheckpointListener,org.apache.flink.runtime.state.SnapshotStrategy<org.apache.flink.runtime.state.KeyedStateHandle,ForStSnapshotStrategyBase.ForStNativeSnapshotResources>
- Direct Known Subclasses:
ForStIncrementalSnapshotStrategy
public class ForStNativeFullSnapshotStrategy<K>
extends ForStSnapshotStrategyBase<K,ForStSnapshotStrategyBase.ForStNativeSnapshotResources>
Snapshot strategy for
ForStKeyedStateBackend that is based
on disableFileDeletions()+getLiveFiles() of ForSt and creates full snapshots.-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.flink.state.forst.snapshot.ForStSnapshotStrategyBase
ForStSnapshotStrategyBase.ForStNativeSnapshotResources, ForStSnapshotStrategyBase.ForStSnapshotOperation, ForStSnapshotStrategyBase.ForStSyncSnapshotResources, ForStSnapshotStrategyBase.PreviousSnapshotNested classes/interfaces inherited from interface org.apache.flink.runtime.state.SnapshotStrategy
org.apache.flink.runtime.state.SnapshotStrategy.SnapshotResultSupplier<S extends org.apache.flink.runtime.state.StateObject> -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final ForStStateDataTransferThe help class used to upload state files.Fields inherited from class org.apache.flink.state.forst.snapshot.ForStSnapshotStrategyBase
backendUID, db, EMPTY_PREVIOUS_SNAPSHOT, keyGroupPrefixBytes, keyGroupRange, keySerializer, kvStateInformation, resourceContainer, resourceGuard -
Constructor Summary
ConstructorsConstructorDescriptionForStNativeFullSnapshotStrategy(String description, org.forstdb.RocksDB db, org.apache.flink.util.ResourceGuard resourceGuard, ForStResourceContainer resourceContainer, org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer, LinkedHashMap<String, ForStOperationUtils.ForStKvStateInfo> kvStateInformation, org.apache.flink.runtime.state.KeyGroupRange keyGroupRange, int keyGroupPrefixBytes, UUID backendUID, ForStStateDataTransfer stateTransfer) ForStNativeFullSnapshotStrategy(org.forstdb.RocksDB db, org.apache.flink.util.ResourceGuard resourceGuard, ForStResourceContainer resourceContainer, org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer, LinkedHashMap<String, ForStOperationUtils.ForStKvStateInfo> kvStateInformation, org.apache.flink.runtime.state.KeyGroupRange keyGroupRange, int keyGroupPrefixBytes, UUID backendUID, ForStStateDataTransfer stateTransfer) -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.flink.runtime.state.SnapshotStrategy.SnapshotResultSupplier<org.apache.flink.runtime.state.KeyedStateHandle>asyncSnapshot(ForStSnapshotStrategyBase.ForStNativeSnapshotResources syncPartResource, long checkpointId, long timestamp, org.apache.flink.runtime.state.CheckpointStreamFactory streamFactory, org.apache.flink.runtime.checkpoint.CheckpointOptions checkpointOptions) voidclose()voidnotifyCheckpointAborted(long abortedCheckpointId) voidnotifyCheckpointComplete(long checkpointId) snapshotMetaData(long checkpointId, List<org.apache.flink.runtime.state.metainfo.StateMetaInfoSnapshot> stateMetaInfoSnapshots) syncPrepareResources(long checkpointId) Methods inherited from class org.apache.flink.state.forst.snapshot.ForStSnapshotStrategyBase
cleanupIncompleteSnapshot, getDescription, materializeMetaData
-
Field Details
-
stateTransfer
The help class used to upload state files.
-
-
Constructor Details
-
ForStNativeFullSnapshotStrategy
public ForStNativeFullSnapshotStrategy(@Nonnull org.forstdb.RocksDB db, @Nonnull org.apache.flink.util.ResourceGuard resourceGuard, @Nonnull ForStResourceContainer resourceContainer, @Nonnull org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer, @Nonnull LinkedHashMap<String, ForStOperationUtils.ForStKvStateInfo> kvStateInformation, @Nonnull org.apache.flink.runtime.state.KeyGroupRange keyGroupRange, int keyGroupPrefixBytes, @Nonnull UUID backendUID, @Nonnull ForStStateDataTransfer stateTransfer) -
ForStNativeFullSnapshotStrategy
public ForStNativeFullSnapshotStrategy(@Nonnull String description, @Nonnull org.forstdb.RocksDB db, @Nonnull org.apache.flink.util.ResourceGuard resourceGuard, @Nonnull ForStResourceContainer resourceContainer, @Nonnull org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer, @Nonnull LinkedHashMap<String, ForStOperationUtils.ForStKvStateInfo> kvStateInformation, @Nonnull org.apache.flink.runtime.state.KeyGroupRange keyGroupRange, int keyGroupPrefixBytes, @Nonnull UUID backendUID, @Nonnull ForStStateDataTransfer stateTransfer)
-
-
Method Details
-
snapshotMetaData
protected ForStSnapshotStrategyBase.PreviousSnapshot snapshotMetaData(long checkpointId, @Nonnull List<org.apache.flink.runtime.state.metainfo.StateMetaInfoSnapshot> stateMetaInfoSnapshots) - Specified by:
snapshotMetaDatain classForStSnapshotStrategyBase<K,ForStSnapshotStrategyBase.ForStNativeSnapshotResources>
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein classForStSnapshotStrategyBase<K,ForStSnapshotStrategyBase.ForStNativeSnapshotResources>
-
notifyCheckpointAborted
public void notifyCheckpointAborted(long abortedCheckpointId) -
notifyCheckpointComplete
- Throws:
Exception
-
syncPrepareResources
public ForStSnapshotStrategyBase.ForStNativeSnapshotResources syncPrepareResources(long checkpointId) throws Exception - Throws:
Exception
-
asyncSnapshot
public org.apache.flink.runtime.state.SnapshotStrategy.SnapshotResultSupplier<org.apache.flink.runtime.state.KeyedStateHandle> asyncSnapshot(ForStSnapshotStrategyBase.ForStNativeSnapshotResources syncPartResource, long checkpointId, long timestamp, @Nonnull org.apache.flink.runtime.state.CheckpointStreamFactory streamFactory, @Nonnull org.apache.flink.runtime.checkpoint.CheckpointOptions checkpointOptions)
-