Go to file
Weiliang Li 63b9ab8857 Rustfmt 2019-08-13 11:18:49 +02:00
src Rustfmt 2019-08-13 11:18:49 +02:00
.gitignore Rustfmt 2019-08-13 11:18:49 +02:00
.rustfmt.toml Rustfmt 2019-08-13 11:18:49 +02:00
Cargo.toml Update Cargo.toml 2019-07-25 16:14:41 +02:00
LICENSE Add license. 2018-07-19 20:45:39 -07:00
README.md Rustfmt 2019-08-13 11:18:49 +02:00
gdb-node Updates. 2018-10-12 12:56:10 -07:00
ltrace-node Updates. 2018-10-12 12:56:10 -07:00
run-node Debug log batch output, tweak logging env var use. 2018-12-03 14:49:23 -08:00
valgrind-node Updates. 2018-10-12 12:56:10 -07:00

README.md

Hydrabadger

An experimental peer-to-peer client using the Honey Badger Byzantine Fault Tolerant consensus algorithm.

Usage

Running a test peer

  1. git clone https://github.com/poanetwork/hydrabadger
  2. cd hydrabadger
  3. ./run-node 0

Additional peers

  1. Open a new terminal window.
  2. cd {...}/hydrabadger
  3. ./run-node 1
  4. (Repeat 1 and 2), ./run-node 2, ./run-node 3, ./run-node 4
    • Note: If your terminal has tabs, open multiple tabs and use ctrl-pgup/pgdown to cycle between tabs quickly.

Each peer will generate a number of random transactions at regular intervals, process them accordingly, and output complete batches. If your terminal is spammed with batch outputs, consensus is working.

Type ./run-node 0 --help or cargo run -- --help for command line options.

See the run-node script for additional optional environment variables that can be set. To turn on debug log output: export HYDRABADGER_LOG_ADDTL=debug and/or echo "export HYDRABADGER_LOG_ADDTL=debug" >> ~/.profile.

Current State

Network initialization node addition, transaction generation, consensus, and batch outputs are all generally working. Batch outputs for each epoch are printed to the log.

Overall the client is fragile and doesn't handle deviation from simple usage very well yet.

Unimplemented

  • Many edge cases and exceptions: disconnects, reconnects, etc.
    • Connecting to a network which is in the process of key generation causes the entire network to fail. For now, wait until the network starts outputting batches before connecting additional peer nodes.
  • Error handling is atrocious, most errors are simply printed to the log.
  • Usage as a library is still a work in progress as the API settles.
  • Much, much more...

License

License: LGPL v3.0

This project is licensed under the GNU Lesser General Public License v3.0. See the LICENSE file for details.