faust.stores.rocksdb

RocksDB storage.

class faust.stores.rocksdb.DB[source]

Dummy DB.

class faust.stores.rocksdb.Options[source]

Dummy Options.

class faust.stores.rocksdb.PartitionDB(*args, **kwargs)[source]

Tuple of (partition, rocksdb.DB).

partition

Alias for field number 0

db

Alias for field number 1

class faust.stores.rocksdb.RocksDBOptions(max_open_files: int = None, write_buffer_size: int = None, max_write_buffer_number: int = None, target_file_size_base: int = None, block_cache_size: int = None, block_cache_compressed_size: int = None, bloom_filter_size: int = None, **kwargs) → None[source]

Options required to open a RocksDB database.

max_open_files = 943719
write_buffer_size = 67108864
max_write_buffer_number = 3
target_file_size_base = 67108864
block_cache_size = 2147483648
block_cache_compressed_size = 524288000
bloom_filter_size = 3
open(path: pathlib.Path, *, read_only: bool = False) → faust.stores.rocksdb.DB[source]
Return type

DB

as_options() → faust.stores.rocksdb.Options[source]
Return type

Options

class faust.stores.rocksdb.Store(url: Union[str, yarl.URL], app: faust.types.app.AppT, table: faust.types.tables.CollectionT, *, key_index_size: int = 10000, options: Mapping = None, **kwargs) → None[source]

RocksDB table storage.

offset_key = b'__faust\x00offset__'
options = None

Used to configure the RocksDB settings for table stores.

key_index_size = None

Decides the size of the K=>TopicPartition index (10_000).

persisted_offset(tp: faust.types.tuples.TP) → Optional[int][source]
Return type

Optional[int]

set_persisted_offset(tp: faust.types.tuples.TP, offset: int) → None[source]
Return type

None

apply_changelog_batch(batch: Iterable[faust.types.events.EventT], to_key: Callable[Any, Any], to_value: Callable[Any, Any]) → None[source]
Return type

None

revoke_partitions(table: faust.types.tables.CollectionT, tps: Set[faust.types.tuples.TP]) → None[source]
Return type

None

coroutine assign_partitions(self, table: faust.types.tables.CollectionT, tps: Set[faust.types.tuples.TP]) → None[source]
Return type

None

logger = <Logger faust.stores.rocksdb (WARNING)>
coroutine need_active_standby_for(self, tp: faust.types.tuples.TP) → bool[source]
Return type

bool

coroutine on_rebalance(self, table: faust.types.tables.CollectionT, assigned: Set[faust.types.tuples.TP], revoked: Set[faust.types.tuples.TP], newly_assigned: Set[faust.types.tuples.TP]) → None[source]
Return type

None

reset_state() → None[source]
Return type

None

partition_path(partition: int) → pathlib.Path[source]
Return type

Path

with_suffix(path: pathlib.Path, *, suffix: str = '.db') → pathlib.Path[source]
Return type

Path

path
Return type

Path

basename
Return type

Path