diff options
| author | tv <tv@krebsco.de> | 2026-11-29 04:00:43 +0000 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-11-29 04:00:43 +0000 |
| commit | 2ae7562083f5f96490f90e9398762cf6a024d51e (patch) | |
| tree | 5e23c6bda5682e39413fe557348023cc4204d487 /src/swarm/tree.rs | |
| parent | f497cf6ef14de8204bc1edec078116593d791b97 (diff) | |
document: a unit's name, which the swarm passes on by
document::UnitId: the name of a unit of a document as its kind has it,
an Automerge change's hash. What the swarm announces, forwards along
trees, tells a peer it refused and drops is named so (the
dissemination, relay, refusals, AppState::drop_taken), and the session
is told so what a peer gets from another; a change's hash it is where
the document is asked, and on the wire.
Diffstat (limited to 'src/swarm/tree.rs')
| -rw-r--r-- | src/swarm/tree.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/swarm/tree.rs b/src/swarm/tree.rs index 4d5afd8..0dd4e31 100644 --- a/src/swarm/tree.rs +++ b/src/swarm/tree.rs @@ -388,7 +388,7 @@ pub(crate) async fn note_arrival( peer: &str, writer: Option<u64>, carried: bool, - authors: &[(String, Vec<crate::document::ChangeHash>)], + authors: &[(String, Vec<crate::document::UnitId>)], ) { match writer { Some(writer) if carried => { @@ -663,7 +663,7 @@ pub(crate) async fn forward( state: &AppState, writer: u64, from: &str, - changes: &[crate::document::ChangeHash], + changes: &[crate::document::UnitId], ) -> Option<Plan> { let plan = plan(state, writer).await?; Some(crate::swarm::dissemination::pass_on(state, writer, from, changes, plan).await) @@ -688,7 +688,7 @@ impl crate::swarm::dissemination::Dissemination for WritersTrees { state: &AppState, writer: u64, from: &str, - changes: &[crate::document::ChangeHash], + changes: &[crate::document::UnitId], ) -> Option<Plan> { forward(state, writer, from, changes).await } @@ -699,7 +699,7 @@ impl crate::swarm::dissemination::Dissemination for WritersTrees { peer: &str, writer: Option<u64>, carried: bool, - authors: &[(String, Vec<crate::document::ChangeHash>)], + authors: &[(String, Vec<crate::document::UnitId>)], ) { note_arrival(state, peer, writer, carried, authors).await; } |
