aboutsummaryrefslogtreecommitdiffstats
path: root/benches
diff options
context:
space:
mode:
authorJan Tuomi <jan@jantuomi.fi>2024-10-05 12:58:35 +0200
committerJan Tuomi <jan@jantuomi.fi>2024-10-05 12:58:35 +0200
commit9f59bf5c621d36fb956ea8a8602b0c37ceaadfe6 (patch)
treea7f394048919c94fc758c3e683e449f95c47a700 /benches
parent6532e4f4a94ada35c958cf53e1f98aaf175188c6 (diff)
Make write durability configurable
Diffstat (limited to 'benches')
-rw-r--r--benches/benchmark.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/benches/benchmark.rs b/benches/benchmark.rs
index b9ecbb3..0328ac5 100644
--- a/benches/benchmark.rs
+++ b/benches/benchmark.rs
@@ -34,8 +34,8 @@ pub fn upsert_benchmark(c: &mut Criterion) {
prefill_db_with_n_records(&mut db, size).expect("Failed to prefill DB");
group.bench_with_input(BenchmarkId::from_parameter(size), &size, |b, &_size| {
+ let record = random_record();
b.iter(|| {
- let record = random_record();
let _ = db.upsert(black_box(&record));
});
});
@@ -64,8 +64,8 @@ pub fn get_benchmark(c: &mut Criterion) {
prefill_db_with_n_records(&mut db, size).expect("Failed to prefill DB");
group.bench_with_input(BenchmarkId::from_parameter(size), &size, |b, &_size| {
+ let id = random_int();
b.iter(|| {
- let id = random_int();
let _ = db.get(black_box(&RecordValue::Int(id)));
});
});