db: remove wal disabling / fast-and-loose option. (#8963)

* parity: highlight --fast-and-loose is not recommended.

* parity: remove fast-and-loose option, ref #1765

* db: remove db wal from options, it's always enabled

* db: remove wal from rocksdb helpers

* cli: fix wallet import test

* ethcore: fix client config tests

* parity: proper deprecated handling for fast-and-loose

* ethcore-client: fix config

* parity: mark fast-and-loose removed

* parity: fix test_find_deprecated

* parity: fix type for fast-and-loose flag

* lock file
This commit is contained in:
Afri Schoedon
2018-07-10 17:33:25 +02:00
committed by David
parent 526c61e2c0
commit da5de4a6ff
16 changed files with 32 additions and 62 deletions

View File

@@ -32,7 +32,6 @@ pub fn client_db_config(client_path: &Path, client_config: &ClientConfig) -> Dat
client_db_config.memory_budget = client_config.db_cache_size;
client_db_config.compaction = compaction_profile(&client_config.db_compaction, &client_path);
client_db_config.wal = client_config.db_wal;
client_db_config
}

View File

@@ -218,7 +218,6 @@ pub fn migrate(path: &Path, compaction_profile: &DatabaseCompactionProfile) -> R
memory_budget: None,
compaction: compaction_profile,
columns: db::NUM_COLUMNS,
wal: true,
};
migrate_blooms(&db_path, &db_config).map_err(Error::BloomsDB)?;

View File

@@ -86,13 +86,12 @@ pub fn restoration_db_handler(client_path: &Path, client_config: &ClientConfig)
}
/// Open a new main DB.
pub fn open_db(client_path: &str, cache_config: &CacheConfig, compaction: &DatabaseCompactionProfile, wal: bool) -> io::Result<Arc<BlockChainDB>> {
pub fn open_db(client_path: &str, cache_config: &CacheConfig, compaction: &DatabaseCompactionProfile) -> io::Result<Arc<BlockChainDB>> {
let path = Path::new(client_path);
let db_config = DatabaseConfig {
memory_budget: Some(cache_config.blockchain() as usize * 1024 * 1024),
compaction: helpers::compaction_profile(&compaction, path),
wal,
.. DatabaseConfig::with_columns(NUM_COLUMNS)
};