Skip to content

Commit

Permalink
inform tokio of blocking call to filter build
Browse files Browse the repository at this point in the history
  • Loading branch information
sug0 committed Jul 19, 2024
1 parent b0bd0aa commit 71925eb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions block-index/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ async fn build_new_block_index(app_state: &AppState) -> Result<(), MainError> {
"Read all block heights with masp transactions from db"
);

let _serialized_filter = {
let _serialized_filter = tokio::task::block_in_place(|| {
tracing::debug!(
"Building binary fuse xor filter of all heights with masp \
transactions"
Expand All @@ -248,8 +248,8 @@ async fn build_new_block_index(app_state: &AppState) -> Result<(), MainError> {
"Binary fuse xor filter built"
);

serialized
};
Ok(serialized)
})?;

tracing::debug!("Storing binary fuse xor filter in db");
// TODO: store filter in db
Expand Down

0 comments on commit 71925eb

Please sign in to comment.