Skip to content

Commit

Permalink
Fix stresstest example compilation error
Browse files Browse the repository at this point in the history
  • Loading branch information
dermesser committed Jul 17, 2023
1 parent 913b60f commit 688d69a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions examples/stresstest/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use rand::distributions::{Alphanumeric, DistString};
use rusty_leveldb::{Options, DB};
use rusty_leveldb::{compressor, CompressorId, Options, DB};

const KEY_LEN: usize = 5;
const VAL_LEN: usize = 8;
Expand All @@ -12,7 +12,7 @@ fn gen_string(n: usize) -> String {

fn write(db: &mut DB, n: usize) {
time_test::time_test!("write");
for _ in 0..n {
for i in 0..n {
let (k, v) = (gen_string(KEY_LEN), gen_string(VAL_LEN));

db.put(k.as_bytes(), v.as_bytes()).unwrap();
Expand Down Expand Up @@ -42,7 +42,7 @@ fn read(db: &mut DB, n: usize) -> usize {
}

fn main() {
let n = 100_000;
let n = 1_000_000;
let m = 10;
let path = "stresstestdb";
let mut entries = 0;
Expand Down

0 comments on commit 688d69a

Please sign in to comment.