Skip to content

Commit

Permalink
linera-views: box MeteredStore::find_key_values_by_prefix to avoi…
Browse files Browse the repository at this point in the history
…d stack overflow
  • Loading branch information
Twey committed Mar 29, 2024
1 parent b6ecc4c commit 70d1e84
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion linera-views/src/metering.rs
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,9 @@ where
}

async fn find_key_values_by_prefix(&self, key_prefix: &[u8]) -> Result<Self::KeyValues, E> {

Check warning on line 150 in linera-views/src/metering.rs

View workflow job for this annotation

GitHub Actions / lint

Diff in /home/runner/work/linera-protocol/linera-protocol/linera-views/src/metering.rs
use futures::FutureExt as _;
let _metric = self.counter.find_key_values_by_prefix.measure_latency();
self.store.find_key_values_by_prefix(key_prefix).await
self.store.find_key_values_by_prefix(key_prefix).boxed().await
}
}

Expand Down

0 comments on commit 70d1e84

Please sign in to comment.