dbms: fix config[#METR-9350]

This commit is contained in:
Pavel Kartavyy 2013-12-10 09:35:30 +00:00
parent ce5ff538ec
commit c22fb0ac12
2 changed files with 2 additions and 2 deletions

View File

@ -44,7 +44,7 @@ private:
* <host>example01-01-1</host>
* <port>9000</port>
* <!-- <user>, <password>, если нужны -->
* </replica>
* </replica>
* </shard>
*/
Poco::Net::SocketAddress host_port;

View File

@ -58,7 +58,7 @@ Cluster::Cluster(const Settings & settings, const DataTypeFactory & data_type_fa
for (Poco::Util::AbstractConfiguration::Keys::const_iterator jt = replica_keys.begin(); jt != replica_keys.end(); ++jt)
{
if (0 == strncmp(jt->c_str(), "replica", strlen("replica")))
replica_addresses.push_back(Address(config_prefix + *it));
replica_addresses.push_back(Address(config_prefix + *it + "." + *jt));
else
throw Exception("Unknown element in config: " + *jt, ErrorCodes::UNKNOWN_ELEMENT_IN_CONFIG);
}