Add TVU ASCII art

This commit is contained in:
Greg Fitzgerald 2018-06-14 18:05:12 -06:00
parent 94ededb54c
commit 22885c3e64
1 changed files with 47 additions and 20 deletions

View File

@ -1,24 +1,51 @@
//! The `tvu` module implements the Transaction Validation Unit, a
//! 5-stage transaction validation pipeline in software.
//! 1. streamer
//! - Incoming blobs are picked up from the replicate socket.
//! 2. verifier
//! - TODO Blobs are sent to the GPU, and while the memory is there the PoH stream is verified
//! along with the ecdsa signature for the blob and each signature in all the transactions. Blobs
//! with errors are dropped, or marked for slashing.
//! 3.a retransmit
//! - Blobs originating from the parent (leader, at the moment, is the only parent), are retransmit to all the
//! peers in the crdt. Peers is everyone who is not me or the leader that has a known replicate
//! address.
//! 3.b window
//! - Verified blobs are placed into a window, indexed by the counter set by the leader.sockets. This could
//! be the PoH counter if its monotonically increasing in each blob. Erasure coding is used to
//! recover any missing packets, and requests are made at random to peers and parents to retransmit
//! a missing packet.
//! 4. accountant
//! - Contigous blobs are sent to the accountant for processing transactions
//! 5. validator
//! - TODO Validation messages are sent back to the leader
//! 3-stage transaction validation pipeline in software.
//!
//! ```text
//! .----------------------------------------.
//! | TVU |
//! | |
//! | |
//! | |
//! | |
//! | .-------. .--------. .-----------. |
//! .--------. | | Blob | | Window | | Replicate | | .------------.
//! | Leader |--->| Fetch |->| Stage |->| Stage |---->| Validators |
//! `--------` | | Stage | | | | | | `------------`
//! | `-------` `----+---` `----+------` |
//! | | | |
//! | | | |
//! | | | |
//! | | | |
//! `------------------|-----------|---------`
//! | |
//! v v
//! .--------. .------.
//! | Window | | Bank |
//! `--------` `------`
//! ```
//
// TODO: @aeyakovenko, these comments no longer refect the code in this module:
// 1. streamer
// - Incoming blobs are picked up from the replicate socket.
// 2. verifier
// - TODO Blobs are sent to the GPU, and while the memory is there the PoH stream is verified
// along with the ecdsa signature for the blob and each signature in all the transactions. Blobs
// with errors are dropped, or marked for slashing.
// 3.a retransmit
// - Blobs originating from the parent (leader, at the moment, is the only parent), are retransmit to all the
// peers in the crdt. Peers is everyone who is not me or the leader that has a known replicate
// address.
// 3.b window
// - Verified blobs are placed into a window, indexed by the counter set by the leader.sockets. This could
// be the PoH counter if its monotonically increasing in each blob. Erasure coding is used to
// recover any missing packets, and requests are made at random to peers and parents to retransmit
// a missing packet.
// 4. accountant
// - Contigous blobs are sent to the accountant for processing transactions
// 5. validator
// - TODO Validation messages are sent back to the leader
//
use bank::Bank;
use blob_fetch_stage::BlobFetchStage;