Skip to content

Commit

Permalink
remove unused search field
Browse files Browse the repository at this point in the history
  • Loading branch information
zcdb committed Mar 29, 2024
1 parent e202564 commit 27516af
Show file tree
Hide file tree
Showing 7 changed files with 146 additions and 234 deletions.
15 changes: 0 additions & 15 deletions internal/client/master_cache.go
Expand Up @@ -854,21 +854,6 @@ func (cliCache *clientCache) reloadAliasCache(ctx context.Context, sync bool, al
if sync {
return fun()
}
if _, ok := aliasReloadWorkder.LoadOrStore(alias_name, struct{}{}); ok {
return nil
}
go func() {
defer func() {
if r := recover(); r != nil {
vearchlog.LogErrNotNil(fmt.Errorf(cast.ToString(r)))
}
}()
if alias_name == "" {
return
}
defer aliasReloadWorkder.Delete(alias_name)
vearchlog.FunIfNotNil(fun)
}()
return nil
}

Expand Down
26 changes: 12 additions & 14 deletions internal/engine/sdk/go/gamma/request.go
Expand Up @@ -40,20 +40,18 @@ type VectorQuery struct {
}

type Request struct {
ReqNum int32
TopN int32
BruteForceSearch int32
VecFields []VectorQuery
Fields []string
RangeFilters []RangeFilter
TermFilters []TermFilter
OnlineLogLevel string
IndexParams string
HasRank bool
MultiVectorRank int32
ParallelBasedOnQuery bool
L2Sqrt bool
IvfFlat bool
ReqNum int32
TopN int32
BruteForceSearch int32
VecFields []VectorQuery
Fields []string
RangeFilters []RangeFilter
TermFilters []TermFilter
OnlineLogLevel string
IndexParams string
HasRank bool
MultiVectorRank int32
L2Sqrt bool

request *gamma_api.Request
}
Expand Down
6 changes: 0 additions & 6 deletions internal/entity/request/search_doc.go
Expand Up @@ -54,9 +54,6 @@ type SearchDocumentRequest struct {
Quick bool `json:"quick,omitempty"`
L2Sqrt bool `json:"l2_sqrt,omitempty"`
VectorValue bool `json:"vector_value,omitempty"`
Parallel bool `json:"parallel,omitempty"`
Nprobe int64 `json:"nprobe,omitempty"`
IVFFlat bool `json:"ivf_flat,omitempty"`
OnlineLogLevel string `json:"online_log_level"`
IsBruteSearch int32 `json:"is_brute_search"`
DbName string `json:"db_name,omitempty"`
Expand Down Expand Up @@ -85,10 +82,7 @@ type SearchDocument struct {
Quick bool `json:"quick,omitempty"`
VectorValue bool `json:"vector_value,omitempty"`
ClietType string `json:"client_type,omitempty"`
Parallel bool `json:"parallel,omitempty"`
L2Sqrt bool `json:"l2_sqrt,omitempty"`
IVFFlat bool `json:"ivf_flat,omitempty"`
Nprobe int `json:"nprobe,omitempty"`
Size int `json:"size,omitempty"`
}

Expand Down
22 changes: 7 additions & 15 deletions internal/proto/router_grpc.proto
Expand Up @@ -61,13 +61,9 @@ message BulkRequest {
repeated Document docs = 4;
}

message ForceMergeRequest {
RequestHead head = 1;
}
message ForceMergeRequest { RequestHead head = 1; }

message FlushRequest {
RequestHead head = 1;
}
message FlushRequest { RequestHead head = 1; }

message IndexRequest {
RequestHead head = 1;
Expand All @@ -88,9 +84,7 @@ message AddResponse {
string primary_key = 4;
}

message UpdateResponse {
ResponseHead head = 1;
}
message UpdateResponse { ResponseHead head = 1; }

message DeleteResponse {
ResponseHead head = 1;
Expand Down Expand Up @@ -178,12 +172,10 @@ message SearchRequest {
string index_params = 10;
bool has_rank = 11;
int32 multi_vector_rank = 12;
bool parallel_based_on_query = 13;
bool l2_sqrt = 14;
bool ivf_flat = 15;
bool is_vector_value = 16;
map<string, string> sort_field_map = 17;
repeated SortField sort_fields = 18;
bool l2_sqrt = 13;
bool is_vector_value = 14;
map<string, string> sort_field_map = 15;
repeated SortField sort_fields = 16;
}

//*********************** Search response *********************** //
Expand Down

0 comments on commit 27516af

Please sign in to comment.