Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Improve the abortable broadcast documentation #3260

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 16 additions & 25 deletions rs/p2p/consensus_manager/README.adoc
Original file line number Diff line number Diff line change
@@ -1,35 +1,26 @@
= Abortable Broadcast
:toc:

== Overview

This library implements the https://arxiv.org/abs/2410.22080[_Abortable Broadcast_] primitive.

Currently, the implementation has some limitations that restrict its generalization:
== Background

- **ArtifactAssembler coupling**: The implementation is tightly coupled with the `ArtifactAssembler`, reducing modularity.
- **Slot table deletions**: Deletions in the slot table are not propagated, which lead to inconsistencies.
[quote, Internet Computer for Geeks]
To guarantee liveness, the Internet Computer Protocol assumes a form of partial synchrony, which (roughly stated) says that the network will
be periodically synchronous for short intervals of time. In such intervals of synchrony, all undelivered messages will be delivered in less than time δ, for some fixed bound δ.
The bound δ does not have to be known in advance (the protocol is initialized with a reasonable bound, but will dynamically adapt and increase this bound if it is too small).
Regardless of whether we are assuming an asynchronous or a partially synchronous network, we assume that every message sent from one honest replica to another will eventually be delivered.

== Requirements

[cols="3,3,3", options="header"]
|===
| **Capability** | **Purpose** | **Implementation Requirements**
== Overview

| **PubSub-like library**
| Simplifies application development by abstracting one-to-many communication within a set of nodes.
| The library must implement https://en.wikipedia.org/wiki/Eventual_consistency[_eventual consistency_].
This library provides an implementation of the https://arxiv.org/abs/2410.22080[Abortable Broadcast] primitive.
This mechanism ensures that any message sent from one honest party to all other honest parties will eventually be delivered, provided the message is still active (i.e., it has not been aborted).

| **Multitenancy of applications**
| Allows multiple applications to safely use the library, ensuring isolation and uninterrupted operation between all applications.
| Must implement fair scheduling across peers to ensure resource allocation and isolation.
=== Key Features
* Delivery Guarantee: Messages sent between honest parties are reliably delivered as long as they remain active.
* Dynamic Adaptability: The implementation dynamically adjusts to changing network conditions, ensuring reliable message delivery without requiring fixed, pre-defined timing bounds.
* Fault Tolerance: The implementation is robust against Byzantine, malicious, or otherwise faulty peers. It avoids slowing down the producer of data and prevents unbounded message buffering, even in the presence of adversarial behavior.
* Finite Active Messages Assumption: The design achieves efficiency and simplicity by leveraging the assumption that there is always a finite number of active messages in the system. This assumption ensures predictable resource usage and prevents attacks that might exploit excessive message production.
* Simplicity: The interface is designed to be intuitive, exposing a channel-like API for publishing messages to all peers in the subnet.

| **Operation in P2P networks with Byzantine peers**
| Ensures reliable message publishing and creation rates, even in networks with faulty or malicious nodes.
| The implementation must provide a non-IO-bound API and be memory-bounded.

| **Scalable and resource-efficient**
| Optimizes usage of shared resources (e.g., CPU, file descriptors) to maintain performance under high demand and prevent resource exhaustion.
| The library should expose a synchronous interface but implement asynchronous operations under the hood.
This design makes the abortable broadcast primitive well-suited for environments with partial synchrony, where the protocol must handle a mix of honest and potentially adversarial behavior while remaining reliable, efficient, and easy to use.

|===
Loading