code wiki / _hdl_build / nx_gossip.nx
nx_gossip.nx
buildroot/runtime/_hdl_build/nx_gossip.nx
about
nx_gossip.nx -- LIB: EPIDEMIC / ANTI-ENTROPY gossip so the Napster index spreads across the mesh with NO central
bottleneck (operator: "lots of peers can share with lots of peers ... spoke to spoke or hub to hub"). Each node
holds a local content registry (nx_dist_index rows). A gossip round reconciles two nodes: exchange a compact
DIGEST (the set of cids each holds) -> each side selects the rows the other LACKS -> merge (idempotent by cid).
After a symmetric round both nodes hold the UNION -> run pairwise across the mesh and knowledge converges
epidemically. Composes nx_dist_index (row parsing, di_has_cid). No TLS. license_tier: ORIGINAL
dependencies 2 imports · 2 importers
imports: nx_dist_index.nxnx_syscalls.nx
imported by: nx_gossip_gate.nxnx_hub_replicate_gate.nx
structs
| none |
consts
| none |
functions
| 11 | func gossip_digest(reg: *u8, rlen: i64, out: *u8) -> i64 |
| 22 | func gossip_digest_has(digest: *u8, dlen: i64, cid: *u8) -> i64 |
| 32 | func gossip_select(my_reg: *u8, mlen: i64, peer_digest: *u8, dlen: i64, out: *u8) -> i64 |
| 46 | func gossip_merge(dst: *u8, dlen: i64, incoming: *u8, ilen: i64) -> i64 |