Config improvements:

* More fine-grained Section mutators
* Add remap for mapping legacy single sections to key value pairs
* Add output stream operators for BasicConfig and Section
* Allow section values to be overwritten from command line
* Update rpc key/value configs from command line
* Add RPC::Setup with defaults and remap legacy rpc sections
This commit is contained in:
Vinnie Falco
2014-09-27 18:22:56 -07:00
parent 2936bbfae8
commit d618581060
8 changed files with 223 additions and 42 deletions

View File

@@ -344,6 +344,7 @@ int run (int argc, char** argv)
if (vm.count ("rpc_ip"))
{
getConfig ().setRpcIpAndOptionalPort (vm ["rpc_ip"].as <std::string> ());
getConfig().overwrite("rpc", "ip", vm["rpc_ip"].as<std::string>());
}
// Override the RPC destination port number
@@ -352,6 +353,7 @@ int run (int argc, char** argv)
{
// VFALCO TODO This should be a short.
getConfig ().setRpcPort (vm ["rpc_port"].as <int> ());
getConfig().overwrite("rpc", "port", vm["rpc_port"].as<std::string>());
}
if (vm.count ("quorum"))