Skip to content

Commit

Permalink
Merge pull request #570 from EspressoSystems/abdul/remove-ltree
Browse files Browse the repository at this point in the history
Optimize merkle path query
  • Loading branch information
imabdulbasit authored May 7, 2024
2 parents bce8fe5 + b928298 commit a48483e
Show file tree
Hide file tree
Showing 6 changed files with 113 additions and 221 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

[package]
name = "hotshot-query-service"
version = "0.1.17"
version = "0.1.18"
authors = ["Espresso Systems <hello@espressosys.com>"]
edition = "2021"
license = "GPL-3.0-or-later"
Expand Down
8 changes: 0 additions & 8 deletions src/data_source/extension.rs
Original file line number Diff line number Diff line change
Expand Up @@ -298,14 +298,6 @@ where
) -> QueryResult<MerkleProof<State::Entry, State::Key, State::T, ARITY>> {
self.data_source.get_path(snapshot, key).await
}

async fn keys(&self, snapshot: Snapshot<Types, State, ARITY>) -> QueryResult<Vec<State::Key>> {
self.data_source.keys(snapshot).await
}

async fn get_snapshot(&self, snapshot: Snapshot<Types, State, ARITY>) -> QueryResult<State> {
self.data_source.get_snapshot(snapshot).await
}
}

#[async_trait]
Expand Down
20 changes: 0 additions & 20 deletions src/data_source/fetching.rs
Original file line number Diff line number Diff line change
Expand Up @@ -596,26 +596,6 @@ where
.get_path(snapshot, key)
.await
}

async fn keys(&self, snapshot: Snapshot<Types, State, ARITY>) -> QueryResult<Vec<State::Key>> {
self.fetcher
.storage
.read()
.await
.storage
.keys(snapshot)
.await
}

async fn get_snapshot(&self, snapshot: Snapshot<Types, State, ARITY>) -> QueryResult<State> {
self.fetcher
.storage
.read()
.await
.storage
.get_snapshot(snapshot)
.await
}
}

#[async_trait]
Expand Down
Loading

0 comments on commit a48483e

Please sign in to comment.