Package org.apache.flink.state.rocksdb
Class RocksDBStateUploader
- java.lang.Object
-
- org.apache.flink.state.rocksdb.RocksDBStateUploader
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public class RocksDBStateUploader extends Object implements Closeable
Help class for uploading RocksDB state files.
-
-
Constructor Summary
Constructors Constructor Description RocksDBStateUploader(int numberOfSnapshottingThreads)RocksDBStateUploader(RocksDBStateDataTransferHelper transfer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()List<org.apache.flink.runtime.state.IncrementalKeyedStateHandle.HandleAndLocalPath>uploadFilesToCheckpointFs(List<Path> files, org.apache.flink.runtime.state.CheckpointStreamFactory checkpointStreamFactory, org.apache.flink.runtime.state.CheckpointedStateScope stateScope, org.apache.flink.core.fs.CloseableRegistry closeableRegistry, org.apache.flink.core.fs.CloseableRegistry tmpResourcesRegistry)Upload all the files to checkpoint fileSystem using specified number of threads.
-
-
-
Constructor Detail
-
RocksDBStateUploader
@VisibleForTesting public RocksDBStateUploader(int numberOfSnapshottingThreads)
-
RocksDBStateUploader
public RocksDBStateUploader(RocksDBStateDataTransferHelper transfer)
-
-
Method Detail
-
uploadFilesToCheckpointFs
public List<org.apache.flink.runtime.state.IncrementalKeyedStateHandle.HandleAndLocalPath> uploadFilesToCheckpointFs(@Nonnull List<Path> files, org.apache.flink.runtime.state.CheckpointStreamFactory checkpointStreamFactory, org.apache.flink.runtime.state.CheckpointedStateScope stateScope, org.apache.flink.core.fs.CloseableRegistry closeableRegistry, org.apache.flink.core.fs.CloseableRegistry tmpResourcesRegistry) throws Exception
Upload all the files to checkpoint fileSystem using specified number of threads.- Parameters:
files- The files will be uploaded to checkpoint filesystem.checkpointStreamFactory- The checkpoint streamFactory used to create outputstream.stateScope-- Throws:
Exception- Thrown if can not upload all the files.
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
-