Expand description
Quorum-broadcast fan-out logic: post_once, post_and_classify, broadcast_*_quorum, bulk_catchup_push.
Functions§
- broadcast_
archive_ quorum - v0.6.2 (S29): fan out a just-archived memory id to every peer. Payload
rides on
sync_pushviaarchives: [id], mirroring the shape used bybroadcast_delete_quorumfor deletions. On the receiving peer,sync_pushcallsdb::archive_memoryto move the row intoarchived_memories— unlike the delete path this is a soft removal (the row remains queryable via/api/v1/archive). - broadcast_
consolidate_ quorum - v0.6.2 (#326): fan out a consolidation in a single
sync_push— the new consolidated memory + the source ids being deleted. Mirrors the local semantics ofdb::consolidate(insert new + delete sources) so peers end up in the same terminal state as the originator. - broadcast_
delete_ quorum - Fan out a tombstone for
idto every configured peer via the extendedsync_pushbody (deletions: [id]). Same quorum contract asbroadcast_store_quorum: local delete is recorded immediately, peer acks counted againstpolicy.write_quorum, deadline enforced, stragglers detached. - broadcast_
link_ quorum - v0.6.2 (#325): fan out a just-committed memory link to every peer.
Payload rides on
sync_pushvialinks: [link]. Same quorum contract asbroadcast_store_quorum. - broadcast_
namespace_ meta_ clear_ quorum - v0.6.2 (S35 follow-up): fan out a namespace-standard clear to peers
via
sync_push.namespace_meta_clears. PR #363 shipped set-side fanout viabroadcast_namespace_meta_quorumbut left the clear path local-only — alice clearing on node-1 didn’t propagate to bob on node-2, so the scenario-35 cross-peer clear assertion failed. - broadcast_
namespace_ meta_ quorum - v0.6.2 (S35): fan out a
namespace_metarow (the(namespace, standard_id, parent_namespace)tuple set byset_namespace_standard) to peers viasync_push.namespace_meta. Without this, peers see the standard memory (already fanned out viabroadcast_store_quorum) but not the meta row tying it to a namespace + parent — so the parent-chain walk on the peer falls through toauto_detect_parentand can return a different ancestor than the originator. - broadcast_
pending_ decision_ quorum - v0.6.2 (S34): fan out a pending-action decision (approve/reject) to
peers via
sync_push.pending_decisions. Without this, an approve on node-2 leaves the row instatus='pending'on node-1 and the caller sees inconsistent governance state across the cluster. Peers apply viadb::decide_pending_actionwhich is a no-op on already-decided rows — replay-safe. - broadcast_
pending_ quorum - v0.6.2 (S34): fan out a just-created pending-action row to every peer
via
sync_push.pendings. Callers pass the fully-hydratedPendingActionread from their localpending_actionstable so peers can upsert it with the same id / status / approvals tuple the originator has. Mirrors the quorum semantics ofbroadcast_store_quorum— local pending row is already persisted at call time; peer acks are counted againstpolicy.write_quorum. - broadcast_
restore_ quorum - v0.6.2 (S29): fan out a just-restored memory id to every peer. Payload
rides on
sync_pushviarestores: [id], mirroring the shape used bybroadcast_archive_quorum. On the receiving peer,sync_pushmoves the row fromarchived_memoriesback intomemoriesviadb::restore_archived. If the peer never saw the archive or the row isn’t in its archive table, the sync call no-ops (same missing-on-peer posture used for archives and deletions). - broadcast_
store_ quorum - Fan out a just-committed memory to every configured peer. Returns
an
AckTrackerwhosefinalise()you then call against the deadline to get the quorum outcome. - broadcast_
store_ quorum_ with_ embedding - #1566 / #1579 B1 —
broadcast_store_quorumvariant that ships the source-side embedding vector alongside the memory row (embed-once-replicate-vector). WhenshippedisSome, the push body carries anembeddings: [ShippedEmbedding]array INSIDE the signed payload so dim-matching receivers store the vector directly instead of re-embedding (~1s/row via ollama, paid up to 9× across the fleet pre-#1566).Nonepreserves the exact pre-#1566 wire bytes (noembeddingskey at all) — older peers and embedder-less senders are unaffected. - bulk_
catchup_ push - v0.6.2 Patch 2 (S40): post-fanout catchup for
bulk_create.