mirror of https://github.com/milvus-io/milvus.git
parent
7323180861
commit
543ec4a209
|
@ -20,6 +20,6 @@ add_library(milvus_common SHARED
|
||||||
${COMMON_SRC}
|
${COMMON_SRC}
|
||||||
)
|
)
|
||||||
|
|
||||||
target_link_libraries(milvus_common milvus_utils milvus_config log knowhere milvus_proto yaml-cpp )
|
target_link_libraries(milvus_common milvus_utils milvus_config milvus_log knowhere milvus_proto yaml-cpp )
|
||||||
|
|
||||||
install(TARGETS milvus_common DESTINATION lib)
|
install(TARGETS milvus_common DESTINATION lib)
|
||||||
|
|
|
@ -18,9 +18,8 @@ set(CONFIG_SRC
|
||||||
ConfigKnowhere.cpp
|
ConfigKnowhere.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
add_library(milvus_config
|
add_library(milvus_config STATIC ${CONFIG_SRC})
|
||||||
${CONFIG_SRC}
|
|
||||||
)
|
|
||||||
target_link_libraries(milvus_config
|
target_link_libraries(milvus_config
|
||||||
knowhere
|
knowhere
|
||||||
milvus_proto
|
milvus_proto
|
||||||
|
|
|
@ -18,5 +18,6 @@ set(exceptions_files
|
||||||
EasyAssert.cpp
|
EasyAssert.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
add_library(milvus_exceptions ${exceptions_files})
|
add_library(milvus_exceptions STATIC ${exceptions_files})
|
||||||
|
|
||||||
target_link_libraries(milvus_exceptions PRIVATE milvus_proto)
|
target_link_libraries(milvus_exceptions PRIVATE milvus_proto)
|
||||||
|
|
|
@ -54,13 +54,4 @@ EasyAssertInfo(bool value,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[[noreturn]] void
|
|
||||||
ThrowWithTrace(const std::exception& exception) {
|
|
||||||
if (typeid(exception) == typeid(SegcoreError)) {
|
|
||||||
throw exception;
|
|
||||||
}
|
|
||||||
auto err_msg = exception.what() + std::string("\n") + EasyStackTrace();
|
|
||||||
throw SegcoreError(ErrorCodeEnum::UnexpectedError, err_msg);
|
|
||||||
}
|
|
||||||
|
|
||||||
} // namespace milvus::impl
|
} // namespace milvus::impl
|
||||||
|
|
|
@ -35,9 +35,6 @@ EasyAssertInfo(bool value,
|
||||||
std::string_view extra_info,
|
std::string_view extra_info,
|
||||||
ErrorCodeEnum error_code = ErrorCodeEnum::UnexpectedError);
|
ErrorCodeEnum error_code = ErrorCodeEnum::UnexpectedError);
|
||||||
|
|
||||||
[[noreturn]] void
|
|
||||||
ThrowWithTrace(const std::exception& exception);
|
|
||||||
|
|
||||||
} // namespace impl
|
} // namespace impl
|
||||||
|
|
||||||
class SegcoreError : public std::runtime_error {
|
class SegcoreError : public std::runtime_error {
|
||||||
|
|
|
@ -16,6 +16,6 @@ set(LOG_FILES ${MILVUS_ENGINE_SRC}/log/Log.cpp
|
||||||
${MILVUS_THIRDPARTY_SRC}/easyloggingpp/easylogging++.h
|
${MILVUS_THIRDPARTY_SRC}/easyloggingpp/easylogging++.h
|
||||||
)
|
)
|
||||||
|
|
||||||
add_library(log STATIC ${LOG_FILES})
|
add_library(milvus_log STATIC ${LOG_FILES})
|
||||||
set_target_properties(log PROPERTIES RULE_LAUNCH_COMPILE "")
|
set_target_properties(milvus_log PROPERTIES RULE_LAUNCH_COMPILE "")
|
||||||
set_target_properties(log PROPERTIES RULE_LAUNCH_LINK "")
|
set_target_properties(milvus_log PROPERTIES RULE_LAUNCH_LINK "")
|
||||||
|
|
|
@ -1,12 +0,0 @@
|
||||||
// Copyright (C) 2019-2020 Zilliz. All rights reserved.
|
|
||||||
//
|
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance
|
|
||||||
// with the License. You may obtain a copy of the License at
|
|
||||||
//
|
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
//
|
|
||||||
// Unless required by applicable law or agreed to in writing, software distributed under the License
|
|
||||||
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
|
|
||||||
// or implied. See the License for the specific language governing permissions and limitations under the License
|
|
||||||
|
|
||||||
#include "Types.h"
|
|
|
@ -11,8 +11,6 @@
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
// #include <faiss/Index.h>
|
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
|
@ -62,7 +62,7 @@ if (LINUX)
|
||||||
milvus_segcore
|
milvus_segcore
|
||||||
milvus_indexbuilder
|
milvus_indexbuilder
|
||||||
milvus_index
|
milvus_index
|
||||||
log
|
milvus_log
|
||||||
pthread
|
pthread
|
||||||
)
|
)
|
||||||
install(TARGETS index_builder_test DESTINATION unittest)
|
install(TARGETS index_builder_test DESTINATION unittest)
|
||||||
|
@ -93,7 +93,7 @@ target_link_libraries(all_tests
|
||||||
milvus_segcore
|
milvus_segcore
|
||||||
milvus_indexbuilder
|
milvus_indexbuilder
|
||||||
milvus_index
|
milvus_index
|
||||||
log
|
milvus_log
|
||||||
pthread
|
pthread
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ set(indexbuilder_bench_srcs
|
||||||
add_executable(all_bench ${bench_srcs})
|
add_executable(all_bench ${bench_srcs})
|
||||||
target_link_libraries(all_bench
|
target_link_libraries(all_bench
|
||||||
milvus_segcore
|
milvus_segcore
|
||||||
log
|
milvus_log
|
||||||
pthread
|
pthread
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@ target_link_libraries(indexbuilder_bench
|
||||||
milvus_segcore
|
milvus_segcore
|
||||||
milvus_indexbuilder
|
milvus_indexbuilder
|
||||||
milvus_index
|
milvus_index
|
||||||
log
|
milvus_log
|
||||||
pthread
|
pthread
|
||||||
knowhere
|
knowhere
|
||||||
milvus_utils
|
milvus_utils
|
||||||
|
|
Loading…
Reference in New Issue