Class RocksDBStateUploader
- java.lang.Object
-
- org.apache.flink.contrib.streaming.state.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 void
close()
List<IncrementalKeyedStateHandle.HandleAndLocalPath>
uploadFilesToCheckpointFs(List<Path> files, CheckpointStreamFactory checkpointStreamFactory, CheckpointedStateScope stateScope, CloseableRegistry closeableRegistry, 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<IncrementalKeyedStateHandle.HandleAndLocalPath> uploadFilesToCheckpointFs(@Nonnull List<Path> files, CheckpointStreamFactory checkpointStreamFactory, CheckpointedStateScope stateScope, CloseableRegistry closeableRegistry, 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:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
-