mirror of https://github.com/milvus-io/milvus.git
enhance: add log to bitmap index (#34197)
#32900 Signed-off-by: luzhang <luzhang@zilliz.com> Co-authored-by: luzhang <luzhang@zilliz.com>pull/34276/head
parent
96dcee5dff
commit
cc1bc07bfd
|
@ -244,6 +244,8 @@ void
|
|||
HybridScalarIndex<T>::BuildInternal(
|
||||
const std::vector<FieldDataPtr>& field_datas) {
|
||||
auto index = GetInternalIndex();
|
||||
LOG_INFO("build bitmap index with internal index:{}",
|
||||
ToString(internal_index_type_));
|
||||
index->BuildWithFieldData(field_datas);
|
||||
}
|
||||
|
||||
|
@ -404,6 +406,8 @@ HybridScalarIndex<T>::Load(const BinarySet& binary_set, const Config& config) {
|
|||
DeserializeIndexType(binary_set);
|
||||
|
||||
auto index = GetInternalIndex();
|
||||
LOG_INFO("load bitmap index with internal index:{}",
|
||||
ToString(internal_index_type_));
|
||||
index->Load(binary_set, config);
|
||||
|
||||
is_built_ = true;
|
||||
|
@ -435,6 +439,8 @@ HybridScalarIndex<T>::Load(milvus::tracer::TraceContext ctx,
|
|||
DeserializeIndexType(binary_set);
|
||||
|
||||
auto index = GetInternalIndex();
|
||||
LOG_INFO("load bitmap index with internal index:{}",
|
||||
ToString(internal_index_type_));
|
||||
index->Load(ctx, config);
|
||||
|
||||
is_built_ = true;
|
||||
|
|
|
@ -37,6 +37,26 @@ enum class ScalarIndexType {
|
|||
HYBRID,
|
||||
};
|
||||
|
||||
inline std::string
|
||||
ToString(ScalarIndexType type) {
|
||||
switch (type) {
|
||||
case ScalarIndexType::NONE:
|
||||
return "NONE";
|
||||
case ScalarIndexType::BITMAP:
|
||||
return "BITMAP";
|
||||
case ScalarIndexType::STLSORT:
|
||||
return "STLSORT";
|
||||
case ScalarIndexType::MARISA:
|
||||
return "MARISA";
|
||||
case ScalarIndexType::INVERTED:
|
||||
return "INVERTED";
|
||||
case ScalarIndexType::HYBRID:
|
||||
return "HYBRID";
|
||||
default:
|
||||
return "UNKNOWN";
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
class ScalarIndex : public IndexBase {
|
||||
public:
|
||||
|
|
Loading…
Reference in New Issue