提交 f6b4ed33 编写于 作者: Y yudong.cai

#1463 enable config version check

Signed-off-by: Nyudong.cai <yudong.cai@zilliz.com>
上级 600dac75
......@@ -617,7 +617,7 @@ Config::CheckConfigVersion(const std::string& value) {
std::string msg = "Invalid config version: " + value +
". Expected config version: " + milvus_config_version_map.at(MILVUS_VERSION);
SERVER_LOG_ERROR << msg;
// return Status(SERVER_INVALID_ARGUMENT, msg);
return Status(SERVER_INVALID_ARGUMENT, msg);
}
}
return Status::OK();
......
......@@ -650,10 +650,10 @@ TEST_F(ConfigTest, SERVER_CONFIG_VALID_FAIL_TEST) {
milvus::Status s = config.LoadConfigFile(config_path + VALID_CONFIG_FILE);
ASSERT_TRUE(s.ok());
// fiu_enable("check_config_version_fail", 1, NULL, 0);
// s = config.ValidateConfig();
// ASSERT_FALSE(s.ok());
// fiu_disable("check_config_version_fail");
fiu_enable("check_config_version_fail", 1, NULL, 0);
s = config.ValidateConfig();
ASSERT_FALSE(s.ok());
fiu_disable("check_config_version_fail");
/* server config */
fiu_enable("check_config_address_fail", 1, NULL, 0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册