mon: MonitorDBStore: remove mon-specific leveldb options.

From this point onward, users should use leveldb's options and add them
to the appropriate config sections of their configuration file.

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
This commit is contained in:
Joao Eduardo Luis 2014-06-23 19:28:07 +01:00
parent 9844885d4c
commit d42d19df2a
3 changed files with 5 additions and 30 deletions

View File

@ -2,3 +2,6 @@
v0.82
-----
- mon-specific leveldb options have been removed. From this point onward,
users should use 'leveldb_' generic options and add the options in the
appropriate sections of their configuration files.

View File

@ -212,14 +212,6 @@ OPTION(mon_debug_dump_location, OPT_STR, "/var/log/ceph/$cluster-$name.tdump")
OPTION(mon_sync_provider_kill_at, OPT_INT, 0) // kill the sync provider at a specific point in the work flow
OPTION(mon_sync_requester_kill_at, OPT_INT, 0) // kill the sync requester at a specific point in the work flow
OPTION(mon_leveldb_write_buffer_size, OPT_U64, 32*1024*1024) // monitor's leveldb write buffer size
OPTION(mon_leveldb_cache_size, OPT_U64, 512*1024*1024) // monitor's leveldb cache size
OPTION(mon_leveldb_block_size, OPT_U64, 64*1024) // monitor's leveldb block size
OPTION(mon_leveldb_bloom_size, OPT_INT, 0) // monitor's leveldb bloom bits per entry
OPTION(mon_leveldb_max_open_files, OPT_INT, 0) // monitor's leveldb max open files
OPTION(mon_leveldb_compression, OPT_BOOL, false) // monitor's leveldb uses compression
OPTION(mon_leveldb_paranoid, OPT_BOOL, false) // monitor's leveldb paranoid flag
OPTION(mon_leveldb_log, OPT_STR, "")
OPTION(mon_force_quorum_join, OPT_BOOL, false) // force monitor to join quorum even if it has been previously removed from the map
OPTION(paxos_stash_full_interval, OPT_INT, 25) // how often (in commits) to stash a full copy of the PaxosService state
OPTION(paxos_max_join_drift, OPT_INT, 10) // max paxos iterations before we must first sync the monitor stores

View File

@ -486,33 +486,13 @@ class MonitorDBStore
db->submit_transaction_sync(dbt);
}
void init_options() {
db->init();
if (g_conf->mon_leveldb_write_buffer_size)
db->options.write_buffer_size = g_conf->mon_leveldb_write_buffer_size;
if (g_conf->mon_leveldb_cache_size)
db->options.cache_size = g_conf->mon_leveldb_cache_size;
if (g_conf->mon_leveldb_block_size)
db->options.block_size = g_conf->mon_leveldb_block_size;
if (g_conf->mon_leveldb_bloom_size)
db->options.bloom_size = g_conf->mon_leveldb_bloom_size;
if (g_conf->mon_leveldb_compression)
db->options.compression_enabled = g_conf->mon_leveldb_compression;
if (g_conf->mon_leveldb_max_open_files)
db->options.max_open_files = g_conf->mon_leveldb_max_open_files;
if (g_conf->mon_leveldb_paranoid)
db->options.paranoid_checks = g_conf->mon_leveldb_paranoid;
if (g_conf->mon_leveldb_log.length())
db->options.log_file = g_conf->mon_leveldb_log;
}
int open(ostream &out) {
init_options();
db->init();
return db->open(out);
}
int create_and_open(ostream &out) {
init_options();
db->init();
return db->create_and_open(out);
}