Skip to content

Commit

Permalink
rename createindex
Browse files Browse the repository at this point in the history
Signed-off-by: Enwei Jiao <[email protected]>
  • Loading branch information
jiaoew1991 committed Oct 24, 2023
1 parent e0222b2 commit f6b5c76
Show file tree
Hide file tree
Showing 6 changed files with 697 additions and 427 deletions.
10 changes: 5 additions & 5 deletions internal/core/src/indexbuilder/index_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@

using namespace milvus;
CStatus
CreateIndex(enum CDataType dtype,
const char* serialized_type_params,
const char* serialized_index_params,
CIndex* res_index) {
CreateIndexV0(enum CDataType dtype,
const char* serialized_type_params,
const char* serialized_index_params,
CIndex* res_index) {
auto status = CStatus();
try {
AssertInfo(res_index, "failed to create index, passed index was null");
Expand Down Expand Up @@ -73,7 +73,7 @@ CreateIndex(enum CDataType dtype,
}

CStatus
CreateIndexV2(CIndex* res_index, CBuildIndexInfo c_build_index_info) {
CreateIndex(CIndex* res_index, CBuildIndexInfo c_build_index_info) {

Check warning on line 76 in internal/core/src/indexbuilder/index_c.cpp

View check run for this annotation

Codecov / codecov/patch

internal/core/src/indexbuilder/index_c.cpp#L76

Added line #L76 was not covered by tests
try {
auto build_index_info = (BuildIndexInfo*)c_build_index_info;
auto field_type = build_index_info->field_type;
Expand Down
14 changes: 7 additions & 7 deletions internal/core/src/indexbuilder/index_c.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,13 @@ extern "C" {
#include "indexbuilder/type_c.h"

CStatus
CreateIndex(enum CDataType dtype,
const char* serialized_type_params,
const char* serialized_index_params,
CIndex* res_index);
CreateIndexV0(enum CDataType dtype,
const char* serialized_type_params,
const char* serialized_index_params,
CIndex* res_index);

CStatus
CreateIndex(CIndex* res_index, CBuildIndexInfo c_build_index_info);

CStatus
DeleteIndex(CIndex index);
Expand Down Expand Up @@ -90,9 +93,6 @@ CStatus
AppendIndexEngineVersionToBuildInfo(CBuildIndexInfo c_load_index_info,
int32_t c_index_engine_version);

CStatus
CreateIndexV2(CIndex* res_index, CBuildIndexInfo c_build_index_info);

CStatus
SerializeIndexAndUpLoad(CIndex index, CBinarySet* c_binary_set);

Expand Down
Loading

0 comments on commit f6b5c76

Please sign in to comment.