-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(header-accumulator): clean up README
- Loading branch information
1 parent
7e8c6c3
commit 5d4a99d
Showing
2 changed files
with
42 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,57 @@ | ||
# Header accumulator | ||
# Header Accumulator | ||
|
||
This crate is used to accumulate block headers and compare them | ||
against header accumulators. This process is used to verify the authenticity of these blocks. | ||
`header_accumulator` is a Rust library used to accumulate and verify | ||
block headers by comparing them against header accumulators, helping | ||
to ensure the authenticity of blockchain data. This crate is designed | ||
primarily for use as a library, requiring parsed blocks as input. | ||
|
||
the header_accumulator is more intended to be used as a library, since it needs to be fed blocks that have to be parsed first. | ||
## Overview | ||
|
||
Check out the crate documentation in your browser by running, from | ||
the root of the `veemon` workspace: | ||
|
||
```terminal | ||
cd crates/header-accumulator && cargo doc --open | ||
``` | ||
|
||
## Getting Started | ||
|
||
### Prerequisites | ||
|
||
- [Rust (stable)](https://www.rust-lang.org/tools/install) | ||
- Cargo (Comes with Rust by default) | ||
- Cargo (included with Rust by default) | ||
- [protoc](https://grpc.io/docs/protoc-installation/) | ||
|
||
## Features | ||
|
||
- `era_validate`: Validates entire ERAs of flat files against Header Accumulators. Use this command to ensure data integrity across different ERAs. | ||
|
||
- `generate_inclusion_proof`: Generates inclusion proofs for a range of blocks. This is useful for verifying the presence of specific blocks within a dataset. | ||
|
||
- `verify_inclusion_proof`: Verifies inclusion proofs for a range of blocks. Use it to confirm the accuracy of inclusion proofs you have. | ||
- **`era_validate`**: Validates entire ERAs of flat files against | ||
Header Accumulators. Use this command to ensure data integrity across | ||
multiple ERAs. | ||
- **`generate_inclusion_proof`**: Generates inclusion proofs for a | ||
specified range of blocks, useful for verifying the presence of | ||
specific blocks within a dataset. | ||
- **`verify_inclusion_proof`**: Verifies inclusion proofs for a | ||
specified range of blocks. Use this to confirm the accuracy of | ||
inclusion proofs. | ||
|
||
### Options | ||
|
||
- `-h, --help`: Display a help message that includes usage, commands, and options. | ||
|
||
- `-h, --help`: Displays a help message that includes usage | ||
information, commands, and options. | ||
|
||
## Goals | ||
|
||
Our goal is to provide a tool that can be used to verify blocks from [StreamingFast's Firehose](https://firehose.streamingfast.io/). | ||
It is used in unity with flat [flat-files-decoder](https://github.com/semiotic-ai/flat-files-decoder) in [flat_head](https://github.com/semiotic-ai/flat_head) to achieve a solution. | ||
|
||
|
||
|
||
|
||
The main objective of this library is to provide a tool for verifying | ||
blocks from [StreamingFast Firehose](https://firehose.streamingfast.io/). | ||
It works in conjunction with [flat-files-decoder](https://github.com/semiotic-ai/flat-files-decoder) | ||
to offer a comprehensive solution. | ||
|
||
## Testing | ||
Some tests depend on [flat-files-decoder](https://github.com/semiotic-ai/flat-files-decoder) to work, so it is used as a development dependency. | ||
|
||
Run `cargo test` to test all functionalities. | ||
Some tests depend on [flat-files-decoder](https://github.com/semiotic-ai/flat-files-decoder) as a development dependency. | ||
|
||
### Coverage | ||
Run all tests with: | ||
|
||
Generate code coverage reports with `cargo llvm-cov --html` and open them with `open ./target/llvm-cov/html/index.html`. | ||
```terminal | ||
cargo test | ||
``` |