mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-02 20:09:57 +08:00
MS-328 Check metric type on server start
Former-commit-id: 736c87b1731618461082b7171ffb366396a1dbd2
This commit is contained in:
parent
20a34eada9
commit
3f699e1757
@ -44,6 +44,7 @@ Please mark all change in change log and use the ticket from JIRA.
|
||||
- MS-305 - Add CPU core percent metric
|
||||
- MS-310 - Add milvus CPU utilization ratio and CPU/GPU temperature metrics
|
||||
- MS-324 - Show error when there is not enough gpu memory to build index
|
||||
- MS-328 - Check metric type on server start
|
||||
|
||||
## New Feature
|
||||
- MS-180 - Add new mem manager
|
||||
|
@ -74,6 +74,12 @@ DBWrapper::DBWrapper() {
|
||||
}
|
||||
}
|
||||
|
||||
std::string metric_type = engine_config.GetValue(CONFIG_METRICTYPE, "L2");
|
||||
if(metric_type != "L2" && metric_type != "IP") {
|
||||
std::cout << "ERROR! Illegal metric type: " << metric_type << ", available options: L2 or IP" << std::endl;
|
||||
kill(0, SIGUSR1);
|
||||
}
|
||||
|
||||
//set archive config
|
||||
engine::ArchiveConf::CriteriaT criterial;
|
||||
int64_t disk = db_config.GetInt64Value(CONFIG_DB_ARCHIVE_DISK, 0);
|
||||
@ -101,6 +107,7 @@ DBWrapper::DBWrapper() {
|
||||
}
|
||||
}
|
||||
|
||||
//create db instance
|
||||
std::string msg = opt.meta.path;
|
||||
try {
|
||||
zilliz::milvus::engine::DB::Open(opt, &db_);
|
||||
|
Loading…
Reference in New Issue
Block a user