Skip to content

Commit ebca8a0

Browse files
committed
ci: linter fixes
1 parent 568340e commit ebca8a0

File tree

1 file changed

+7
-12
lines changed

1 file changed

+7
-12
lines changed

crates/server/benches/whitepaper_bench.rs

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,7 @@ fn create_state_layer(temp_dir: &TempDir) -> StateLayer<FileBackend> {
6666
}
6767

6868
/// Pre-populate a vault with entities for read benchmarks.
69-
fn populate_vault(
70-
state: &StateLayer<FileBackend>,
71-
vault_id: i64,
72-
count: usize,
73-
) {
69+
fn populate_vault(state: &StateLayer<FileBackend>, vault_id: i64, count: usize) {
7470
// Use batched writes for faster population
7571
const BATCH_SIZE: usize = 1000;
7672
let mut sequence = 0u64;
@@ -86,9 +82,7 @@ fn populate_vault(
8682
})
8783
.collect();
8884

89-
state
90-
.apply_operations(vault_id, &operations, sequence)
91-
.expect("populate");
85+
state.apply_operations(vault_id, &operations, sequence).expect("populate");
9286
sequence += 1;
9387
}
9488
}
@@ -100,9 +94,7 @@ struct LatencyCollector {
10094

10195
impl LatencyCollector {
10296
fn new(capacity: usize) -> Self {
103-
Self {
104-
samples: Vec::with_capacity(capacity),
105-
}
97+
Self { samples: Vec::with_capacity(capacity) }
10698
}
10799

108100
fn record(&mut self, duration: Duration) {
@@ -523,7 +515,10 @@ fn bench_latency_percentiles(c: &mut Criterion) {
523515
eprintln!("━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━");
524516
eprintln!(" p50: {:>8.2} µs", p50.as_nanos() as f64 / 1000.0);
525517
eprintln!(" p95: {:>8.2} µs", p95.as_nanos() as f64 / 1000.0);
526-
eprintln!(" p99: {:>8.2} µs (target: <2,000 µs)", p99.as_nanos() as f64 / 1000.0);
518+
eprintln!(
519+
" p99: {:>8.2} µs (target: <2,000 µs)",
520+
p99.as_nanos() as f64 / 1000.0
521+
);
527522
eprintln!(" p999: {:>8.2} µs", p999.as_nanos() as f64 / 1000.0);
528523
eprintln!(" mean: {:>8.2} µs", mean.as_nanos() as f64 / 1000.0);
529524
eprintln!("━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n");

0 commit comments

Comments
 (0)