public interface SegmentedBytesStore extends StateStore
RocksDBSegmentedBytesStore
Modifier and Type | Interface and Description |
---|---|
static interface |
SegmentedBytesStore.KeySchema |
Modifier and Type | Method and Description |
---|---|
KeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> |
all()
Gets all the key-value pairs in the existing windows.
|
KeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> |
fetch(org.apache.kafka.common.utils.Bytes keyFrom,
org.apache.kafka.common.utils.Bytes keyTo,
long from,
long to)
Fetch all records from the segmented store in the provided key range and time range
from all existing segments
|
KeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> |
fetch(org.apache.kafka.common.utils.Bytes key,
long from,
long to)
Fetch all records from the segmented store with the provided key and time range
from all existing segments
|
KeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> |
fetchAll(long from,
long to)
Gets all the key-value pairs that belong to the windows within in the given time range.
|
byte[] |
get(org.apache.kafka.common.utils.Bytes key)
Get the record from the store with the given key.
|
void |
put(org.apache.kafka.common.utils.Bytes key,
byte[] value)
Write a new value to the store with the provided key.
|
void |
remove(org.apache.kafka.common.utils.Bytes key)
Remove the record with the provided key.
|
close, flush, init, isOpen, name, persistent
KeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> fetch(org.apache.kafka.common.utils.Bytes key, long from, long to)
key
- the key to matchfrom
- earliest time to matchto
- latest time to matchKeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> fetch(org.apache.kafka.common.utils.Bytes keyFrom, org.apache.kafka.common.utils.Bytes keyTo, long from, long to)
keyFrom
- The first key that could be in the rangekeyTo
- The last key that could be in the rangefrom
- earliest time to matchto
- latest time to matchKeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> all()
<Windowed<K>, value>
InvalidStateStoreException
- if the store is not initializedKeyValueIterator<org.apache.kafka.common.utils.Bytes,byte[]> fetchAll(long from, long to)
from
- the beginning of the time slot from which to searchto
- the end of the time slot from which to search<Windowed<K>, value>
InvalidStateStoreException
- if the store is not initializedjava.lang.NullPointerException
- if null is used for any keyvoid remove(org.apache.kafka.common.utils.Bytes key)
SegmentedBytesStore.KeySchema
key
- the segmented key to removevoid put(org.apache.kafka.common.utils.Bytes key, byte[] value)
SegmentedBytesStore.KeySchema
key
- value
- byte[] get(org.apache.kafka.common.utils.Bytes key)
SegmentedBytesStore.KeySchema
key
-