1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//! Event source abstraction.
//!
//! `LiveTable` consumes [`LiveEvent`]s from anything that implements
//! [`LiveStream`]. The most useful real-world implementor is SurrealDB's
//! LIVE query (see `vantage-surrealdb`), but the trait is deliberately
//! generic — Kafka, Postgres LISTEN/NOTIFY, Mongo change streams, or any
//! ad-hoc event bus can drive a LiveTable.
//!
//! In v1 every event invalidates the entire `cache_key`, so the variant
//! distinction is informational; we keep the per-id variants for forward
//! compatibility with surgical invalidation.
use Stream;
use Pin;
pub use ManualLiveStream;
/// A single change event observed at the master. Variants are forward-
/// compatible with future surgical invalidation.
/// Source of [`LiveEvent`]s. Subscribers each get an independent stream.