Skip to content

Commit cc56cd1

Browse files
authored
feat: rocksdb storage for AccountTree and NullifierTree by default (#1326)
1 parent 5ab03a7 commit cc56cd1

21 files changed

Lines changed: 493 additions & 116 deletions

File tree

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: "Install RocksDB dependencies"
2+
description: "Install dependencies for RocksDB compilation"
3+
4+
runs:
5+
using: "composite"
6+
steps:
7+
- name: Install LLVM/Clang for RocksDB
8+
shell: bash
9+
run: |
10+
set -eux
11+
sudo apt-get update
12+
# Install clang/llvm for bindgen (needed for FFI bindings).
13+
# RocksDB is compiled from source by librocksdb-sys.
14+
sudo apt-get install -y clang llvm-dev libclang-dev

.github/workflows/lint.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ jobs:
5151
runs-on: ubuntu-24.04
5252
steps:
5353
- uses: actions/checkout@main
54+
- name: Cleanup large tools for build space
55+
uses: ./.github/actions/cleanup-runner
56+
- name: Install RocksDB
57+
uses: ./.github/actions/install-rocksdb
5458
- name: Rustup
5559
run: |
5660
rustup update --no-self-update
@@ -87,6 +91,10 @@ jobs:
8791
runs-on: ubuntu-24.04
8892
steps:
8993
- uses: actions/checkout@main
94+
- name: Cleanup large tools for build space
95+
uses: ./.github/actions/cleanup-runner
96+
- name: Install RocksDB
97+
uses: ./.github/actions/install-rocksdb
9098
- name: Rustup
9199
run: rustup update --no-self-update
92100
- uses: Swatinem/rust-cache@v2

.github/workflows/publish-debian-all.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ jobs:
3131
uses: actions/checkout@main
3232
with:
3333
fetch-depth: 0
34+
- name: Install RocksDB
35+
uses: ./.github/actions/install-rocksdb
3436
- name: Build and Publish Node
3537
uses: ./.github/actions/debian
3638
with:

.github/workflows/publish-debian.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ jobs:
6060
with:
6161
fetch-depth: 0
6262

63+
- name: Install RocksDB
64+
uses: ./.github/actions/install-rocksdb
65+
6366
- name: Build and Publish Packages
6467
uses: ./.github/actions/debian
6568
with:

.github/workflows/publish-dry-run.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ jobs:
2323
fetch-depth: 0
2424
- name: Cleanup large tools for build space
2525
uses: ./.github/actions/cleanup-runner
26+
- name: Install RocksDB
27+
uses: ./.github/actions/install-rocksdb
2628
- name: Install dependencies
2729
run: sudo apt-get update && sudo apt-get install -y jq
2830
- name: Update Rust toolchain

.github/workflows/publish-main.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ jobs:
1818
with:
1919
fetch-depth: 0
2020
ref: main
21+
- name: Install RocksDB
22+
uses: ./.github/actions/install-rocksdb
2123
# Ensure the release tag refers to the latest commit on main.
2224
# Compare the commit SHA that triggered the workflow with the HEAD of the branch we just
2325
# checked out (main).

.github/workflows/stress-test-check.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,14 @@ env:
2323
jobs:
2424
stress-test-check:
2525
name: stress-test-check
26-
runs-on: ubuntu-24.04
27-
timeout-minutes: 10
26+
runs-on: Linux-ARM64-Runner
27+
timeout-minutes: 20
2828
steps:
2929
- uses: actions/checkout@main
30+
- name: Cleanup large tools for build space
31+
uses: ./.github/actions/cleanup-runner
32+
- name: Install RocksDB
33+
uses: ./.github/actions/install-rocksdb
3034
- name: Rustup
3135
run: rustup update --no-self-update
3236
- uses: Swatinem/rust-cache@v2

.github/workflows/test-beta.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ jobs:
1616
- uses: actions/checkout@v4
1717
with:
1818
ref: 'next'
19+
- name: Cleanup large tools for build space
20+
uses: ./.github/actions/cleanup-runner
21+
- name: Install RocksDB
22+
uses: ./.github/actions/install-rocksdb
1923
- name: Rustup
2024
run: rustup install beta && rustup default beta
2125
- uses: taiki-e/install-action@v2

.github/workflows/test.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ jobs:
2828
timeout-minutes: 30
2929
steps:
3030
- uses: actions/checkout@main
31+
- name: Cleanup large tools for build space
32+
uses: ./.github/actions/cleanup-runner
33+
- name: Install RocksDB
34+
uses: ./.github/actions/install-rocksdb
3135
- name: Rustup
3236
run: rustup update --no-self-update
3337
- uses: Swatinem/rust-cache@v2

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@
115115
- Add optional `TransactionInputs` field to `SubmitProvenTransaction` endpoint for transaction re-execution (#[1278](https://github.com/0xMiden/miden-node/pull/1278)).
116116
- Added `validator` crate with initial protobuf, gRPC server, and sub-command (#[1293](https://github.com/0xMiden/miden-node/pull/1293)).
117117
- [BREAKING] Added `AccountTreeWithHistory` and integrate historical queries into `GetAccountProof` ([#1292](https://github.com/0xMiden/miden-node/pull/1292)).
118+
- [BREAKING] Added `rocksdb` feature to enable rocksdb backends of `LargeSmt` ([#1326](https://github.com/0xMiden/miden-node/pull/1326)).
118119
- [BREAKING] Handle past/historical `AccountProof` requests ([#1333](https://github.com/0xMiden/miden-node/pull/1333)).
119120
- Implement `DataStore::get_note_script()` for `NtxDataStore` (#[1332](https://github.com/0xMiden/miden-node/pull/1332)).
120121
- Started validating notes by their commitment instead of ID before entering the mempool ([#1338](https://github.com/0xMiden/miden-node/pull/1338)).

0 commit comments

Comments
 (0)