Class RocksDBFullSnapshotResources<K>

  • All Implemented Interfaces:
    org.apache.flink.runtime.state.FullSnapshotResources<K>, org.apache.flink.runtime.state.SnapshotResources

    public class RocksDBFullSnapshotResources<K>
    extends Object
    implements org.apache.flink.runtime.state.FullSnapshotResources<K>
    A FullSnapshotResources for the RocksDB backend.
    • Constructor Detail

      • RocksDBFullSnapshotResources

        public RocksDBFullSnapshotResources​(org.apache.flink.util.ResourceGuard.Lease lease,
                                            org.rocksdb.Snapshot snapshot,
                                            List<RocksDBKeyedStateBackend.RocksDbKvStateInfo> metaDataCopy,
                                            List<org.apache.flink.runtime.state.heap.HeapPriorityQueueStateSnapshot<?>> heapPriorityQueuesSnapshots,
                                            List<org.apache.flink.runtime.state.metainfo.StateMetaInfoSnapshot> stateMetaInfoSnapshots,
                                            org.rocksdb.RocksDB db,
                                            int keyGroupPrefixBytes,
                                            org.apache.flink.runtime.state.KeyGroupRange keyGroupRange,
                                            org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer,
                                            org.apache.flink.runtime.state.StreamCompressionDecorator streamCompressionDecorator)
    • Method Detail

      • create

        public static <K> RocksDBFullSnapshotResources<K> create​(LinkedHashMap<String,​RocksDBKeyedStateBackend.RocksDbKvStateInfo> kvStateInformation,
                                                                 Map<String,​org.apache.flink.runtime.state.heap.HeapPriorityQueueSnapshotRestoreWrapper<?>> registeredPQStates,
                                                                 org.rocksdb.RocksDB db,
                                                                 org.apache.flink.util.ResourceGuard rocksDBResourceGuard,
                                                                 org.apache.flink.runtime.state.KeyGroupRange keyGroupRange,
                                                                 org.apache.flink.api.common.typeutils.TypeSerializer<K> keySerializer,
                                                                 int keyGroupPrefixBytes,
                                                                 org.apache.flink.runtime.state.StreamCompressionDecorator keyGroupCompressionDecorator)
                                                          throws IOException
        Throws:
        IOException
      • createKVStateIterator

        public org.apache.flink.runtime.state.KeyValueStateIterator createKVStateIterator()
                                                                                   throws IOException
        Specified by:
        createKVStateIterator in interface org.apache.flink.runtime.state.FullSnapshotResources<K>
        Throws:
        IOException
      • getMetaInfoSnapshots

        public List<org.apache.flink.runtime.state.metainfo.StateMetaInfoSnapshot> getMetaInfoSnapshots()
        Specified by:
        getMetaInfoSnapshots in interface org.apache.flink.runtime.state.FullSnapshotResources<K>
      • getKeyGroupRange

        public org.apache.flink.runtime.state.KeyGroupRange getKeyGroupRange()
        Specified by:
        getKeyGroupRange in interface org.apache.flink.runtime.state.FullSnapshotResources<K>
      • getKeySerializer

        public org.apache.flink.api.common.typeutils.TypeSerializer<K> getKeySerializer()
        Specified by:
        getKeySerializer in interface org.apache.flink.runtime.state.FullSnapshotResources<K>
      • getStreamCompressionDecorator

        public org.apache.flink.runtime.state.StreamCompressionDecorator getStreamCompressionDecorator()
        Specified by:
        getStreamCompressionDecorator in interface org.apache.flink.runtime.state.FullSnapshotResources<K>
      • release

        public void release()
        Specified by:
        release in interface org.apache.flink.runtime.state.SnapshotResources