faust.tables.objects

Storing objects in tables.

This is also used to store data structures such as sets/lists.

class faust.tables.objects.ChangeloggedObject(manager: faust.tables.objects.ChangeloggedObjectManager, key: Any) → None[source]

A changelogged object in a ChangeloggedObjectManager store.

sync_from_storage(value: Any) → None[source]
Return type

None

as_stored_value() → Any[source]
Return type

Any

apply_changelog_event(operation: int, value: Any) → None[source]
Return type

None

class faust.tables.objects.ChangeloggedObjectManager(table: faust.tables.table.Table, **kwargs) → None[source]

Store of changelogged objects.

send_changelog_event(key: Any, operation: int, value: Any) → None[source]
Return type

None

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

sync_from_storage() → None[source]
Return type

None

flush_to_storage() → None[source]
Return type

None

logger = <Logger faust.tables.objects (WARNING)>
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

coroutine on_recovery_completed(self, active_tps: Set[faust.types.tuples.TP], standby_tps: Set[faust.types.tuples.TP]) → None[source]
Return type

None

coroutine on_start(self) → None[source]

Service is starting.

Return type

None

coroutine on_stop(self) → None[source]

Service is being stopped/restarted.

Return type

None

reset_state() → None[source]
Return type

None

storage
Return type

StoreT[~KT, ~VT]

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

None