-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #79 from turbofish-org/cleanup
Cleanup
- Loading branch information
Showing
4 changed files
with
53 additions
and
16 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
[package] | ||
name = "merk" | ||
description = "Merkle key/value store" | ||
description = "High-performance Merkle key/value store" | ||
version = "2.0.0" | ||
authors = ["Matt Bell <[email protected]>"] | ||
authors = ["Turbofish <[email protected]>"] | ||
edition = "2018" | ||
license = "MIT" | ||
license = "Apache-2.0" | ||
|
||
[dependencies] | ||
thiserror= "1.0.58" | ||
|
@@ -40,5 +40,11 @@ optional = true | |
|
||
[features] | ||
default = ["full", "verify"] | ||
full = ["rand", "rocksdb", "colored", "num_cpus", "ed"] | ||
full = [ | ||
"rand", | ||
"rocksdb", | ||
"colored", | ||
"num_cpus", | ||
"ed", | ||
] | ||
verify = ["ed"] |
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,17 +1,23 @@ | ||
# merk | ||
<h1 align="left"> | ||
<picture> | ||
<source media="(prefers-color-scheme: dark)" srcset="./merk-dark.svg"> | ||
<source media="(prefers-color-scheme: light)" srcset="./merk.svg"> | ||
<img alt="merk" src="./merk.svg"> | ||
</picture> | ||
</h1> | ||
|
||
*High-performance Merkle key/value store* | ||
|
||
![CI](https://github.com/nomic-io/merk/actions/workflows/ci.yml/badge.svg) | ||
[![codecov](https://codecov.io/gh/nomic-io/merk/branch/develop/graph/badge.svg?token=TTUTSt2iLz)](https://codecov.io/gh/nomic-io/merk) | ||
![CI](https://github.com/turbofish-org/merk/actions/workflows/ci.yml/badge.svg) | ||
[![codecov](https://codecov.io/gh/turbofish-org/merk/branch/develop/graph/badge.svg?token=TTUTSt2iLz)](https://codecov.io/gh/turbofish-org/merk) | ||
[![Crate](https://img.shields.io/crates/v/merk.svg)](https://crates.io/crates/merk) | ||
[![API](https://docs.rs/merk/badge.svg)](https://docs.rs/merk) | ||
|
||
Merk is a crypto key/value store - more specifically, it's a Merkle AVL tree built on top of RocksDB (Facebook's fork of LevelDB). | ||
|
||
Its priorities are performance and reliability. While Merk was designed to be the state database for blockchains, it can also be used anywhere an auditable key/value store is needed. | ||
|
||
### FEATURES: | ||
### Features | ||
- **Fast reads/writes** - Reads have no overhead compared to a normal RocksDB store, and writes are optimized for batch operations (e.g. blocks in a blockchain). | ||
- **Fast proof generation** - Since Merk implements an AVL tree rather than a trie, it is very efficient to create and verify proofs for ranges of keys. | ||
- **Concurrency** - Unlike most other Merkle stores, all operations utilize all available cores - giving huge performance gains and allowing nodes to scale along with Moore's Law. | ||
|
@@ -20,6 +26,8 @@ Its priorities are performance and reliability. While Merk was designed to be th | |
- **Web-friendly** - Being written in Rust means it is easy to run the proof-verification code in browsers with WebAssembly, allowing for light-clients that can verify data for themselves. | ||
- **Fits any Profile** - Performant on RAM-constrained Raspberry Pi's and beefy validator rigs alike. | ||
|
||
The algorithms are based on AVL, but optimized for batches of operations and random fetches from the backing store. | ||
|
||
## Usage | ||
|
||
**Install:** | ||
|
@@ -44,12 +52,7 @@ let batch = [ | |
]; | ||
merk.apply(&batch).unwrap(); | ||
``` | ||
|
||
## Status | ||
|
||
Merk is being used in the [Nomic](https://github.com/nomic-io/nomic) Bitcoin Sidechain. | ||
|
||
The codebase has not been audited but has been throroughly tested and proves to be stable. | ||
Merk is currently used by [Nomic](https://github.com/nomic-io/nomic), a blockchain powering decentralized custody of Bitcoin, built on [Orga](https://github.com/turbofish-org/orga). | ||
|
||
## Benchmarks | ||
|
||
|
@@ -113,6 +116,28 @@ You can test these yourself by running `cargo bench`. | |
| Random reads | 2,370,000 | | ||
| Random proof generation | 497,000 | | ||
|
||
## Algorithm Details | ||
## Contributing | ||
|
||
Merk is an open-source project spearheaded by Turbofish. Anyone is able to contribute to Merk via GitHub. | ||
|
||
[Contribute to Merk](https://github.com/turbofish-org/merk/contribute) | ||
|
||
## Security | ||
|
||
Merk is currently undergoing security audits. | ||
|
||
Vulnerabilities should not be reported through public channels, including GitHub Issues. You can report a vulnerability via GitHub's Private Vulnerability Reporting or to Turbofish at `[email protected]`. | ||
|
||
[Report a Vulnerability](https://github.com/turbofish-org/merk/security/advisories/new) | ||
|
||
## License | ||
|
||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use the files in this repository except in compliance with the License. You may obtain a copy of the License at | ||
|
||
https://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. | ||
|
||
--- | ||
|
||
The algorithms are based on AVL, but optimized for batches of operations and random fetches from the backing store. Read about the algorithms here: https://github.com/nomic-io/merk/blob/develop/docs/algorithms.md | ||
Copyright © 2024 Turbofish, Inc. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.