From 82019228a9033288eed50c5de4440ea4262d1f55 Mon Sep 17 00:00:00 2001 From: dkos Date: Sun, 6 Sep 2020 12:32:54 +0200 Subject: [PATCH] latest rocksdb-rs --- Cargo.toml | 8 +------- config/db_config.toml | 4 ++-- src/config.rs | 6 ------ 3 files changed, 3 insertions(+), 15 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 0a63f47..d173fdd 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -6,22 +6,16 @@ edition = "2018" categories = ["http", "rocksdb", "storage"] description = "RocksDb as a service" -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html - [dependencies] structopt = "0.3" actix-web = "2.0" actix-rt = "1.0" actix-web-prom = "0.2" - - serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" - simplelog = "0.7.6" log = "0.4.8" - -rocksdb = "0.14.0" +rocksdb = "0.15.0" confy = "0.4.0" num_cpus = "1.0" crossbeam = "0.7.3" diff --git a/config/db_config.toml b/config/db_config.toml index a12ba6c..78f02cb 100644 --- a/config/db_config.toml +++ b/config/db_config.toml @@ -12,5 +12,5 @@ min_write_buffer_number_to_merge = 1 level_zero_stop_writes_trigger = 24 level_zero_slowdown_writes_trigger = 20 compaction_style = "Level" -max_background_compactions = 2 -max_background_flushes = 2 \ No newline at end of file +#block based + diff --git a/src/config.rs b/src/config.rs index 57a8e86..807046c 100644 --- a/src/config.rs +++ b/src/config.rs @@ -68,8 +68,6 @@ pub struct RocksDbConfig { level_zero_stop_writes_trigger: i32, level_zero_slowdown_writes_trigger: i32, compaction_style: String, - max_background_compactions: i32, - max_background_flushes: i32, } impl Default for RocksDbConfig { @@ -89,8 +87,6 @@ impl Default for RocksDbConfig { level_zero_stop_writes_trigger: 24, level_zero_slowdown_writes_trigger: 24, compaction_style: "Level".to_string(), - max_background_compactions: 2, - max_background_flushes: 2, } } } @@ -120,8 +116,6 @@ impl RocksDbConfig { opts.set_level_zero_stop_writes_trigger(self.level_zero_stop_writes_trigger); opts.set_level_zero_slowdown_writes_trigger(self.level_zero_slowdown_writes_trigger); opts.set_compaction_style(get_compaction_style(&self.compaction_style)); - opts.set_max_background_compactions(self.max_background_compactions); - opts.set_max_background_flushes(self.max_background_flushes); opts.create_if_missing(true); opts