Documentation ¶
Index ¶
- Constants
- Variables
- func CopyCProtoBlob(cProto *C.CProto) []byte
- func CreateInternalReducer(req *querypb.QueryRequest, schema *schemapb.CollectionSchema) internalReducer
- func CreateSegCoreReducer(req *querypb.QueryRequest, schema *schemapb.CollectionSchema, manager *Manager) segCoreReducer
- func DecodeSearchResults(ctx context.Context, searchResults []*internalpb.SearchResults) ([]*schemapb.SearchResultData, error)
- func DeleteCollection(collection *Collection)
- func DeleteSearchResultDataBlobs(cSearchResultDataBlobs SearchResultDataBlobs)
- func DeleteSearchResults(results []*SearchResult)
- func DeleteStreamReduceHelper(cStreamReduceHelper StreamSearchReducer)
- func EncodeSearchResultData(ctx context.Context, searchResultData *schemapb.SearchResultData, nq int64, ...) (searchResults *internalpb.SearchResults, err error)
- func FilterZeroValuesFromSlice(intVals []int64) []int64
- func GenAndSaveIndex(collectionID, partitionID, segmentID, fieldID int64, msgLength int, ...) (*querypb.FieldIndexInfo, error)
- func GenAndSaveIndexV2(collectionID, partitionID, segmentID, buildID int64, ...) (*querypb.FieldIndexInfo, error)
- func GenTestCollectionSchema(collectionName string, pkType schemapb.DataType, withSparse bool) *schemapb.CollectionSchema
- func GenTestIndexInfoList(collectionID int64, schema *schemapb.CollectionSchema) []*indexpb.IndexInfo
- func GenTestIndexMeta(collectionID int64, schema *schemapb.CollectionSchema) *segcorepb.CollectionIndexMeta
- func GetBFApplyPool() *conc.Pool[any]
- func GetCProtoBlob(cProto *C.CProto) []byte
- func GetDynamicPool() *conc.Pool[any]
- func GetLoadPool() *conc.Pool[any]
- func GetLocalUsedSize(ctx context.Context, path string) (int64, error)
- func GetPkField(schema *schemapb.CollectionSchema) *schemapb.FieldSchema
- func GetPrimaryKeys(msg *msgstream.InsertMsg, schema *schemapb.CollectionSchema) ([]storage.PrimaryKey, error)
- func GetSQPool() *conc.Pool[any]
- func GetSearchResultDataBlob(ctx context.Context, cSearchResultDataBlobs SearchResultDataBlobs, ...) ([]byte, error)
- func GetSegmentRelatedDataSize(segment Segment) int64
- func GetWarmupPool() *conc.Pool[any]
- func HandleCStatus(ctx context.Context, status *C.CStatus, extraInfo string, fields ...zap.Field) error
- func JoinIDPath(ids ...int64) string
- func MergeInternalRetrieveResult(ctx context.Context, retrieveResults []*internalpb.RetrieveResults, ...) (*internalpb.RetrieveResults, error)
- func MergeSegcoreRetrieveResults(ctx context.Context, retrieveResults []*segcorepb.RetrieveResults, ...) (*segcorepb.RetrieveResults, error)
- func MergeToAdvancedResults(ctx context.Context, results []*internalpb.SearchResults) (*internalpb.SearchResults, error)
- func NewCollectionManager() *collectionManager
- func NewLoader(manager *Manager, cm storage.ChunkManager) *segmentLoader
- func NewMergeParam(limit int64, outputFieldsId []int64, schema *schemapb.CollectionSchema, ...) *mergeParam
- func NewSegmentManager() *segmentManager
- func NewTestChunkManagerFactory(params *paramtable.ComponentParam, rootPath string) *storage.ChunkManagerFactory
- func ReduceAdvancedSearchResults(ctx context.Context, results []*internalpb.SearchResults, nq int64) (*internalpb.SearchResults, error)
- func ReduceSearchResultData(ctx context.Context, searchResultData []*schemapb.SearchResultData, nq int64, ...) (*schemapb.SearchResultData, error)
- func ReduceSearchResults(ctx context.Context, results []*internalpb.SearchResults, nq int64, topk int64, ...) (*internalpb.SearchResults, error)
- func ResizeBFApplyPool(evt *config.Event)
- func ResizeLoadPool(evt *config.Event)
- func ResizeSQPool(evt *config.Event)
- func ResizeWarmupPool(evt *config.Event)
- func Retrieve(ctx context.Context, manager *Manager, plan *RetrievePlan, ...) ([]RetrieveSegmentResult, []Segment, error)
- func SaveBinLog(ctx context.Context, collectionID int64, partitionID int64, segmentID int64, ...) ([]*datapb.FieldBinlog, []*datapb.FieldBinlog, error)
- func SaveDeltaLog(collectionID int64, partitionID int64, segmentID int64, ...) ([]*datapb.FieldBinlog, error)
- func SearchHistorical(ctx context.Context, manager *Manager, searchReq *SearchRequest, collID int64, ...) ([]*SearchResult, []Segment, error)
- func SearchStreaming(ctx context.Context, manager *Manager, searchReq *SearchRequest, collID int64, ...) ([]*SearchResult, []Segment, error)
- func SelectSearchResultData(dataArray []*schemapb.SearchResultData, resultOffsets [][]int64, ...) int
- func StatisticStreaming(ctx context.Context, manager *Manager, collID int64, partIDs []int64, ...) ([]SegmentStats, []Segment, error)
- func StatisticsHistorical(ctx context.Context, manager *Manager, collID int64, partIDs []int64, ...) ([]SegmentStats, []Segment, error)
- func StreamReduceSearchResult(ctx context.Context, newResult *SearchResult, ...) error
- func UnmarshalCProto(cRes *C.CProto, msg proto.Message) error
- func WithReleaseScope(scope ReleaseScope) releaseOption
- type CTraceContext
- type Collection
- func (c *Collection) AddPartition(partitions ...int64)
- func (c *Collection) ExistPartition(partitionIDs ...int64) bool
- func (c *Collection) GetDBName() string
- func (c *Collection) GetLoadType() querypb.LoadType
- func (c *Collection) GetPartitions() []int64
- func (c *Collection) GetResourceGroup() string
- func (c *Collection) ID() int64
- func (c *Collection) IsGpuIndex() bool
- func (c *Collection) Ref(count uint32) uint32
- func (c *Collection) RemovePartition(partitionID int64)
- func (c *Collection) Schema() *schemapb.CollectionSchema
- func (c *Collection) Unref(count uint32) uint32
- type CollectionManager
- type FieldInfo
- type IndexAttrCache
- type IndexedFieldInfo
- type L0Segment
- func (s *L0Segment) BatchPkExist(lc *storage.BatchLocationsCache) []bool
- func (s *L0Segment) CASVersion(old, newVersion int64) bool
- func (s *L0Segment) Collection() int64
- func (s *L0Segment) DatabaseName() string
- func (s *L0Segment) Delete(ctx context.Context, primaryKeys []storage.PrimaryKey, ...) error
- func (s *L0Segment) DeleteRecords() ([]storage.PrimaryKey, []uint64)
- func (s *L0Segment) ExistIndex(fieldID int64) bool
- func (s *L0Segment) GetCollection() *Collection
- func (s *L0Segment) GetIndex(fieldID int64) *IndexedFieldInfo
- func (s *L0Segment) HasRawData(fieldID int64) bool
- func (s *L0Segment) ID() int64
- func (s *L0Segment) Indexes() []*IndexedFieldInfo
- func (s *L0Segment) Insert(ctx context.Context, rowIDs []int64, timestamps []typeutil.Timestamp, ...) error
- func (s *L0Segment) InsertCount() int64
- func (s *L0Segment) IsLazyLoad() bool
- func (s *L0Segment) LastDeltaTimestamp() uint64
- func (s *L0Segment) Level() datapb.SegmentLevel
- func (s *L0Segment) LoadDeltaData(ctx context.Context, deltaData *storage.DeleteData) error
- func (s *L0Segment) LoadInfo() *querypb.SegmentLoadInfo
- func (s *L0Segment) MayPkExist(pk *storage.LocationsCache) bool
- func (s *L0Segment) MemSize() int64
- func (s *L0Segment) NeedUpdatedVersion() int64
- func (s *L0Segment) Partition() int64
- func (s *L0Segment) PinIfNotReleased() error
- func (s *L0Segment) Release(ctx context.Context, opts ...releaseOption)
- func (s *L0Segment) RemoveUnusedFieldFiles() error
- func (s *L0Segment) ResetIndexesLazyLoad(lazyState bool)
- func (s *L0Segment) ResourceGroup() string
- func (s *L0Segment) ResourceUsageEstimate() ResourceUsage
- func (s *L0Segment) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error)
- func (s *L0Segment) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error)
- func (s *L0Segment) RowNum() int64
- func (s *L0Segment) Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error)
- func (s *L0Segment) SetLoadInfo(loadInfo *querypb.SegmentLoadInfo)
- func (s *L0Segment) SetNeedUpdatedVersion(version int64)
- func (s *L0Segment) Shard() metautil.Channel
- func (s *L0Segment) StartPosition() *msgpb.MsgPosition
- func (s *L0Segment) Type() SegmentType
- func (s *L0Segment) Unpin()
- func (s *L0Segment) UpdateBloomFilter(pks []storage.PrimaryKey)
- func (s *L0Segment) Version() int64
- type LoadFieldDataInfo
- type LoadIndexInfo
- type LoadResource
- type Loader
- type LocalSegment
- func (s *LocalSegment) AddFieldDataInfo(ctx context.Context, rowCount int64, fields []*datapb.FieldBinlog) error
- func (s *LocalSegment) BatchPkExist(lc *storage.BatchLocationsCache) []bool
- func (s *LocalSegment) CASVersion(old, newVersion int64) bool
- func (s *LocalSegment) Collection() int64
- func (s *LocalSegment) DatabaseName() string
- func (s *LocalSegment) Delete(ctx context.Context, primaryKeys []storage.PrimaryKey, ...) error
- func (s *LocalSegment) ExistIndex(fieldID int64) bool
- func (s *LocalSegment) GetCollection() *Collection
- func (s *LocalSegment) GetFieldDataPath(index *IndexedFieldInfo, offset int64) (dataPath string, offsetInBinlog int64)
- func (s *LocalSegment) GetIndex(fieldID int64) *IndexedFieldInfo
- func (s *LocalSegment) HasRawData(fieldID int64) bool
- func (s *LocalSegment) ID() int64
- func (s *LocalSegment) Indexes() []*IndexedFieldInfo
- func (s *LocalSegment) Insert(ctx context.Context, rowIDs []int64, timestamps []typeutil.Timestamp, ...) error
- func (s *LocalSegment) InsertCount() int64
- func (s *LocalSegment) IsLazyLoad() bool
- func (s *LocalSegment) LastDeltaTimestamp() uint64
- func (s *LocalSegment) Level() datapb.SegmentLevel
- func (s *LocalSegment) LoadDeltaData(ctx context.Context, deltaData *storage.DeleteData) error
- func (s *LocalSegment) LoadFieldData(ctx context.Context, fieldID int64, rowCount int64, field *datapb.FieldBinlog, ...) error
- func (s *LocalSegment) LoadIndex(ctx context.Context, indexInfo *querypb.FieldIndexInfo, ...) error
- func (s *LocalSegment) LoadInfo() *querypb.SegmentLoadInfo
- func (s *LocalSegment) LoadMultiFieldData(ctx context.Context) error
- func (s *LocalSegment) MayPkExist(pk *storage.LocationsCache) bool
- func (s *LocalSegment) MemSize() int64
- func (s *LocalSegment) NeedUpdatedVersion() int64
- func (s *LocalSegment) Partition() int64
- func (s *LocalSegment) PinIfNotReleased() error
- func (s *LocalSegment) Release(ctx context.Context, opts ...releaseOption)
- func (s *LocalSegment) ReleaseSegmentData()
- func (s *LocalSegment) RemoveFieldFile(fieldId int64)
- func (s *LocalSegment) RemoveUnusedFieldFiles() error
- func (s *LocalSegment) ResetIndexesLazyLoad(lazyState bool)
- func (s *LocalSegment) ResourceGroup() string
- func (s *LocalSegment) ResourceUsageEstimate() ResourceUsage
- func (s *LocalSegment) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error)
- func (s *LocalSegment) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error)
- func (s *LocalSegment) RowNum() int64
- func (s *LocalSegment) Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error)
- func (s *LocalSegment) SetLoadInfo(loadInfo *querypb.SegmentLoadInfo)
- func (s *LocalSegment) SetNeedUpdatedVersion(version int64)
- func (s *LocalSegment) Shard() metautil.Channel
- func (s *LocalSegment) StartLoadData() (state.LoadStateLockGuard, error)
- func (s *LocalSegment) StartPosition() *msgpb.MsgPosition
- func (s *LocalSegment) Type() SegmentType
- func (s *LocalSegment) Unpin()
- func (s *LocalSegment) UpdateBloomFilter(pks []storage.PrimaryKey)
- func (s *LocalSegment) UpdateFieldRawDataSize(ctx context.Context, numRows int64, fieldBinlog *datapb.FieldBinlog) error
- func (s *LocalSegment) UpdateIndexInfo(ctx context.Context, indexInfo *querypb.FieldIndexInfo, info *LoadIndexInfo) error
- func (s *LocalSegment) Version() int64
- func (s *LocalSegment) WarmupChunkCache(ctx context.Context, fieldID int64)
- type Manager
- type MockCollectionManager
- func (_m *MockCollectionManager) EXPECT() *MockCollectionManager_Expecter
- func (_m *MockCollectionManager) Get(collectionID int64) *Collection
- func (_m *MockCollectionManager) List() []int64
- func (_m *MockCollectionManager) PutOrRef(collectionID int64, schema *schemapb.CollectionSchema, ...)
- func (_m *MockCollectionManager) Ref(collectionID int64, count uint32) bool
- func (_m *MockCollectionManager) Unref(collectionID int64, count uint32) bool
- type MockCollectionManager_Expecter
- func (_e *MockCollectionManager_Expecter) Get(collectionID interface{}) *MockCollectionManager_Get_Call
- func (_e *MockCollectionManager_Expecter) List() *MockCollectionManager_List_Call
- func (_e *MockCollectionManager_Expecter) PutOrRef(collectionID interface{}, schema interface{}, meta interface{}, ...) *MockCollectionManager_PutOrRef_Call
- func (_e *MockCollectionManager_Expecter) Ref(collectionID interface{}, count interface{}) *MockCollectionManager_Ref_Call
- func (_e *MockCollectionManager_Expecter) Unref(collectionID interface{}, count interface{}) *MockCollectionManager_Unref_Call
- type MockCollectionManager_Get_Call
- func (_c *MockCollectionManager_Get_Call) Return(_a0 *Collection) *MockCollectionManager_Get_Call
- func (_c *MockCollectionManager_Get_Call) Run(run func(collectionID int64)) *MockCollectionManager_Get_Call
- func (_c *MockCollectionManager_Get_Call) RunAndReturn(run func(int64) *Collection) *MockCollectionManager_Get_Call
- type MockCollectionManager_List_Call
- type MockCollectionManager_PutOrRef_Call
- func (_c *MockCollectionManager_PutOrRef_Call) Return() *MockCollectionManager_PutOrRef_Call
- func (_c *MockCollectionManager_PutOrRef_Call) Run(run func(collectionID int64, schema *schemapb.CollectionSchema, ...)) *MockCollectionManager_PutOrRef_Call
- func (_c *MockCollectionManager_PutOrRef_Call) RunAndReturn(...) *MockCollectionManager_PutOrRef_Call
- type MockCollectionManager_Ref_Call
- func (_c *MockCollectionManager_Ref_Call) Return(_a0 bool) *MockCollectionManager_Ref_Call
- func (_c *MockCollectionManager_Ref_Call) Run(run func(collectionID int64, count uint32)) *MockCollectionManager_Ref_Call
- func (_c *MockCollectionManager_Ref_Call) RunAndReturn(run func(int64, uint32) bool) *MockCollectionManager_Ref_Call
- type MockCollectionManager_Unref_Call
- func (_c *MockCollectionManager_Unref_Call) Return(_a0 bool) *MockCollectionManager_Unref_Call
- func (_c *MockCollectionManager_Unref_Call) Run(run func(collectionID int64, count uint32)) *MockCollectionManager_Unref_Call
- func (_c *MockCollectionManager_Unref_Call) RunAndReturn(run func(int64, uint32) bool) *MockCollectionManager_Unref_Call
- type MockLoader
- func (_m *MockLoader) EXPECT() *MockLoader_Expecter
- func (_m *MockLoader) Load(ctx context.Context, collectionID int64, segmentType commonpb.SegmentState, ...) ([]Segment, error)
- func (_m *MockLoader) LoadBloomFilterSet(ctx context.Context, collectionID int64, version int64, ...) ([]*pkoracle.BloomFilterSet, error)
- func (_m *MockLoader) LoadDeltaLogs(ctx context.Context, segment Segment, deltaLogs []*datapb.FieldBinlog) error
- func (_m *MockLoader) LoadIndex(ctx context.Context, segment Segment, info *querypb.SegmentLoadInfo, ...) error
- func (_m *MockLoader) LoadLazySegment(ctx context.Context, segment Segment, loadInfo *querypb.SegmentLoadInfo) error
- type MockLoader_Expecter
- func (_e *MockLoader_Expecter) Load(ctx interface{}, collectionID interface{}, segmentType interface{}, ...) *MockLoader_Load_Call
- func (_e *MockLoader_Expecter) LoadBloomFilterSet(ctx interface{}, collectionID interface{}, version interface{}, ...) *MockLoader_LoadBloomFilterSet_Call
- func (_e *MockLoader_Expecter) LoadDeltaLogs(ctx interface{}, segment interface{}, deltaLogs interface{}) *MockLoader_LoadDeltaLogs_Call
- func (_e *MockLoader_Expecter) LoadIndex(ctx interface{}, segment interface{}, info interface{}, version interface{}) *MockLoader_LoadIndex_Call
- func (_e *MockLoader_Expecter) LoadLazySegment(ctx interface{}, segment interface{}, loadInfo interface{}) *MockLoader_LoadLazySegment_Call
- type MockLoader_LoadBloomFilterSet_Call
- func (_c *MockLoader_LoadBloomFilterSet_Call) Return(_a0 []*pkoracle.BloomFilterSet, _a1 error) *MockLoader_LoadBloomFilterSet_Call
- func (_c *MockLoader_LoadBloomFilterSet_Call) Run(run func(ctx context.Context, collectionID int64, version int64, ...)) *MockLoader_LoadBloomFilterSet_Call
- func (_c *MockLoader_LoadBloomFilterSet_Call) RunAndReturn(...) *MockLoader_LoadBloomFilterSet_Call
- type MockLoader_LoadDeltaLogs_Call
- func (_c *MockLoader_LoadDeltaLogs_Call) Return(_a0 error) *MockLoader_LoadDeltaLogs_Call
- func (_c *MockLoader_LoadDeltaLogs_Call) Run(...) *MockLoader_LoadDeltaLogs_Call
- func (_c *MockLoader_LoadDeltaLogs_Call) RunAndReturn(run func(context.Context, Segment, []*datapb.FieldBinlog) error) *MockLoader_LoadDeltaLogs_Call
- type MockLoader_LoadIndex_Call
- func (_c *MockLoader_LoadIndex_Call) Return(_a0 error) *MockLoader_LoadIndex_Call
- func (_c *MockLoader_LoadIndex_Call) Run(...) *MockLoader_LoadIndex_Call
- func (_c *MockLoader_LoadIndex_Call) RunAndReturn(run func(context.Context, Segment, *querypb.SegmentLoadInfo, int64) error) *MockLoader_LoadIndex_Call
- type MockLoader_LoadLazySegment_Call
- func (_c *MockLoader_LoadLazySegment_Call) Return(_a0 error) *MockLoader_LoadLazySegment_Call
- func (_c *MockLoader_LoadLazySegment_Call) Run(...) *MockLoader_LoadLazySegment_Call
- func (_c *MockLoader_LoadLazySegment_Call) RunAndReturn(run func(context.Context, Segment, *querypb.SegmentLoadInfo) error) *MockLoader_LoadLazySegment_Call
- type MockLoader_Load_Call
- type MockSegment
- func (_m *MockSegment) BatchPkExist(lc *storage.BatchLocationsCache) []bool
- func (_m *MockSegment) CASVersion(_a0 int64, _a1 int64) bool
- func (_m *MockSegment) Collection() int64
- func (_m *MockSegment) DatabaseName() string
- func (_m *MockSegment) Delete(ctx context.Context, primaryKeys []storage.PrimaryKey, timestamps []uint64) error
- func (_m *MockSegment) EXPECT() *MockSegment_Expecter
- func (_m *MockSegment) ExistIndex(fieldID int64) bool
- func (_m *MockSegment) GetIndex(fieldID int64) *IndexedFieldInfo
- func (_m *MockSegment) HasRawData(fieldID int64) bool
- func (_m *MockSegment) ID() int64
- func (_m *MockSegment) Indexes() []*IndexedFieldInfo
- func (_m *MockSegment) Insert(ctx context.Context, rowIDs []int64, timestamps []uint64, ...) error
- func (_m *MockSegment) InsertCount() int64
- func (_m *MockSegment) IsLazyLoad() bool
- func (_m *MockSegment) LastDeltaTimestamp() uint64
- func (_m *MockSegment) Level() datapb.SegmentLevel
- func (_m *MockSegment) LoadDeltaData(ctx context.Context, deltaData *storage.DeleteData) error
- func (_m *MockSegment) LoadDeltaData2(ctx context.Context, schema *schemapb.CollectionSchema) error
- func (_m *MockSegment) LoadInfo() *querypb.SegmentLoadInfo
- func (_m *MockSegment) MayPkExist(lc *storage.LocationsCache) bool
- func (_m *MockSegment) MemSize() int64
- func (_m *MockSegment) NeedUpdatedVersion() int64
- func (_m *MockSegment) Partition() int64
- func (_m *MockSegment) PinIfNotReleased() error
- func (_m *MockSegment) Release(ctx context.Context, opts ...releaseOption)
- func (_m *MockSegment) RemoveUnusedFieldFiles() error
- func (_m *MockSegment) ResetIndexesLazyLoad(lazyState bool)
- func (_m *MockSegment) ResourceGroup() string
- func (_m *MockSegment) ResourceUsageEstimate() ResourceUsage
- func (_m *MockSegment) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error)
- func (_m *MockSegment) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error)
- func (_m *MockSegment) RowNum() int64
- func (_m *MockSegment) Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error)
- func (_m *MockSegment) Shard() metautil.Channel
- func (_m *MockSegment) StartPosition() *msgpb.MsgPosition
- func (_m *MockSegment) Type() commonpb.SegmentState
- func (_m *MockSegment) Unpin()
- func (_m *MockSegment) UpdateBloomFilter(pks []storage.PrimaryKey)
- func (_m *MockSegment) Version() int64
- type MockSegmentManager
- func (_m *MockSegmentManager) Clear(ctx context.Context)
- func (_m *MockSegmentManager) EXPECT() *MockSegmentManager_Expecter
- func (_m *MockSegmentManager) Empty() bool
- func (_m *MockSegmentManager) Exist(segmentID int64, typ commonpb.SegmentState) bool
- func (_m *MockSegmentManager) Get(segmentID int64) Segment
- func (_m *MockSegmentManager) GetAndPin(segments []int64, filters ...SegmentFilter) ([]Segment, error)
- func (_m *MockSegmentManager) GetAndPinBy(filters ...SegmentFilter) ([]Segment, error)
- func (_m *MockSegmentManager) GetBy(filters ...SegmentFilter) []Segment
- func (_m *MockSegmentManager) GetGrowing(segmentID int64) Segment
- func (_m *MockSegmentManager) GetSealed(segmentID int64) Segment
- func (_m *MockSegmentManager) GetWithType(segmentID int64, typ commonpb.SegmentState) Segment
- func (_m *MockSegmentManager) Put(ctx context.Context, segmentType commonpb.SegmentState, segments ...Segment)
- func (_m *MockSegmentManager) Remove(ctx context.Context, segmentID int64, scope querypb.DataScope) (int, int)
- func (_m *MockSegmentManager) RemoveBy(ctx context.Context, filters ...SegmentFilter) (int, int)
- func (_m *MockSegmentManager) Unpin(segments []Segment)
- func (_m *MockSegmentManager) UpdateBy(action SegmentAction, filters ...SegmentFilter) int
- type MockSegmentManager_Clear_Call
- type MockSegmentManager_Empty_Call
- type MockSegmentManager_Exist_Call
- func (_c *MockSegmentManager_Exist_Call) Return(_a0 bool) *MockSegmentManager_Exist_Call
- func (_c *MockSegmentManager_Exist_Call) Run(run func(segmentID int64, typ commonpb.SegmentState)) *MockSegmentManager_Exist_Call
- func (_c *MockSegmentManager_Exist_Call) RunAndReturn(run func(int64, commonpb.SegmentState) bool) *MockSegmentManager_Exist_Call
- type MockSegmentManager_Expecter
- func (_e *MockSegmentManager_Expecter) Clear(ctx interface{}) *MockSegmentManager_Clear_Call
- func (_e *MockSegmentManager_Expecter) Empty() *MockSegmentManager_Empty_Call
- func (_e *MockSegmentManager_Expecter) Exist(segmentID interface{}, typ interface{}) *MockSegmentManager_Exist_Call
- func (_e *MockSegmentManager_Expecter) Get(segmentID interface{}) *MockSegmentManager_Get_Call
- func (_e *MockSegmentManager_Expecter) GetAndPin(segments interface{}, filters ...interface{}) *MockSegmentManager_GetAndPin_Call
- func (_e *MockSegmentManager_Expecter) GetAndPinBy(filters ...interface{}) *MockSegmentManager_GetAndPinBy_Call
- func (_e *MockSegmentManager_Expecter) GetBy(filters ...interface{}) *MockSegmentManager_GetBy_Call
- func (_e *MockSegmentManager_Expecter) GetGrowing(segmentID interface{}) *MockSegmentManager_GetGrowing_Call
- func (_e *MockSegmentManager_Expecter) GetSealed(segmentID interface{}) *MockSegmentManager_GetSealed_Call
- func (_e *MockSegmentManager_Expecter) GetWithType(segmentID interface{}, typ interface{}) *MockSegmentManager_GetWithType_Call
- func (_e *MockSegmentManager_Expecter) Put(ctx interface{}, segmentType interface{}, segments ...interface{}) *MockSegmentManager_Put_Call
- func (_e *MockSegmentManager_Expecter) Remove(ctx interface{}, segmentID interface{}, scope interface{}) *MockSegmentManager_Remove_Call
- func (_e *MockSegmentManager_Expecter) RemoveBy(ctx interface{}, filters ...interface{}) *MockSegmentManager_RemoveBy_Call
- func (_e *MockSegmentManager_Expecter) Unpin(segments interface{}) *MockSegmentManager_Unpin_Call
- func (_e *MockSegmentManager_Expecter) UpdateBy(action interface{}, filters ...interface{}) *MockSegmentManager_UpdateBy_Call
- type MockSegmentManager_GetAndPinBy_Call
- func (_c *MockSegmentManager_GetAndPinBy_Call) Return(_a0 []Segment, _a1 error) *MockSegmentManager_GetAndPinBy_Call
- func (_c *MockSegmentManager_GetAndPinBy_Call) Run(run func(filters ...SegmentFilter)) *MockSegmentManager_GetAndPinBy_Call
- func (_c *MockSegmentManager_GetAndPinBy_Call) RunAndReturn(run func(...SegmentFilter) ([]Segment, error)) *MockSegmentManager_GetAndPinBy_Call
- type MockSegmentManager_GetAndPin_Call
- func (_c *MockSegmentManager_GetAndPin_Call) Return(_a0 []Segment, _a1 error) *MockSegmentManager_GetAndPin_Call
- func (_c *MockSegmentManager_GetAndPin_Call) Run(run func(segments []int64, filters ...SegmentFilter)) *MockSegmentManager_GetAndPin_Call
- func (_c *MockSegmentManager_GetAndPin_Call) RunAndReturn(run func([]int64, ...SegmentFilter) ([]Segment, error)) *MockSegmentManager_GetAndPin_Call
- type MockSegmentManager_GetBy_Call
- func (_c *MockSegmentManager_GetBy_Call) Return(_a0 []Segment) *MockSegmentManager_GetBy_Call
- func (_c *MockSegmentManager_GetBy_Call) Run(run func(filters ...SegmentFilter)) *MockSegmentManager_GetBy_Call
- func (_c *MockSegmentManager_GetBy_Call) RunAndReturn(run func(...SegmentFilter) []Segment) *MockSegmentManager_GetBy_Call
- type MockSegmentManager_GetGrowing_Call
- func (_c *MockSegmentManager_GetGrowing_Call) Return(_a0 Segment) *MockSegmentManager_GetGrowing_Call
- func (_c *MockSegmentManager_GetGrowing_Call) Run(run func(segmentID int64)) *MockSegmentManager_GetGrowing_Call
- func (_c *MockSegmentManager_GetGrowing_Call) RunAndReturn(run func(int64) Segment) *MockSegmentManager_GetGrowing_Call
- type MockSegmentManager_GetSealed_Call
- func (_c *MockSegmentManager_GetSealed_Call) Return(_a0 Segment) *MockSegmentManager_GetSealed_Call
- func (_c *MockSegmentManager_GetSealed_Call) Run(run func(segmentID int64)) *MockSegmentManager_GetSealed_Call
- func (_c *MockSegmentManager_GetSealed_Call) RunAndReturn(run func(int64) Segment) *MockSegmentManager_GetSealed_Call
- type MockSegmentManager_GetWithType_Call
- func (_c *MockSegmentManager_GetWithType_Call) Return(_a0 Segment) *MockSegmentManager_GetWithType_Call
- func (_c *MockSegmentManager_GetWithType_Call) Run(run func(segmentID int64, typ commonpb.SegmentState)) *MockSegmentManager_GetWithType_Call
- func (_c *MockSegmentManager_GetWithType_Call) RunAndReturn(run func(int64, commonpb.SegmentState) Segment) *MockSegmentManager_GetWithType_Call
- type MockSegmentManager_Get_Call
- type MockSegmentManager_Put_Call
- type MockSegmentManager_RemoveBy_Call
- func (_c *MockSegmentManager_RemoveBy_Call) Return(_a0 int, _a1 int) *MockSegmentManager_RemoveBy_Call
- func (_c *MockSegmentManager_RemoveBy_Call) Run(run func(ctx context.Context, filters ...SegmentFilter)) *MockSegmentManager_RemoveBy_Call
- func (_c *MockSegmentManager_RemoveBy_Call) RunAndReturn(run func(context.Context, ...SegmentFilter) (int, int)) *MockSegmentManager_RemoveBy_Call
- type MockSegmentManager_Remove_Call
- func (_c *MockSegmentManager_Remove_Call) Return(_a0 int, _a1 int) *MockSegmentManager_Remove_Call
- func (_c *MockSegmentManager_Remove_Call) Run(run func(ctx context.Context, segmentID int64, scope querypb.DataScope)) *MockSegmentManager_Remove_Call
- func (_c *MockSegmentManager_Remove_Call) RunAndReturn(run func(context.Context, int64, querypb.DataScope) (int, int)) *MockSegmentManager_Remove_Call
- type MockSegmentManager_Unpin_Call
- type MockSegmentManager_UpdateBy_Call
- func (_c *MockSegmentManager_UpdateBy_Call) Return(_a0 int) *MockSegmentManager_UpdateBy_Call
- func (_c *MockSegmentManager_UpdateBy_Call) Run(run func(action SegmentAction, filters ...SegmentFilter)) *MockSegmentManager_UpdateBy_Call
- func (_c *MockSegmentManager_UpdateBy_Call) RunAndReturn(run func(SegmentAction, ...SegmentFilter) int) *MockSegmentManager_UpdateBy_Call
- type MockSegment_BatchPkExist_Call
- func (_c *MockSegment_BatchPkExist_Call) Return(_a0 []bool) *MockSegment_BatchPkExist_Call
- func (_c *MockSegment_BatchPkExist_Call) Run(run func(lc *storage.BatchLocationsCache)) *MockSegment_BatchPkExist_Call
- func (_c *MockSegment_BatchPkExist_Call) RunAndReturn(run func(*storage.BatchLocationsCache) []bool) *MockSegment_BatchPkExist_Call
- type MockSegment_CASVersion_Call
- type MockSegment_Collection_Call
- type MockSegment_DatabaseName_Call
- type MockSegment_Delete_Call
- type MockSegment_ExistIndex_Call
- type MockSegment_Expecter
- func (_e *MockSegment_Expecter) BatchPkExist(lc interface{}) *MockSegment_BatchPkExist_Call
- func (_e *MockSegment_Expecter) CASVersion(_a0 interface{}, _a1 interface{}) *MockSegment_CASVersion_Call
- func (_e *MockSegment_Expecter) Collection() *MockSegment_Collection_Call
- func (_e *MockSegment_Expecter) DatabaseName() *MockSegment_DatabaseName_Call
- func (_e *MockSegment_Expecter) Delete(ctx interface{}, primaryKeys interface{}, timestamps interface{}) *MockSegment_Delete_Call
- func (_e *MockSegment_Expecter) ExistIndex(fieldID interface{}) *MockSegment_ExistIndex_Call
- func (_e *MockSegment_Expecter) GetIndex(fieldID interface{}) *MockSegment_GetIndex_Call
- func (_e *MockSegment_Expecter) HasRawData(fieldID interface{}) *MockSegment_HasRawData_Call
- func (_e *MockSegment_Expecter) ID() *MockSegment_ID_Call
- func (_e *MockSegment_Expecter) Indexes() *MockSegment_Indexes_Call
- func (_e *MockSegment_Expecter) Insert(ctx interface{}, rowIDs interface{}, timestamps interface{}, ...) *MockSegment_Insert_Call
- func (_e *MockSegment_Expecter) InsertCount() *MockSegment_InsertCount_Call
- func (_e *MockSegment_Expecter) IsLazyLoad() *MockSegment_IsLazyLoad_Call
- func (_e *MockSegment_Expecter) LastDeltaTimestamp() *MockSegment_LastDeltaTimestamp_Call
- func (_e *MockSegment_Expecter) Level() *MockSegment_Level_Call
- func (_e *MockSegment_Expecter) LoadDeltaData(ctx interface{}, deltaData interface{}) *MockSegment_LoadDeltaData_Call
- func (_e *MockSegment_Expecter) LoadDeltaData2(ctx interface{}, schema interface{}) *MockSegment_LoadDeltaData2_Call
- func (_e *MockSegment_Expecter) LoadInfo() *MockSegment_LoadInfo_Call
- func (_e *MockSegment_Expecter) MayPkExist(lc interface{}) *MockSegment_MayPkExist_Call
- func (_e *MockSegment_Expecter) MemSize() *MockSegment_MemSize_Call
- func (_e *MockSegment_Expecter) NeedUpdatedVersion() *MockSegment_NeedUpdatedVersion_Call
- func (_e *MockSegment_Expecter) Partition() *MockSegment_Partition_Call
- func (_e *MockSegment_Expecter) PinIfNotReleased() *MockSegment_PinIfNotReleased_Call
- func (_e *MockSegment_Expecter) Release(ctx interface{}, opts ...interface{}) *MockSegment_Release_Call
- func (_e *MockSegment_Expecter) RemoveUnusedFieldFiles() *MockSegment_RemoveUnusedFieldFiles_Call
- func (_e *MockSegment_Expecter) ResetIndexesLazyLoad(lazyState interface{}) *MockSegment_ResetIndexesLazyLoad_Call
- func (_e *MockSegment_Expecter) ResourceGroup() *MockSegment_ResourceGroup_Call
- func (_e *MockSegment_Expecter) ResourceUsageEstimate() *MockSegment_ResourceUsageEstimate_Call
- func (_e *MockSegment_Expecter) Retrieve(ctx interface{}, plan interface{}) *MockSegment_Retrieve_Call
- func (_e *MockSegment_Expecter) RetrieveByOffsets(ctx interface{}, plan interface{}, offsets interface{}) *MockSegment_RetrieveByOffsets_Call
- func (_e *MockSegment_Expecter) RowNum() *MockSegment_RowNum_Call
- func (_e *MockSegment_Expecter) Search(ctx interface{}, searchReq interface{}) *MockSegment_Search_Call
- func (_e *MockSegment_Expecter) Shard() *MockSegment_Shard_Call
- func (_e *MockSegment_Expecter) StartPosition() *MockSegment_StartPosition_Call
- func (_e *MockSegment_Expecter) Type() *MockSegment_Type_Call
- func (_e *MockSegment_Expecter) Unpin() *MockSegment_Unpin_Call
- func (_e *MockSegment_Expecter) UpdateBloomFilter(pks interface{}) *MockSegment_UpdateBloomFilter_Call
- func (_e *MockSegment_Expecter) Version() *MockSegment_Version_Call
- type MockSegment_GetIndex_Call
- type MockSegment_HasRawData_Call
- type MockSegment_ID_Call
- type MockSegment_Indexes_Call
- type MockSegment_InsertCount_Call
- type MockSegment_Insert_Call
- func (_c *MockSegment_Insert_Call) Return(_a0 error) *MockSegment_Insert_Call
- func (_c *MockSegment_Insert_Call) Run(run func(ctx context.Context, rowIDs []int64, timestamps []uint64, ...)) *MockSegment_Insert_Call
- func (_c *MockSegment_Insert_Call) RunAndReturn(run func(context.Context, []int64, []uint64, *segcorepb.InsertRecord) error) *MockSegment_Insert_Call
- type MockSegment_IsLazyLoad_Call
- type MockSegment_LastDeltaTimestamp_Call
- func (_c *MockSegment_LastDeltaTimestamp_Call) Return(_a0 uint64) *MockSegment_LastDeltaTimestamp_Call
- func (_c *MockSegment_LastDeltaTimestamp_Call) Run(run func()) *MockSegment_LastDeltaTimestamp_Call
- func (_c *MockSegment_LastDeltaTimestamp_Call) RunAndReturn(run func() uint64) *MockSegment_LastDeltaTimestamp_Call
- type MockSegment_Level_Call
- type MockSegment_LoadDeltaData2_Call
- func (_c *MockSegment_LoadDeltaData2_Call) Return(_a0 error) *MockSegment_LoadDeltaData2_Call
- func (_c *MockSegment_LoadDeltaData2_Call) Run(run func(ctx context.Context, schema *schemapb.CollectionSchema)) *MockSegment_LoadDeltaData2_Call
- func (_c *MockSegment_LoadDeltaData2_Call) RunAndReturn(run func(context.Context, *schemapb.CollectionSchema) error) *MockSegment_LoadDeltaData2_Call
- type MockSegment_LoadDeltaData_Call
- func (_c *MockSegment_LoadDeltaData_Call) Return(_a0 error) *MockSegment_LoadDeltaData_Call
- func (_c *MockSegment_LoadDeltaData_Call) Run(run func(ctx context.Context, deltaData *storage.DeleteData)) *MockSegment_LoadDeltaData_Call
- func (_c *MockSegment_LoadDeltaData_Call) RunAndReturn(run func(context.Context, *storage.DeleteData) error) *MockSegment_LoadDeltaData_Call
- type MockSegment_LoadInfo_Call
- type MockSegment_MayPkExist_Call
- func (_c *MockSegment_MayPkExist_Call) Return(_a0 bool) *MockSegment_MayPkExist_Call
- func (_c *MockSegment_MayPkExist_Call) Run(run func(lc *storage.LocationsCache)) *MockSegment_MayPkExist_Call
- func (_c *MockSegment_MayPkExist_Call) RunAndReturn(run func(*storage.LocationsCache) bool) *MockSegment_MayPkExist_Call
- type MockSegment_MemSize_Call
- type MockSegment_NeedUpdatedVersion_Call
- func (_c *MockSegment_NeedUpdatedVersion_Call) Return(_a0 int64) *MockSegment_NeedUpdatedVersion_Call
- func (_c *MockSegment_NeedUpdatedVersion_Call) Run(run func()) *MockSegment_NeedUpdatedVersion_Call
- func (_c *MockSegment_NeedUpdatedVersion_Call) RunAndReturn(run func() int64) *MockSegment_NeedUpdatedVersion_Call
- type MockSegment_Partition_Call
- type MockSegment_PinIfNotReleased_Call
- func (_c *MockSegment_PinIfNotReleased_Call) Return(_a0 error) *MockSegment_PinIfNotReleased_Call
- func (_c *MockSegment_PinIfNotReleased_Call) Run(run func()) *MockSegment_PinIfNotReleased_Call
- func (_c *MockSegment_PinIfNotReleased_Call) RunAndReturn(run func() error) *MockSegment_PinIfNotReleased_Call
- type MockSegment_Release_Call
- func (_c *MockSegment_Release_Call) Return() *MockSegment_Release_Call
- func (_c *MockSegment_Release_Call) Run(run func(ctx context.Context, opts ...releaseOption)) *MockSegment_Release_Call
- func (_c *MockSegment_Release_Call) RunAndReturn(run func(context.Context, ...releaseOption)) *MockSegment_Release_Call
- type MockSegment_RemoveUnusedFieldFiles_Call
- func (_c *MockSegment_RemoveUnusedFieldFiles_Call) Return(_a0 error) *MockSegment_RemoveUnusedFieldFiles_Call
- func (_c *MockSegment_RemoveUnusedFieldFiles_Call) Run(run func()) *MockSegment_RemoveUnusedFieldFiles_Call
- func (_c *MockSegment_RemoveUnusedFieldFiles_Call) RunAndReturn(run func() error) *MockSegment_RemoveUnusedFieldFiles_Call
- type MockSegment_ResetIndexesLazyLoad_Call
- func (_c *MockSegment_ResetIndexesLazyLoad_Call) Return() *MockSegment_ResetIndexesLazyLoad_Call
- func (_c *MockSegment_ResetIndexesLazyLoad_Call) Run(run func(lazyState bool)) *MockSegment_ResetIndexesLazyLoad_Call
- func (_c *MockSegment_ResetIndexesLazyLoad_Call) RunAndReturn(run func(bool)) *MockSegment_ResetIndexesLazyLoad_Call
- type MockSegment_ResourceGroup_Call
- type MockSegment_ResourceUsageEstimate_Call
- func (_c *MockSegment_ResourceUsageEstimate_Call) Return(_a0 ResourceUsage) *MockSegment_ResourceUsageEstimate_Call
- func (_c *MockSegment_ResourceUsageEstimate_Call) Run(run func()) *MockSegment_ResourceUsageEstimate_Call
- func (_c *MockSegment_ResourceUsageEstimate_Call) RunAndReturn(run func() ResourceUsage) *MockSegment_ResourceUsageEstimate_Call
- type MockSegment_RetrieveByOffsets_Call
- func (_c *MockSegment_RetrieveByOffsets_Call) Return(_a0 *segcorepb.RetrieveResults, _a1 error) *MockSegment_RetrieveByOffsets_Call
- func (_c *MockSegment_RetrieveByOffsets_Call) Run(run func(ctx context.Context, plan *RetrievePlan, offsets []int64)) *MockSegment_RetrieveByOffsets_Call
- func (_c *MockSegment_RetrieveByOffsets_Call) RunAndReturn(...) *MockSegment_RetrieveByOffsets_Call
- type MockSegment_Retrieve_Call
- func (_c *MockSegment_Retrieve_Call) Return(_a0 *segcorepb.RetrieveResults, _a1 error) *MockSegment_Retrieve_Call
- func (_c *MockSegment_Retrieve_Call) Run(run func(ctx context.Context, plan *RetrievePlan)) *MockSegment_Retrieve_Call
- func (_c *MockSegment_Retrieve_Call) RunAndReturn(run func(context.Context, *RetrievePlan) (*segcorepb.RetrieveResults, error)) *MockSegment_Retrieve_Call
- type MockSegment_RowNum_Call
- type MockSegment_Search_Call
- func (_c *MockSegment_Search_Call) Return(_a0 *SearchResult, _a1 error) *MockSegment_Search_Call
- func (_c *MockSegment_Search_Call) Run(run func(ctx context.Context, searchReq *SearchRequest)) *MockSegment_Search_Call
- func (_c *MockSegment_Search_Call) RunAndReturn(run func(context.Context, *SearchRequest) (*SearchResult, error)) *MockSegment_Search_Call
- type MockSegment_Shard_Call
- type MockSegment_StartPosition_Call
- func (_c *MockSegment_StartPosition_Call) Return(_a0 *msgpb.MsgPosition) *MockSegment_StartPosition_Call
- func (_c *MockSegment_StartPosition_Call) Run(run func()) *MockSegment_StartPosition_Call
- func (_c *MockSegment_StartPosition_Call) RunAndReturn(run func() *msgpb.MsgPosition) *MockSegment_StartPosition_Call
- type MockSegment_Type_Call
- type MockSegment_Unpin_Call
- type MockSegment_UpdateBloomFilter_Call
- func (_c *MockSegment_UpdateBloomFilter_Call) Return() *MockSegment_UpdateBloomFilter_Call
- func (_c *MockSegment_UpdateBloomFilter_Call) Run(run func(pks []storage.PrimaryKey)) *MockSegment_UpdateBloomFilter_Call
- func (_c *MockSegment_UpdateBloomFilter_Call) RunAndReturn(run func([]storage.PrimaryKey)) *MockSegment_UpdateBloomFilter_Call
- type MockSegment_Version_Call
- type ReleaseScope
- type ResourceUsage
- type RetrievePlan
- type RetrieveResult
- type RetrieveSegmentResult
- type SearchPlan
- type SearchRequest
- type SearchResult
- type SearchResultDataBlobs
- type Segment
- func NewL0Segment(collection *Collection, segmentType SegmentType, version int64, ...) (Segment, error)
- func NewSegment(ctx context.Context, collection *Collection, segmentType SegmentType, ...) (Segment, error)
- func RetrieveStream(ctx context.Context, manager *Manager, plan *RetrievePlan, ...) ([]Segment, error)
- func SearchHistoricalStreamly(ctx context.Context, manager *Manager, searchReq *SearchRequest, collID int64, ...) ([]Segment, error)
- type SegmentAction
- type SegmentFilter
- type SegmentFilterFunc
- type SegmentIDFilter
- type SegmentManager
- type SegmentStats
- type SegmentType
- type SegmentTypeFilter
- type SliceInfo
- type StreamSearchReducer
- type TimestampedRetrieveResult
Constants ¶
const ( IndexFaissIDMap = "FLAT" IndexFaissIVFFlat = "IVF_FLAT" IndexFaissIVFPQ = "IVF_PQ" IndexFaissIVFSQ8 = "IVF_SQ8" IndexScaNN = "SCANN" IndexFaissBinIDMap = "BIN_FLAT" IndexFaissBinIVFFlat = "BIN_IVF_FLAT" IndexHNSW = "HNSW" IndexSparseWand = "SPARSE_WAND" )
const ( SegmentTypeGrowing = commonpb.SegmentState_Growing SegmentTypeSealed = commonpb.SegmentState_Sealed )
const (
UsedDiskMemoryRatio = 4
)
Variables ¶
var ErrSegmentUnhealthy = errors.New("segment unhealthy")
Functions ¶
func CopyCProtoBlob ¶
CopyCProtoBlob returns the copy of C memory
func CreateInternalReducer ¶
func CreateInternalReducer(req *querypb.QueryRequest, schema *schemapb.CollectionSchema) internalReducer
func CreateSegCoreReducer ¶
func CreateSegCoreReducer(req *querypb.QueryRequest, schema *schemapb.CollectionSchema, manager *Manager) segCoreReducer
func DecodeSearchResults ¶
func DecodeSearchResults(ctx context.Context, searchResults []*internalpb.SearchResults) ([]*schemapb.SearchResultData, error)
func DeleteCollection ¶
func DeleteCollection(collection *Collection)
deleteCollection delete collection and free the collection memory
func DeleteSearchResultDataBlobs ¶
func DeleteSearchResultDataBlobs(cSearchResultDataBlobs SearchResultDataBlobs)
func DeleteSearchResults ¶
func DeleteSearchResults(results []*SearchResult)
func DeleteStreamReduceHelper ¶
func DeleteStreamReduceHelper(cStreamReduceHelper StreamSearchReducer)
func EncodeSearchResultData ¶
func EncodeSearchResultData(ctx context.Context, searchResultData *schemapb.SearchResultData, nq int64, topk int64, metricType string) (searchResults *internalpb.SearchResults, err error)
func GenAndSaveIndex ¶
func GenAndSaveIndex(collectionID, partitionID, segmentID, fieldID int64, msgLength int, indexType, metricType string, cm storage.ChunkManager) (*querypb.FieldIndexInfo, error)
func GenAndSaveIndexV2 ¶
func GenAndSaveIndexV2(collectionID, partitionID, segmentID, buildID int64, fieldSchema *schemapb.FieldSchema, indexInfo *indexpb.IndexInfo, cm storage.ChunkManager, msgLength int, ) (*querypb.FieldIndexInfo, error)
func GenTestCollectionSchema ¶
func GenTestCollectionSchema(collectionName string, pkType schemapb.DataType, withSparse bool) *schemapb.CollectionSchema
some tests do not yet support sparse float vector, see comments of GenSparseFloatVecDataset in indexcgowrapper/dataset.go
func GenTestIndexInfoList ¶
func GenTestIndexInfoList(collectionID int64, schema *schemapb.CollectionSchema) []*indexpb.IndexInfo
func GenTestIndexMeta ¶
func GenTestIndexMeta(collectionID int64, schema *schemapb.CollectionSchema) *segcorepb.CollectionIndexMeta
func GetBFApplyPool ¶
func GetCProtoBlob ¶
GetCProtoBlob returns the raw C memory, invoker should release it itself
func GetDynamicPool ¶
GetDynamicPool returns the singleton pool for dynamic cgo operations.
func GetLoadPool ¶
func GetPkField ¶
func GetPkField(schema *schemapb.CollectionSchema) *schemapb.FieldSchema
func GetPrimaryKeys ¶
func GetPrimaryKeys(msg *msgstream.InsertMsg, schema *schemapb.CollectionSchema) ([]storage.PrimaryKey, error)
TODO: remove this function to proper file GetPrimaryKeys would get primary keys by insert messages
func GetSearchResultDataBlob ¶
func GetWarmupPool ¶
func HandleCStatus ¶
func HandleCStatus(ctx context.Context, status *C.CStatus, extraInfo string, fields ...zap.Field) error
HandleCStatus deals with the error returned from CGO
func MergeInternalRetrieveResult ¶
func MergeInternalRetrieveResult(ctx context.Context, retrieveResults []*internalpb.RetrieveResults, param *mergeParam) (*internalpb.RetrieveResults, error)
func MergeSegcoreRetrieveResults ¶
func MergeSegcoreRetrieveResults(ctx context.Context, retrieveResults []*segcorepb.RetrieveResults, param *mergeParam, segments []Segment, plan *RetrievePlan, manager *Manager) (*segcorepb.RetrieveResults, error)
func MergeToAdvancedResults ¶
func MergeToAdvancedResults(ctx context.Context, results []*internalpb.SearchResults) (*internalpb.SearchResults, error)
func NewCollectionManager ¶
func NewCollectionManager() *collectionManager
func NewLoader ¶
func NewLoader( manager *Manager, cm storage.ChunkManager, ) *segmentLoader
func NewMergeParam ¶
func NewMergeParam(limit int64, outputFieldsId []int64, schema *schemapb.CollectionSchema, reduceStopForBest bool) *mergeParam
func NewSegmentManager ¶
func NewSegmentManager() *segmentManager
func NewTestChunkManagerFactory ¶
func NewTestChunkManagerFactory(params *paramtable.ComponentParam, rootPath string) *storage.ChunkManagerFactory
func ReduceAdvancedSearchResults ¶
func ReduceAdvancedSearchResults(ctx context.Context, results []*internalpb.SearchResults, nq int64) (*internalpb.SearchResults, error)
func ReduceSearchResultData ¶
func ReduceSearchResultData(ctx context.Context, searchResultData []*schemapb.SearchResultData, nq int64, topk int64) (*schemapb.SearchResultData, error)
func ReduceSearchResults ¶
func ReduceSearchResults(ctx context.Context, results []*internalpb.SearchResults, nq int64, topk int64, metricType string) (*internalpb.SearchResults, error)
func ResizeBFApplyPool ¶
func ResizeLoadPool ¶
func ResizeSQPool ¶
func ResizeWarmupPool ¶
func Retrieve ¶
func Retrieve(ctx context.Context, manager *Manager, plan *RetrievePlan, req *querypb.QueryRequest) ([]RetrieveSegmentResult, []Segment, error)
retrieve will retrieve all the validate target segments
func SaveBinLog ¶
func SaveBinLog(ctx context.Context, collectionID int64, partitionID int64, segmentID int64, msgLength int, schema *schemapb.CollectionSchema, chunkManager storage.ChunkManager, ) ([]*datapb.FieldBinlog, []*datapb.FieldBinlog, error)
func SaveDeltaLog ¶
func SaveDeltaLog(collectionID int64, partitionID int64, segmentID int64, cm storage.ChunkManager, ) ([]*datapb.FieldBinlog, error)
func SearchHistorical ¶
func SearchHistorical(ctx context.Context, manager *Manager, searchReq *SearchRequest, collID int64, partIDs []int64, segIDs []int64) ([]*SearchResult, []Segment, error)
search will search on the historical segments the target segments in historical. if segIDs is not specified, it will search on all the historical segments speficied by partIDs. if segIDs is specified, it will only search on the segments specified by the segIDs. if partIDs is empty, it means all the partitions of the loaded collection or all the partitions loaded.
func SearchStreaming ¶
func SearchStreaming(ctx context.Context, manager *Manager, searchReq *SearchRequest, collID int64, partIDs []int64, segIDs []int64) ([]*SearchResult, []Segment, error)
searchStreaming will search all the target segments in streaming if partIDs is empty, it means all the partitions of the loaded collection or all the partitions loaded.
func SelectSearchResultData ¶
func StatisticStreaming ¶
func StatisticStreaming(ctx context.Context, manager *Manager, collID int64, partIDs []int64, segIDs []int64) ([]SegmentStats, []Segment, error)
StatisticStreaming will do statistics all the target segments in streaming if partIDs is empty, it means all the partitions of the loaded collection or all the partitions loaded.
func StatisticsHistorical ¶
func StatisticsHistorical(ctx context.Context, manager *Manager, collID int64, partIDs []int64, segIDs []int64) ([]SegmentStats, []Segment, error)
statistic will do statistics on the historical segments the target segments in historical. if segIDs is not specified, it will search on all the historical segments specified by partIDs. if segIDs is specified, it will only search on the segments specified by the segIDs. if partIDs is empty, it means all the partitions of the loaded collection or all the partitions loaded.
func StreamReduceSearchResult ¶
func StreamReduceSearchResult(ctx context.Context, newResult *SearchResult, streamReducer StreamSearchReducer, ) error
func UnmarshalCProto ¶
UnmarshalCProto unmarshal the proto from C memory
func WithReleaseScope ¶
func WithReleaseScope(scope ReleaseScope) releaseOption
Types ¶
type CTraceContext ¶
type CTraceContext struct {
// contains filtered or unexported fields
}
CTraceContext is the wrapper for `C.CTraceContext` it stores the internal C.CTraceContext and
func ParseCTraceContext ¶
func ParseCTraceContext(ctx context.Context) *CTraceContext
ParseCTraceContext parses tracing span and convert it into `C.CTraceContext`.
type Collection ¶
type Collection struct {
// contains filtered or unexported fields
}
Collection is a wrapper of the underlying C-structure C.CCollection In a query node, `Collection` is a replica info of a collection in these query node.
func NewCollection ¶
func NewCollection(collectionID int64, schema *schemapb.CollectionSchema, indexMeta *segcorepb.CollectionIndexMeta, loadMetaInfo *querypb.LoadMetaInfo) *Collection
newCollection returns a new Collection
func NewCollectionWithoutSchema ¶
func NewCollectionWithoutSchema(collectionID int64, loadType querypb.LoadType) *Collection
func (*Collection) AddPartition ¶
func (c *Collection) AddPartition(partitions ...int64)
addPartitionID would add a partition id to partition id list of collection
func (*Collection) ExistPartition ¶
func (c *Collection) ExistPartition(partitionIDs ...int64) bool
func (*Collection) GetDBName ¶
func (c *Collection) GetDBName() string
GetDBName returns the database name of collection.
func (*Collection) GetLoadType ¶
func (c *Collection) GetLoadType() querypb.LoadType
getLoadType get the loadType of collection, which is loadTypeCollection or loadTypePartition
func (*Collection) GetPartitions ¶
func (c *Collection) GetPartitions() []int64
getPartitionIDs return partitionIDs of collection
func (*Collection) GetResourceGroup ¶
func (c *Collection) GetResourceGroup() string
GetResourceGroup returns the resource group of collection.
func (*Collection) IsGpuIndex ¶
func (c *Collection) IsGpuIndex() bool
IsGpuIndex returns a boolean value indicating whether the collection is using a GPU index.
func (*Collection) Ref ¶
func (c *Collection) Ref(count uint32) uint32
func (*Collection) RemovePartition ¶
func (c *Collection) RemovePartition(partitionID int64)
removePartitionID removes the partition id from partition id list of collection
func (*Collection) Schema ¶
func (c *Collection) Schema() *schemapb.CollectionSchema
Schema returns the schema of collection
func (*Collection) Unref ¶
func (c *Collection) Unref(count uint32) uint32
type CollectionManager ¶
type CollectionManager interface { List() []int64 Get(collectionID int64) *Collection PutOrRef(collectionID int64, schema *schemapb.CollectionSchema, meta *segcorepb.CollectionIndexMeta, loadMeta *querypb.LoadMetaInfo) Ref(collectionID int64, count uint32) bool // unref the collection, // returns true if the collection ref count goes 0, or the collection not exists, // return false otherwise Unref(collectionID int64, count uint32) bool }
type FieldInfo ¶
type FieldInfo struct { *datapb.FieldBinlog RowCount int64 }
type IndexAttrCache ¶
type IndexAttrCache struct {
// contains filtered or unexported fields
}
IndexAttrCache index meta cache stores calculated attribute.
func NewIndexAttrCache ¶
func NewIndexAttrCache() *IndexAttrCache
func (*IndexAttrCache) GetIndexResourceUsage ¶
func (c *IndexAttrCache) GetIndexResourceUsage(indexInfo *querypb.FieldIndexInfo, memoryIndexLoadPredictMemoryUsageFactor float64, fieldBinlog *datapb.FieldBinlog) (memory uint64, disk uint64, err error)
type IndexedFieldInfo ¶
type IndexedFieldInfo struct { FieldBinlog *datapb.FieldBinlog IndexInfo *querypb.FieldIndexInfo IsLoaded bool }
IndexedFieldInfo contains binlog info of vector field
type L0Segment ¶
type L0Segment struct {
// contains filtered or unexported fields
}
func (*L0Segment) BatchPkExist ¶
func (s *L0Segment) BatchPkExist(lc *storage.BatchLocationsCache) []bool
func (*L0Segment) CASVersion ¶
func (*L0Segment) Collection ¶
func (s *L0Segment) Collection() int64
func (*L0Segment) DatabaseName ¶
func (s *L0Segment) DatabaseName() string
func (*L0Segment) DeleteRecords ¶
func (s *L0Segment) DeleteRecords() ([]storage.PrimaryKey, []uint64)
func (*L0Segment) ExistIndex ¶
func (*L0Segment) GetCollection ¶
func (s *L0Segment) GetCollection() *Collection
func (*L0Segment) GetIndex ¶
func (s *L0Segment) GetIndex(fieldID int64) *IndexedFieldInfo
func (*L0Segment) HasRawData ¶
func (*L0Segment) Indexes ¶
func (s *L0Segment) Indexes() []*IndexedFieldInfo
func (*L0Segment) InsertCount ¶
func (*L0Segment) IsLazyLoad ¶
func (s *L0Segment) IsLazyLoad() bool
func (*L0Segment) LastDeltaTimestamp ¶
func (*L0Segment) Level ¶
func (s *L0Segment) Level() datapb.SegmentLevel
func (*L0Segment) LoadDeltaData ¶
func (*L0Segment) LoadInfo ¶
func (s *L0Segment) LoadInfo() *querypb.SegmentLoadInfo
func (*L0Segment) MayPkExist ¶
func (s *L0Segment) MayPkExist(pk *storage.LocationsCache) bool
MayPkExist returns true if the given PK exists in the PK range and being positive through the bloom filter, false otherwise, may returns true even the PK doesn't exist actually
func (*L0Segment) NeedUpdatedVersion ¶
func (s *L0Segment) NeedUpdatedVersion() int64
func (*L0Segment) PinIfNotReleased ¶
func (*L0Segment) RemoveUnusedFieldFiles ¶
func (*L0Segment) ResetIndexesLazyLoad ¶
func (*L0Segment) ResourceGroup ¶
func (s *L0Segment) ResourceGroup() string
func (*L0Segment) ResourceUsageEstimate ¶
func (s *L0Segment) ResourceUsageEstimate() ResourceUsage
ResourceUsageEstimate returns the estimated resource usage of the segment.
func (*L0Segment) Retrieve ¶
func (s *L0Segment) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error)
func (*L0Segment) RetrieveByOffsets ¶
func (s *L0Segment) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error)
func (*L0Segment) Search ¶
func (s *L0Segment) Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error)
func (*L0Segment) SetLoadInfo ¶
func (s *L0Segment) SetLoadInfo(loadInfo *querypb.SegmentLoadInfo)
func (*L0Segment) SetNeedUpdatedVersion ¶
func (s *L0Segment) SetNeedUpdatedVersion(version int64)
func (*L0Segment) StartPosition ¶
func (s *L0Segment) StartPosition() *msgpb.MsgPosition
func (*L0Segment) Type ¶
func (s *L0Segment) Type() SegmentType
func (*L0Segment) UpdateBloomFilter ¶
func (s *L0Segment) UpdateBloomFilter(pks []storage.PrimaryKey)
type LoadFieldDataInfo ¶
type LoadFieldDataInfo struct {
// contains filtered or unexported fields
}
type LoadIndexInfo ¶
type LoadIndexInfo struct {
// contains filtered or unexported fields
}
LoadIndexInfo is a wrapper of the underlying C-structure C.CLoadIndexInfo
type LoadResource ¶
func (*LoadResource) Add ¶
func (r *LoadResource) Add(resource LoadResource)
func (*LoadResource) IsZero ¶
func (r *LoadResource) IsZero() bool
func (*LoadResource) Sub ¶
func (r *LoadResource) Sub(resource LoadResource)
type Loader ¶
type Loader interface { // Load loads binlogs, and spawn segments, // NOTE: make sure the ref count of the corresponding collection will never go down to 0 during this Load(ctx context.Context, collectionID int64, segmentType SegmentType, version int64, segments ...*querypb.SegmentLoadInfo) ([]Segment, error) LoadDeltaLogs(ctx context.Context, segment Segment, deltaLogs []*datapb.FieldBinlog) error // LoadBloomFilterSet loads needed statslog for RemoteSegment. LoadBloomFilterSet(ctx context.Context, collectionID int64, version int64, infos ...*querypb.SegmentLoadInfo) ([]*pkoracle.BloomFilterSet, error) // LoadIndex append index for segment and remove vector binlogs. LoadIndex(ctx context.Context, segment Segment, info *querypb.SegmentLoadInfo, version int64) error LoadLazySegment(ctx context.Context, segment Segment, loadInfo *querypb.SegmentLoadInfo, ) error }
type LocalSegment ¶
type LocalSegment struct {
// contains filtered or unexported fields
}
Segment is a wrapper of the underlying C-structure segment.
func (*LocalSegment) AddFieldDataInfo ¶
func (s *LocalSegment) AddFieldDataInfo(ctx context.Context, rowCount int64, fields []*datapb.FieldBinlog) error
func (*LocalSegment) BatchPkExist ¶
func (s *LocalSegment) BatchPkExist(lc *storage.BatchLocationsCache) []bool
func (*LocalSegment) CASVersion ¶
func (*LocalSegment) Collection ¶
func (s *LocalSegment) Collection() int64
func (*LocalSegment) DatabaseName ¶
func (s *LocalSegment) DatabaseName() string
func (*LocalSegment) Delete ¶
func (s *LocalSegment) Delete(ctx context.Context, primaryKeys []storage.PrimaryKey, timestamps []typeutil.Timestamp) error
func (*LocalSegment) ExistIndex ¶
func (s *LocalSegment) ExistIndex(fieldID int64) bool
func (*LocalSegment) GetCollection ¶
func (s *LocalSegment) GetCollection() *Collection
func (*LocalSegment) GetFieldDataPath ¶
func (s *LocalSegment) GetFieldDataPath(index *IndexedFieldInfo, offset int64) (dataPath string, offsetInBinlog int64)
func (*LocalSegment) GetIndex ¶
func (s *LocalSegment) GetIndex(fieldID int64) *IndexedFieldInfo
func (*LocalSegment) HasRawData ¶
func (s *LocalSegment) HasRawData(fieldID int64) bool
func (*LocalSegment) Indexes ¶
func (s *LocalSegment) Indexes() []*IndexedFieldInfo
func (*LocalSegment) Insert ¶
func (s *LocalSegment) Insert(ctx context.Context, rowIDs []int64, timestamps []typeutil.Timestamp, record *segcorepb.InsertRecord) error
func (*LocalSegment) InsertCount ¶
func (s *LocalSegment) InsertCount() int64
func (*LocalSegment) IsLazyLoad ¶
func (s *LocalSegment) IsLazyLoad() bool
func (*LocalSegment) LastDeltaTimestamp ¶
func (s *LocalSegment) LastDeltaTimestamp() uint64
func (*LocalSegment) Level ¶
func (s *LocalSegment) Level() datapb.SegmentLevel
func (*LocalSegment) LoadDeltaData ¶
func (s *LocalSegment) LoadDeltaData(ctx context.Context, deltaData *storage.DeleteData) error
func (*LocalSegment) LoadFieldData ¶
func (s *LocalSegment) LoadFieldData(ctx context.Context, fieldID int64, rowCount int64, field *datapb.FieldBinlog, useMmap bool) error
func (*LocalSegment) LoadIndex ¶
func (s *LocalSegment) LoadIndex(ctx context.Context, indexInfo *querypb.FieldIndexInfo, fieldType schemapb.DataType) error
func (*LocalSegment) LoadInfo ¶
func (s *LocalSegment) LoadInfo() *querypb.SegmentLoadInfo
func (*LocalSegment) LoadMultiFieldData ¶
func (s *LocalSegment) LoadMultiFieldData(ctx context.Context) error
-------------------------------------------------------------------------------------- interfaces for sealed segment
func (*LocalSegment) MayPkExist ¶
func (s *LocalSegment) MayPkExist(pk *storage.LocationsCache) bool
MayPkExist returns true if the given PK exists in the PK range and being positive through the bloom filter, false otherwise, may returns true even the PK doesn't exist actually
func (*LocalSegment) MemSize ¶
func (s *LocalSegment) MemSize() int64
func (*LocalSegment) NeedUpdatedVersion ¶
func (s *LocalSegment) NeedUpdatedVersion() int64
func (*LocalSegment) PinIfNotReleased ¶
func (s *LocalSegment) PinIfNotReleased() error
PinIfNotReleased acquires the `ptrLock` and returns true if the pointer is valid Provide ONLY the read lock operations, don't make `ptrLock` public to avoid abusing of the mutex.
func (*LocalSegment) Release ¶
func (s *LocalSegment) Release(ctx context.Context, opts ...releaseOption)
func (*LocalSegment) ReleaseSegmentData ¶
func (s *LocalSegment) ReleaseSegmentData()
ReleaseSegmentData releases the segment data.
func (*LocalSegment) RemoveFieldFile ¶
func (s *LocalSegment) RemoveFieldFile(fieldId int64)
func (*LocalSegment) RemoveUnusedFieldFiles ¶
func (s *LocalSegment) RemoveUnusedFieldFiles() error
func (*LocalSegment) ResetIndexesLazyLoad ¶
func (s *LocalSegment) ResetIndexesLazyLoad(lazyState bool)
func (*LocalSegment) ResourceGroup ¶
func (s *LocalSegment) ResourceGroup() string
func (*LocalSegment) ResourceUsageEstimate ¶
func (s *LocalSegment) ResourceUsageEstimate() ResourceUsage
ResourceUsageEstimate returns the estimated resource usage of the segment.
func (*LocalSegment) Retrieve ¶
func (s *LocalSegment) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error)
func (*LocalSegment) RetrieveByOffsets ¶
func (s *LocalSegment) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error)
func (*LocalSegment) RowNum ¶
func (s *LocalSegment) RowNum() int64
func (*LocalSegment) Search ¶
func (s *LocalSegment) Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error)
func (*LocalSegment) SetLoadInfo ¶
func (s *LocalSegment) SetLoadInfo(loadInfo *querypb.SegmentLoadInfo)
func (*LocalSegment) SetNeedUpdatedVersion ¶
func (s *LocalSegment) SetNeedUpdatedVersion(version int64)
func (*LocalSegment) StartLoadData ¶
func (s *LocalSegment) StartLoadData() (state.LoadStateLockGuard, error)
StartLoadData starts the loading process of the segment.
func (*LocalSegment) StartPosition ¶
func (s *LocalSegment) StartPosition() *msgpb.MsgPosition
func (*LocalSegment) Type ¶
func (s *LocalSegment) Type() SegmentType
func (*LocalSegment) Unpin ¶
func (s *LocalSegment) Unpin()
func (*LocalSegment) UpdateBloomFilter ¶
func (s *LocalSegment) UpdateBloomFilter(pks []storage.PrimaryKey)
func (*LocalSegment) UpdateFieldRawDataSize ¶
func (s *LocalSegment) UpdateFieldRawDataSize(ctx context.Context, numRows int64, fieldBinlog *datapb.FieldBinlog) error
func (*LocalSegment) UpdateIndexInfo ¶
func (s *LocalSegment) UpdateIndexInfo(ctx context.Context, indexInfo *querypb.FieldIndexInfo, info *LoadIndexInfo) error
func (*LocalSegment) WarmupChunkCache ¶
func (s *LocalSegment) WarmupChunkCache(ctx context.Context, fieldID int64)
type Manager ¶
type Manager struct { Collection CollectionManager Segment SegmentManager DiskCache cache.Cache[int64, Segment] Loader Loader }
func NewManager ¶
func NewManager() *Manager
type MockCollectionManager ¶
MockCollectionManager is an autogenerated mock type for the CollectionManager type
func NewMockCollectionManager ¶
func NewMockCollectionManager(t interface { mock.TestingT Cleanup(func()) }) *MockCollectionManager
NewMockCollectionManager creates a new instance of MockCollectionManager. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockCollectionManager) EXPECT ¶
func (_m *MockCollectionManager) EXPECT() *MockCollectionManager_Expecter
func (*MockCollectionManager) Get ¶
func (_m *MockCollectionManager) Get(collectionID int64) *Collection
Get provides a mock function with given fields: collectionID
func (*MockCollectionManager) List ¶
func (_m *MockCollectionManager) List() []int64
List provides a mock function with given fields:
func (*MockCollectionManager) PutOrRef ¶
func (_m *MockCollectionManager) PutOrRef(collectionID int64, schema *schemapb.CollectionSchema, meta *segcorepb.CollectionIndexMeta, loadMeta *querypb.LoadMetaInfo)
PutOrRef provides a mock function with given fields: collectionID, schema, meta, loadMeta
type MockCollectionManager_Expecter ¶
type MockCollectionManager_Expecter struct {
// contains filtered or unexported fields
}
func (*MockCollectionManager_Expecter) Get ¶
func (_e *MockCollectionManager_Expecter) Get(collectionID interface{}) *MockCollectionManager_Get_Call
Get is a helper method to define mock.On call
- collectionID int64
func (*MockCollectionManager_Expecter) List ¶
func (_e *MockCollectionManager_Expecter) List() *MockCollectionManager_List_Call
List is a helper method to define mock.On call
func (*MockCollectionManager_Expecter) PutOrRef ¶
func (_e *MockCollectionManager_Expecter) PutOrRef(collectionID interface{}, schema interface{}, meta interface{}, loadMeta interface{}) *MockCollectionManager_PutOrRef_Call
PutOrRef is a helper method to define mock.On call
- collectionID int64
- schema *schemapb.CollectionSchema
- meta *segcorepb.CollectionIndexMeta
- loadMeta *querypb.LoadMetaInfo
func (*MockCollectionManager_Expecter) Ref ¶
func (_e *MockCollectionManager_Expecter) Ref(collectionID interface{}, count interface{}) *MockCollectionManager_Ref_Call
Ref is a helper method to define mock.On call
- collectionID int64
- count uint32
func (*MockCollectionManager_Expecter) Unref ¶
func (_e *MockCollectionManager_Expecter) Unref(collectionID interface{}, count interface{}) *MockCollectionManager_Unref_Call
Unref is a helper method to define mock.On call
- collectionID int64
- count uint32
type MockCollectionManager_Get_Call ¶
MockCollectionManager_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*MockCollectionManager_Get_Call) Return ¶
func (_c *MockCollectionManager_Get_Call) Return(_a0 *Collection) *MockCollectionManager_Get_Call
func (*MockCollectionManager_Get_Call) Run ¶
func (_c *MockCollectionManager_Get_Call) Run(run func(collectionID int64)) *MockCollectionManager_Get_Call
func (*MockCollectionManager_Get_Call) RunAndReturn ¶
func (_c *MockCollectionManager_Get_Call) RunAndReturn(run func(int64) *Collection) *MockCollectionManager_Get_Call
type MockCollectionManager_List_Call ¶
MockCollectionManager_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*MockCollectionManager_List_Call) Return ¶
func (_c *MockCollectionManager_List_Call) Return(_a0 []int64) *MockCollectionManager_List_Call
func (*MockCollectionManager_List_Call) Run ¶
func (_c *MockCollectionManager_List_Call) Run(run func()) *MockCollectionManager_List_Call
func (*MockCollectionManager_List_Call) RunAndReturn ¶
func (_c *MockCollectionManager_List_Call) RunAndReturn(run func() []int64) *MockCollectionManager_List_Call
type MockCollectionManager_PutOrRef_Call ¶
MockCollectionManager_PutOrRef_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PutOrRef'
func (*MockCollectionManager_PutOrRef_Call) Return ¶
func (_c *MockCollectionManager_PutOrRef_Call) Return() *MockCollectionManager_PutOrRef_Call
func (*MockCollectionManager_PutOrRef_Call) Run ¶
func (_c *MockCollectionManager_PutOrRef_Call) Run(run func(collectionID int64, schema *schemapb.CollectionSchema, meta *segcorepb.CollectionIndexMeta, loadMeta *querypb.LoadMetaInfo)) *MockCollectionManager_PutOrRef_Call
func (*MockCollectionManager_PutOrRef_Call) RunAndReturn ¶
func (_c *MockCollectionManager_PutOrRef_Call) RunAndReturn(run func(int64, *schemapb.CollectionSchema, *segcorepb.CollectionIndexMeta, *querypb.LoadMetaInfo)) *MockCollectionManager_PutOrRef_Call
type MockCollectionManager_Ref_Call ¶
MockCollectionManager_Ref_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Ref'
func (*MockCollectionManager_Ref_Call) Return ¶
func (_c *MockCollectionManager_Ref_Call) Return(_a0 bool) *MockCollectionManager_Ref_Call
func (*MockCollectionManager_Ref_Call) Run ¶
func (_c *MockCollectionManager_Ref_Call) Run(run func(collectionID int64, count uint32)) *MockCollectionManager_Ref_Call
func (*MockCollectionManager_Ref_Call) RunAndReturn ¶
func (_c *MockCollectionManager_Ref_Call) RunAndReturn(run func(int64, uint32) bool) *MockCollectionManager_Ref_Call
type MockCollectionManager_Unref_Call ¶
MockCollectionManager_Unref_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Unref'
func (*MockCollectionManager_Unref_Call) Return ¶
func (_c *MockCollectionManager_Unref_Call) Return(_a0 bool) *MockCollectionManager_Unref_Call
func (*MockCollectionManager_Unref_Call) Run ¶
func (_c *MockCollectionManager_Unref_Call) Run(run func(collectionID int64, count uint32)) *MockCollectionManager_Unref_Call
func (*MockCollectionManager_Unref_Call) RunAndReturn ¶
func (_c *MockCollectionManager_Unref_Call) RunAndReturn(run func(int64, uint32) bool) *MockCollectionManager_Unref_Call
type MockLoader ¶
MockLoader is an autogenerated mock type for the Loader type
func NewMockLoader ¶
func NewMockLoader(t interface { mock.TestingT Cleanup(func()) }) *MockLoader
NewMockLoader creates a new instance of MockLoader. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockLoader) EXPECT ¶
func (_m *MockLoader) EXPECT() *MockLoader_Expecter
func (*MockLoader) Load ¶
func (_m *MockLoader) Load(ctx context.Context, collectionID int64, segmentType commonpb.SegmentState, version int64, segments ...*querypb.SegmentLoadInfo) ([]Segment, error)
Load provides a mock function with given fields: ctx, collectionID, segmentType, version, segments
func (*MockLoader) LoadBloomFilterSet ¶
func (_m *MockLoader) LoadBloomFilterSet(ctx context.Context, collectionID int64, version int64, infos ...*querypb.SegmentLoadInfo) ([]*pkoracle.BloomFilterSet, error)
LoadBloomFilterSet provides a mock function with given fields: ctx, collectionID, version, infos
func (*MockLoader) LoadDeltaLogs ¶
func (_m *MockLoader) LoadDeltaLogs(ctx context.Context, segment Segment, deltaLogs []*datapb.FieldBinlog) error
LoadDeltaLogs provides a mock function with given fields: ctx, segment, deltaLogs
func (*MockLoader) LoadIndex ¶
func (_m *MockLoader) LoadIndex(ctx context.Context, segment Segment, info *querypb.SegmentLoadInfo, version int64) error
LoadIndex provides a mock function with given fields: ctx, segment, info, version
func (*MockLoader) LoadLazySegment ¶
func (_m *MockLoader) LoadLazySegment(ctx context.Context, segment Segment, loadInfo *querypb.SegmentLoadInfo) error
LoadLazySegment provides a mock function with given fields: ctx, segment, loadInfo
type MockLoader_Expecter ¶
type MockLoader_Expecter struct {
// contains filtered or unexported fields
}
func (*MockLoader_Expecter) Load ¶
func (_e *MockLoader_Expecter) Load(ctx interface{}, collectionID interface{}, segmentType interface{}, version interface{}, segments ...interface{}) *MockLoader_Load_Call
Load is a helper method to define mock.On call
- ctx context.Context
- collectionID int64
- segmentType commonpb.SegmentState
- version int64
- segments ...*querypb.SegmentLoadInfo
func (*MockLoader_Expecter) LoadBloomFilterSet ¶
func (_e *MockLoader_Expecter) LoadBloomFilterSet(ctx interface{}, collectionID interface{}, version interface{}, infos ...interface{}) *MockLoader_LoadBloomFilterSet_Call
LoadBloomFilterSet is a helper method to define mock.On call
- ctx context.Context
- collectionID int64
- version int64
- infos ...*querypb.SegmentLoadInfo
func (*MockLoader_Expecter) LoadDeltaLogs ¶
func (_e *MockLoader_Expecter) LoadDeltaLogs(ctx interface{}, segment interface{}, deltaLogs interface{}) *MockLoader_LoadDeltaLogs_Call
LoadDeltaLogs is a helper method to define mock.On call
- ctx context.Context
- segment Segment
- deltaLogs []*datapb.FieldBinlog
func (*MockLoader_Expecter) LoadIndex ¶
func (_e *MockLoader_Expecter) LoadIndex(ctx interface{}, segment interface{}, info interface{}, version interface{}) *MockLoader_LoadIndex_Call
LoadIndex is a helper method to define mock.On call
- ctx context.Context
- segment Segment
- info *querypb.SegmentLoadInfo
- version int64
func (*MockLoader_Expecter) LoadLazySegment ¶
func (_e *MockLoader_Expecter) LoadLazySegment(ctx interface{}, segment interface{}, loadInfo interface{}) *MockLoader_LoadLazySegment_Call
LoadLazySegment is a helper method to define mock.On call
- ctx context.Context
- segment Segment
- loadInfo *querypb.SegmentLoadInfo
type MockLoader_LoadBloomFilterSet_Call ¶
MockLoader_LoadBloomFilterSet_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadBloomFilterSet'
func (*MockLoader_LoadBloomFilterSet_Call) Return ¶
func (_c *MockLoader_LoadBloomFilterSet_Call) Return(_a0 []*pkoracle.BloomFilterSet, _a1 error) *MockLoader_LoadBloomFilterSet_Call
func (*MockLoader_LoadBloomFilterSet_Call) Run ¶
func (_c *MockLoader_LoadBloomFilterSet_Call) Run(run func(ctx context.Context, collectionID int64, version int64, infos ...*querypb.SegmentLoadInfo)) *MockLoader_LoadBloomFilterSet_Call
func (*MockLoader_LoadBloomFilterSet_Call) RunAndReturn ¶
func (_c *MockLoader_LoadBloomFilterSet_Call) RunAndReturn(run func(context.Context, int64, int64, ...*querypb.SegmentLoadInfo) ([]*pkoracle.BloomFilterSet, error)) *MockLoader_LoadBloomFilterSet_Call
type MockLoader_LoadDeltaLogs_Call ¶
MockLoader_LoadDeltaLogs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadDeltaLogs'
func (*MockLoader_LoadDeltaLogs_Call) Return ¶
func (_c *MockLoader_LoadDeltaLogs_Call) Return(_a0 error) *MockLoader_LoadDeltaLogs_Call
func (*MockLoader_LoadDeltaLogs_Call) Run ¶
func (_c *MockLoader_LoadDeltaLogs_Call) Run(run func(ctx context.Context, segment Segment, deltaLogs []*datapb.FieldBinlog)) *MockLoader_LoadDeltaLogs_Call
func (*MockLoader_LoadDeltaLogs_Call) RunAndReturn ¶
func (_c *MockLoader_LoadDeltaLogs_Call) RunAndReturn(run func(context.Context, Segment, []*datapb.FieldBinlog) error) *MockLoader_LoadDeltaLogs_Call
type MockLoader_LoadIndex_Call ¶
MockLoader_LoadIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadIndex'
func (*MockLoader_LoadIndex_Call) Return ¶
func (_c *MockLoader_LoadIndex_Call) Return(_a0 error) *MockLoader_LoadIndex_Call
func (*MockLoader_LoadIndex_Call) Run ¶
func (_c *MockLoader_LoadIndex_Call) Run(run func(ctx context.Context, segment Segment, info *querypb.SegmentLoadInfo, version int64)) *MockLoader_LoadIndex_Call
func (*MockLoader_LoadIndex_Call) RunAndReturn ¶
func (_c *MockLoader_LoadIndex_Call) RunAndReturn(run func(context.Context, Segment, *querypb.SegmentLoadInfo, int64) error) *MockLoader_LoadIndex_Call
type MockLoader_LoadLazySegment_Call ¶
MockLoader_LoadLazySegment_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadLazySegment'
func (*MockLoader_LoadLazySegment_Call) Return ¶
func (_c *MockLoader_LoadLazySegment_Call) Return(_a0 error) *MockLoader_LoadLazySegment_Call
func (*MockLoader_LoadLazySegment_Call) Run ¶
func (_c *MockLoader_LoadLazySegment_Call) Run(run func(ctx context.Context, segment Segment, loadInfo *querypb.SegmentLoadInfo)) *MockLoader_LoadLazySegment_Call
func (*MockLoader_LoadLazySegment_Call) RunAndReturn ¶
func (_c *MockLoader_LoadLazySegment_Call) RunAndReturn(run func(context.Context, Segment, *querypb.SegmentLoadInfo) error) *MockLoader_LoadLazySegment_Call
type MockLoader_Load_Call ¶
MockLoader_Load_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Load'
func (*MockLoader_Load_Call) Return ¶
func (_c *MockLoader_Load_Call) Return(_a0 []Segment, _a1 error) *MockLoader_Load_Call
func (*MockLoader_Load_Call) Run ¶
func (_c *MockLoader_Load_Call) Run(run func(ctx context.Context, collectionID int64, segmentType commonpb.SegmentState, version int64, segments ...*querypb.SegmentLoadInfo)) *MockLoader_Load_Call
func (*MockLoader_Load_Call) RunAndReturn ¶
func (_c *MockLoader_Load_Call) RunAndReturn(run func(context.Context, int64, commonpb.SegmentState, int64, ...*querypb.SegmentLoadInfo) ([]Segment, error)) *MockLoader_Load_Call
type MockSegment ¶
MockSegment is an autogenerated mock type for the Segment type
func NewMockSegment ¶
func NewMockSegment(t interface { mock.TestingT Cleanup(func()) }) *MockSegment
NewMockSegment creates a new instance of MockSegment. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockSegment) BatchPkExist ¶
func (_m *MockSegment) BatchPkExist(lc *storage.BatchLocationsCache) []bool
BatchPkExist provides a mock function with given fields: lc
func (*MockSegment) CASVersion ¶
func (_m *MockSegment) CASVersion(_a0 int64, _a1 int64) bool
CASVersion provides a mock function with given fields: _a0, _a1
func (*MockSegment) Collection ¶
func (_m *MockSegment) Collection() int64
Collection provides a mock function with given fields:
func (*MockSegment) DatabaseName ¶
func (_m *MockSegment) DatabaseName() string
DatabaseName provides a mock function with given fields:
func (*MockSegment) Delete ¶
func (_m *MockSegment) Delete(ctx context.Context, primaryKeys []storage.PrimaryKey, timestamps []uint64) error
Delete provides a mock function with given fields: ctx, primaryKeys, timestamps
func (*MockSegment) EXPECT ¶
func (_m *MockSegment) EXPECT() *MockSegment_Expecter
func (*MockSegment) ExistIndex ¶
func (_m *MockSegment) ExistIndex(fieldID int64) bool
ExistIndex provides a mock function with given fields: fieldID
func (*MockSegment) GetIndex ¶
func (_m *MockSegment) GetIndex(fieldID int64) *IndexedFieldInfo
GetIndex provides a mock function with given fields: fieldID
func (*MockSegment) HasRawData ¶
func (_m *MockSegment) HasRawData(fieldID int64) bool
HasRawData provides a mock function with given fields: fieldID
func (*MockSegment) ID ¶
func (_m *MockSegment) ID() int64
ID provides a mock function with given fields:
func (*MockSegment) Indexes ¶
func (_m *MockSegment) Indexes() []*IndexedFieldInfo
Indexes provides a mock function with given fields:
func (*MockSegment) Insert ¶
func (_m *MockSegment) Insert(ctx context.Context, rowIDs []int64, timestamps []uint64, record *segcorepb.InsertRecord) error
Insert provides a mock function with given fields: ctx, rowIDs, timestamps, record
func (*MockSegment) InsertCount ¶
func (_m *MockSegment) InsertCount() int64
InsertCount provides a mock function with given fields:
func (*MockSegment) IsLazyLoad ¶
func (_m *MockSegment) IsLazyLoad() bool
IsLazyLoad provides a mock function with given fields:
func (*MockSegment) LastDeltaTimestamp ¶
func (_m *MockSegment) LastDeltaTimestamp() uint64
LastDeltaTimestamp provides a mock function with given fields:
func (*MockSegment) Level ¶
func (_m *MockSegment) Level() datapb.SegmentLevel
Level provides a mock function with given fields:
func (*MockSegment) LoadDeltaData ¶
func (_m *MockSegment) LoadDeltaData(ctx context.Context, deltaData *storage.DeleteData) error
LoadDeltaData provides a mock function with given fields: ctx, deltaData
func (*MockSegment) LoadDeltaData2 ¶
func (_m *MockSegment) LoadDeltaData2(ctx context.Context, schema *schemapb.CollectionSchema) error
LoadDeltaData2 provides a mock function with given fields: ctx, schema
func (*MockSegment) LoadInfo ¶
func (_m *MockSegment) LoadInfo() *querypb.SegmentLoadInfo
LoadInfo provides a mock function with given fields:
func (*MockSegment) MayPkExist ¶
func (_m *MockSegment) MayPkExist(lc *storage.LocationsCache) bool
MayPkExist provides a mock function with given fields: lc
func (*MockSegment) MemSize ¶
func (_m *MockSegment) MemSize() int64
MemSize provides a mock function with given fields:
func (*MockSegment) NeedUpdatedVersion ¶
func (_m *MockSegment) NeedUpdatedVersion() int64
NeedUpdatedVersion provides a mock function with given fields:
func (*MockSegment) Partition ¶
func (_m *MockSegment) Partition() int64
Partition provides a mock function with given fields:
func (*MockSegment) PinIfNotReleased ¶
func (_m *MockSegment) PinIfNotReleased() error
PinIfNotReleased provides a mock function with given fields:
func (*MockSegment) Release ¶
func (_m *MockSegment) Release(ctx context.Context, opts ...releaseOption)
Release provides a mock function with given fields: ctx, opts
func (*MockSegment) RemoveUnusedFieldFiles ¶
func (_m *MockSegment) RemoveUnusedFieldFiles() error
RemoveUnusedFieldFiles provides a mock function with given fields:
func (*MockSegment) ResetIndexesLazyLoad ¶
func (_m *MockSegment) ResetIndexesLazyLoad(lazyState bool)
ResetIndexesLazyLoad provides a mock function with given fields: lazyState
func (*MockSegment) ResourceGroup ¶
func (_m *MockSegment) ResourceGroup() string
ResourceGroup provides a mock function with given fields:
func (*MockSegment) ResourceUsageEstimate ¶
func (_m *MockSegment) ResourceUsageEstimate() ResourceUsage
ResourceUsageEstimate provides a mock function with given fields:
func (*MockSegment) Retrieve ¶
func (_m *MockSegment) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error)
Retrieve provides a mock function with given fields: ctx, plan
func (*MockSegment) RetrieveByOffsets ¶
func (_m *MockSegment) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error)
RetrieveByOffsets provides a mock function with given fields: ctx, plan, offsets
func (*MockSegment) RowNum ¶
func (_m *MockSegment) RowNum() int64
RowNum provides a mock function with given fields:
func (*MockSegment) Search ¶
func (_m *MockSegment) Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error)
Search provides a mock function with given fields: ctx, searchReq
func (*MockSegment) Shard ¶
func (_m *MockSegment) Shard() metautil.Channel
Shard provides a mock function with given fields:
func (*MockSegment) StartPosition ¶
func (_m *MockSegment) StartPosition() *msgpb.MsgPosition
StartPosition provides a mock function with given fields:
func (*MockSegment) Type ¶
func (_m *MockSegment) Type() commonpb.SegmentState
Type provides a mock function with given fields:
func (*MockSegment) Unpin ¶
func (_m *MockSegment) Unpin()
Unpin provides a mock function with given fields:
func (*MockSegment) UpdateBloomFilter ¶
func (_m *MockSegment) UpdateBloomFilter(pks []storage.PrimaryKey)
UpdateBloomFilter provides a mock function with given fields: pks
func (*MockSegment) Version ¶
func (_m *MockSegment) Version() int64
Version provides a mock function with given fields:
type MockSegmentManager ¶
MockSegmentManager is an autogenerated mock type for the SegmentManager type
func NewMockSegmentManager ¶
func NewMockSegmentManager(t interface { mock.TestingT Cleanup(func()) }) *MockSegmentManager
NewMockSegmentManager creates a new instance of MockSegmentManager. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockSegmentManager) Clear ¶
func (_m *MockSegmentManager) Clear(ctx context.Context)
Clear provides a mock function with given fields: ctx
func (*MockSegmentManager) EXPECT ¶
func (_m *MockSegmentManager) EXPECT() *MockSegmentManager_Expecter
func (*MockSegmentManager) Empty ¶
func (_m *MockSegmentManager) Empty() bool
Empty provides a mock function with given fields:
func (*MockSegmentManager) Exist ¶
func (_m *MockSegmentManager) Exist(segmentID int64, typ commonpb.SegmentState) bool
Exist provides a mock function with given fields: segmentID, typ
func (*MockSegmentManager) Get ¶
func (_m *MockSegmentManager) Get(segmentID int64) Segment
Get provides a mock function with given fields: segmentID
func (*MockSegmentManager) GetAndPin ¶
func (_m *MockSegmentManager) GetAndPin(segments []int64, filters ...SegmentFilter) ([]Segment, error)
GetAndPin provides a mock function with given fields: segments, filters
func (*MockSegmentManager) GetAndPinBy ¶
func (_m *MockSegmentManager) GetAndPinBy(filters ...SegmentFilter) ([]Segment, error)
GetAndPinBy provides a mock function with given fields: filters
func (*MockSegmentManager) GetBy ¶
func (_m *MockSegmentManager) GetBy(filters ...SegmentFilter) []Segment
GetBy provides a mock function with given fields: filters
func (*MockSegmentManager) GetGrowing ¶
func (_m *MockSegmentManager) GetGrowing(segmentID int64) Segment
GetGrowing provides a mock function with given fields: segmentID
func (*MockSegmentManager) GetSealed ¶
func (_m *MockSegmentManager) GetSealed(segmentID int64) Segment
GetSealed provides a mock function with given fields: segmentID
func (*MockSegmentManager) GetWithType ¶
func (_m *MockSegmentManager) GetWithType(segmentID int64, typ commonpb.SegmentState) Segment
GetWithType provides a mock function with given fields: segmentID, typ
func (*MockSegmentManager) Put ¶
func (_m *MockSegmentManager) Put(ctx context.Context, segmentType commonpb.SegmentState, segments ...Segment)
Put provides a mock function with given fields: ctx, segmentType, segments
func (*MockSegmentManager) Remove ¶
func (_m *MockSegmentManager) Remove(ctx context.Context, segmentID int64, scope querypb.DataScope) (int, int)
Remove provides a mock function with given fields: ctx, segmentID, scope
func (*MockSegmentManager) RemoveBy ¶
func (_m *MockSegmentManager) RemoveBy(ctx context.Context, filters ...SegmentFilter) (int, int)
RemoveBy provides a mock function with given fields: ctx, filters
func (*MockSegmentManager) Unpin ¶
func (_m *MockSegmentManager) Unpin(segments []Segment)
Unpin provides a mock function with given fields: segments
func (*MockSegmentManager) UpdateBy ¶
func (_m *MockSegmentManager) UpdateBy(action SegmentAction, filters ...SegmentFilter) int
UpdateBy provides a mock function with given fields: action, filters
type MockSegmentManager_Clear_Call ¶
MockSegmentManager_Clear_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Clear'
func (*MockSegmentManager_Clear_Call) Return ¶
func (_c *MockSegmentManager_Clear_Call) Return() *MockSegmentManager_Clear_Call
func (*MockSegmentManager_Clear_Call) Run ¶
func (_c *MockSegmentManager_Clear_Call) Run(run func(ctx context.Context)) *MockSegmentManager_Clear_Call
func (*MockSegmentManager_Clear_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Clear_Call) RunAndReturn(run func(context.Context)) *MockSegmentManager_Clear_Call
type MockSegmentManager_Empty_Call ¶
MockSegmentManager_Empty_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Empty'
func (*MockSegmentManager_Empty_Call) Return ¶
func (_c *MockSegmentManager_Empty_Call) Return(_a0 bool) *MockSegmentManager_Empty_Call
func (*MockSegmentManager_Empty_Call) Run ¶
func (_c *MockSegmentManager_Empty_Call) Run(run func()) *MockSegmentManager_Empty_Call
func (*MockSegmentManager_Empty_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Empty_Call) RunAndReturn(run func() bool) *MockSegmentManager_Empty_Call
type MockSegmentManager_Exist_Call ¶
MockSegmentManager_Exist_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Exist'
func (*MockSegmentManager_Exist_Call) Return ¶
func (_c *MockSegmentManager_Exist_Call) Return(_a0 bool) *MockSegmentManager_Exist_Call
func (*MockSegmentManager_Exist_Call) Run ¶
func (_c *MockSegmentManager_Exist_Call) Run(run func(segmentID int64, typ commonpb.SegmentState)) *MockSegmentManager_Exist_Call
func (*MockSegmentManager_Exist_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Exist_Call) RunAndReturn(run func(int64, commonpb.SegmentState) bool) *MockSegmentManager_Exist_Call
type MockSegmentManager_Expecter ¶
type MockSegmentManager_Expecter struct {
// contains filtered or unexported fields
}
func (*MockSegmentManager_Expecter) Clear ¶
func (_e *MockSegmentManager_Expecter) Clear(ctx interface{}) *MockSegmentManager_Clear_Call
Clear is a helper method to define mock.On call
- ctx context.Context
func (*MockSegmentManager_Expecter) Empty ¶
func (_e *MockSegmentManager_Expecter) Empty() *MockSegmentManager_Empty_Call
Empty is a helper method to define mock.On call
func (*MockSegmentManager_Expecter) Exist ¶
func (_e *MockSegmentManager_Expecter) Exist(segmentID interface{}, typ interface{}) *MockSegmentManager_Exist_Call
Exist is a helper method to define mock.On call
- segmentID int64
- typ commonpb.SegmentState
func (*MockSegmentManager_Expecter) Get ¶
func (_e *MockSegmentManager_Expecter) Get(segmentID interface{}) *MockSegmentManager_Get_Call
Get is a helper method to define mock.On call
- segmentID int64
func (*MockSegmentManager_Expecter) GetAndPin ¶
func (_e *MockSegmentManager_Expecter) GetAndPin(segments interface{}, filters ...interface{}) *MockSegmentManager_GetAndPin_Call
GetAndPin is a helper method to define mock.On call
- segments []int64
- filters ...SegmentFilter
func (*MockSegmentManager_Expecter) GetAndPinBy ¶
func (_e *MockSegmentManager_Expecter) GetAndPinBy(filters ...interface{}) *MockSegmentManager_GetAndPinBy_Call
GetAndPinBy is a helper method to define mock.On call
- filters ...SegmentFilter
func (*MockSegmentManager_Expecter) GetBy ¶
func (_e *MockSegmentManager_Expecter) GetBy(filters ...interface{}) *MockSegmentManager_GetBy_Call
GetBy is a helper method to define mock.On call
- filters ...SegmentFilter
func (*MockSegmentManager_Expecter) GetGrowing ¶
func (_e *MockSegmentManager_Expecter) GetGrowing(segmentID interface{}) *MockSegmentManager_GetGrowing_Call
GetGrowing is a helper method to define mock.On call
- segmentID int64
func (*MockSegmentManager_Expecter) GetSealed ¶
func (_e *MockSegmentManager_Expecter) GetSealed(segmentID interface{}) *MockSegmentManager_GetSealed_Call
GetSealed is a helper method to define mock.On call
- segmentID int64
func (*MockSegmentManager_Expecter) GetWithType ¶
func (_e *MockSegmentManager_Expecter) GetWithType(segmentID interface{}, typ interface{}) *MockSegmentManager_GetWithType_Call
GetWithType is a helper method to define mock.On call
- segmentID int64
- typ commonpb.SegmentState
func (*MockSegmentManager_Expecter) Put ¶
func (_e *MockSegmentManager_Expecter) Put(ctx interface{}, segmentType interface{}, segments ...interface{}) *MockSegmentManager_Put_Call
Put is a helper method to define mock.On call
- ctx context.Context
- segmentType commonpb.SegmentState
- segments ...Segment
func (*MockSegmentManager_Expecter) Remove ¶
func (_e *MockSegmentManager_Expecter) Remove(ctx interface{}, segmentID interface{}, scope interface{}) *MockSegmentManager_Remove_Call
Remove is a helper method to define mock.On call
- ctx context.Context
- segmentID int64
- scope querypb.DataScope
func (*MockSegmentManager_Expecter) RemoveBy ¶
func (_e *MockSegmentManager_Expecter) RemoveBy(ctx interface{}, filters ...interface{}) *MockSegmentManager_RemoveBy_Call
RemoveBy is a helper method to define mock.On call
- ctx context.Context
- filters ...SegmentFilter
func (*MockSegmentManager_Expecter) Unpin ¶
func (_e *MockSegmentManager_Expecter) Unpin(segments interface{}) *MockSegmentManager_Unpin_Call
Unpin is a helper method to define mock.On call
- segments []Segment
func (*MockSegmentManager_Expecter) UpdateBy ¶
func (_e *MockSegmentManager_Expecter) UpdateBy(action interface{}, filters ...interface{}) *MockSegmentManager_UpdateBy_Call
UpdateBy is a helper method to define mock.On call
- action SegmentAction
- filters ...SegmentFilter
type MockSegmentManager_GetAndPinBy_Call ¶
MockSegmentManager_GetAndPinBy_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAndPinBy'
func (*MockSegmentManager_GetAndPinBy_Call) Return ¶
func (_c *MockSegmentManager_GetAndPinBy_Call) Return(_a0 []Segment, _a1 error) *MockSegmentManager_GetAndPinBy_Call
func (*MockSegmentManager_GetAndPinBy_Call) Run ¶
func (_c *MockSegmentManager_GetAndPinBy_Call) Run(run func(filters ...SegmentFilter)) *MockSegmentManager_GetAndPinBy_Call
func (*MockSegmentManager_GetAndPinBy_Call) RunAndReturn ¶
func (_c *MockSegmentManager_GetAndPinBy_Call) RunAndReturn(run func(...SegmentFilter) ([]Segment, error)) *MockSegmentManager_GetAndPinBy_Call
type MockSegmentManager_GetAndPin_Call ¶
MockSegmentManager_GetAndPin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAndPin'
func (*MockSegmentManager_GetAndPin_Call) Return ¶
func (_c *MockSegmentManager_GetAndPin_Call) Return(_a0 []Segment, _a1 error) *MockSegmentManager_GetAndPin_Call
func (*MockSegmentManager_GetAndPin_Call) Run ¶
func (_c *MockSegmentManager_GetAndPin_Call) Run(run func(segments []int64, filters ...SegmentFilter)) *MockSegmentManager_GetAndPin_Call
func (*MockSegmentManager_GetAndPin_Call) RunAndReturn ¶
func (_c *MockSegmentManager_GetAndPin_Call) RunAndReturn(run func([]int64, ...SegmentFilter) ([]Segment, error)) *MockSegmentManager_GetAndPin_Call
type MockSegmentManager_GetBy_Call ¶
MockSegmentManager_GetBy_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetBy'
func (*MockSegmentManager_GetBy_Call) Return ¶
func (_c *MockSegmentManager_GetBy_Call) Return(_a0 []Segment) *MockSegmentManager_GetBy_Call
func (*MockSegmentManager_GetBy_Call) Run ¶
func (_c *MockSegmentManager_GetBy_Call) Run(run func(filters ...SegmentFilter)) *MockSegmentManager_GetBy_Call
func (*MockSegmentManager_GetBy_Call) RunAndReturn ¶
func (_c *MockSegmentManager_GetBy_Call) RunAndReturn(run func(...SegmentFilter) []Segment) *MockSegmentManager_GetBy_Call
type MockSegmentManager_GetGrowing_Call ¶
MockSegmentManager_GetGrowing_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetGrowing'
func (*MockSegmentManager_GetGrowing_Call) Return ¶
func (_c *MockSegmentManager_GetGrowing_Call) Return(_a0 Segment) *MockSegmentManager_GetGrowing_Call
func (*MockSegmentManager_GetGrowing_Call) Run ¶
func (_c *MockSegmentManager_GetGrowing_Call) Run(run func(segmentID int64)) *MockSegmentManager_GetGrowing_Call
func (*MockSegmentManager_GetGrowing_Call) RunAndReturn ¶
func (_c *MockSegmentManager_GetGrowing_Call) RunAndReturn(run func(int64) Segment) *MockSegmentManager_GetGrowing_Call
type MockSegmentManager_GetSealed_Call ¶
MockSegmentManager_GetSealed_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSealed'
func (*MockSegmentManager_GetSealed_Call) Return ¶
func (_c *MockSegmentManager_GetSealed_Call) Return(_a0 Segment) *MockSegmentManager_GetSealed_Call
func (*MockSegmentManager_GetSealed_Call) Run ¶
func (_c *MockSegmentManager_GetSealed_Call) Run(run func(segmentID int64)) *MockSegmentManager_GetSealed_Call
func (*MockSegmentManager_GetSealed_Call) RunAndReturn ¶
func (_c *MockSegmentManager_GetSealed_Call) RunAndReturn(run func(int64) Segment) *MockSegmentManager_GetSealed_Call
type MockSegmentManager_GetWithType_Call ¶
MockSegmentManager_GetWithType_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetWithType'
func (*MockSegmentManager_GetWithType_Call) Return ¶
func (_c *MockSegmentManager_GetWithType_Call) Return(_a0 Segment) *MockSegmentManager_GetWithType_Call
func (*MockSegmentManager_GetWithType_Call) Run ¶
func (_c *MockSegmentManager_GetWithType_Call) Run(run func(segmentID int64, typ commonpb.SegmentState)) *MockSegmentManager_GetWithType_Call
func (*MockSegmentManager_GetWithType_Call) RunAndReturn ¶
func (_c *MockSegmentManager_GetWithType_Call) RunAndReturn(run func(int64, commonpb.SegmentState) Segment) *MockSegmentManager_GetWithType_Call
type MockSegmentManager_Get_Call ¶
MockSegmentManager_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*MockSegmentManager_Get_Call) Return ¶
func (_c *MockSegmentManager_Get_Call) Return(_a0 Segment) *MockSegmentManager_Get_Call
func (*MockSegmentManager_Get_Call) Run ¶
func (_c *MockSegmentManager_Get_Call) Run(run func(segmentID int64)) *MockSegmentManager_Get_Call
func (*MockSegmentManager_Get_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Get_Call) RunAndReturn(run func(int64) Segment) *MockSegmentManager_Get_Call
type MockSegmentManager_Put_Call ¶
MockSegmentManager_Put_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Put'
func (*MockSegmentManager_Put_Call) Return ¶
func (_c *MockSegmentManager_Put_Call) Return() *MockSegmentManager_Put_Call
func (*MockSegmentManager_Put_Call) Run ¶
func (_c *MockSegmentManager_Put_Call) Run(run func(ctx context.Context, segmentType commonpb.SegmentState, segments ...Segment)) *MockSegmentManager_Put_Call
func (*MockSegmentManager_Put_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Put_Call) RunAndReturn(run func(context.Context, commonpb.SegmentState, ...Segment)) *MockSegmentManager_Put_Call
type MockSegmentManager_RemoveBy_Call ¶
MockSegmentManager_RemoveBy_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoveBy'
func (*MockSegmentManager_RemoveBy_Call) Return ¶
func (_c *MockSegmentManager_RemoveBy_Call) Return(_a0 int, _a1 int) *MockSegmentManager_RemoveBy_Call
func (*MockSegmentManager_RemoveBy_Call) Run ¶
func (_c *MockSegmentManager_RemoveBy_Call) Run(run func(ctx context.Context, filters ...SegmentFilter)) *MockSegmentManager_RemoveBy_Call
func (*MockSegmentManager_RemoveBy_Call) RunAndReturn ¶
func (_c *MockSegmentManager_RemoveBy_Call) RunAndReturn(run func(context.Context, ...SegmentFilter) (int, int)) *MockSegmentManager_RemoveBy_Call
type MockSegmentManager_Remove_Call ¶
MockSegmentManager_Remove_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remove'
func (*MockSegmentManager_Remove_Call) Return ¶
func (_c *MockSegmentManager_Remove_Call) Return(_a0 int, _a1 int) *MockSegmentManager_Remove_Call
func (*MockSegmentManager_Remove_Call) Run ¶
func (_c *MockSegmentManager_Remove_Call) Run(run func(ctx context.Context, segmentID int64, scope querypb.DataScope)) *MockSegmentManager_Remove_Call
func (*MockSegmentManager_Remove_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Remove_Call) RunAndReturn(run func(context.Context, int64, querypb.DataScope) (int, int)) *MockSegmentManager_Remove_Call
type MockSegmentManager_Unpin_Call ¶
MockSegmentManager_Unpin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Unpin'
func (*MockSegmentManager_Unpin_Call) Return ¶
func (_c *MockSegmentManager_Unpin_Call) Return() *MockSegmentManager_Unpin_Call
func (*MockSegmentManager_Unpin_Call) Run ¶
func (_c *MockSegmentManager_Unpin_Call) Run(run func(segments []Segment)) *MockSegmentManager_Unpin_Call
func (*MockSegmentManager_Unpin_Call) RunAndReturn ¶
func (_c *MockSegmentManager_Unpin_Call) RunAndReturn(run func([]Segment)) *MockSegmentManager_Unpin_Call
type MockSegmentManager_UpdateBy_Call ¶
MockSegmentManager_UpdateBy_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateBy'
func (*MockSegmentManager_UpdateBy_Call) Return ¶
func (_c *MockSegmentManager_UpdateBy_Call) Return(_a0 int) *MockSegmentManager_UpdateBy_Call
func (*MockSegmentManager_UpdateBy_Call) Run ¶
func (_c *MockSegmentManager_UpdateBy_Call) Run(run func(action SegmentAction, filters ...SegmentFilter)) *MockSegmentManager_UpdateBy_Call
func (*MockSegmentManager_UpdateBy_Call) RunAndReturn ¶
func (_c *MockSegmentManager_UpdateBy_Call) RunAndReturn(run func(SegmentAction, ...SegmentFilter) int) *MockSegmentManager_UpdateBy_Call
type MockSegment_BatchPkExist_Call ¶
MockSegment_BatchPkExist_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'BatchPkExist'
func (*MockSegment_BatchPkExist_Call) Return ¶
func (_c *MockSegment_BatchPkExist_Call) Return(_a0 []bool) *MockSegment_BatchPkExist_Call
func (*MockSegment_BatchPkExist_Call) Run ¶
func (_c *MockSegment_BatchPkExist_Call) Run(run func(lc *storage.BatchLocationsCache)) *MockSegment_BatchPkExist_Call
func (*MockSegment_BatchPkExist_Call) RunAndReturn ¶
func (_c *MockSegment_BatchPkExist_Call) RunAndReturn(run func(*storage.BatchLocationsCache) []bool) *MockSegment_BatchPkExist_Call
type MockSegment_CASVersion_Call ¶
MockSegment_CASVersion_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CASVersion'
func (*MockSegment_CASVersion_Call) Return ¶
func (_c *MockSegment_CASVersion_Call) Return(_a0 bool) *MockSegment_CASVersion_Call
func (*MockSegment_CASVersion_Call) Run ¶
func (_c *MockSegment_CASVersion_Call) Run(run func(_a0 int64, _a1 int64)) *MockSegment_CASVersion_Call
func (*MockSegment_CASVersion_Call) RunAndReturn ¶
func (_c *MockSegment_CASVersion_Call) RunAndReturn(run func(int64, int64) bool) *MockSegment_CASVersion_Call
type MockSegment_Collection_Call ¶
MockSegment_Collection_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Collection'
func (*MockSegment_Collection_Call) Return ¶
func (_c *MockSegment_Collection_Call) Return(_a0 int64) *MockSegment_Collection_Call
func (*MockSegment_Collection_Call) Run ¶
func (_c *MockSegment_Collection_Call) Run(run func()) *MockSegment_Collection_Call
func (*MockSegment_Collection_Call) RunAndReturn ¶
func (_c *MockSegment_Collection_Call) RunAndReturn(run func() int64) *MockSegment_Collection_Call
type MockSegment_DatabaseName_Call ¶
MockSegment_DatabaseName_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DatabaseName'
func (*MockSegment_DatabaseName_Call) Return ¶
func (_c *MockSegment_DatabaseName_Call) Return(_a0 string) *MockSegment_DatabaseName_Call
func (*MockSegment_DatabaseName_Call) Run ¶
func (_c *MockSegment_DatabaseName_Call) Run(run func()) *MockSegment_DatabaseName_Call
func (*MockSegment_DatabaseName_Call) RunAndReturn ¶
func (_c *MockSegment_DatabaseName_Call) RunAndReturn(run func() string) *MockSegment_DatabaseName_Call
type MockSegment_Delete_Call ¶
MockSegment_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*MockSegment_Delete_Call) Return ¶
func (_c *MockSegment_Delete_Call) Return(_a0 error) *MockSegment_Delete_Call
func (*MockSegment_Delete_Call) Run ¶
func (_c *MockSegment_Delete_Call) Run(run func(ctx context.Context, primaryKeys []storage.PrimaryKey, timestamps []uint64)) *MockSegment_Delete_Call
func (*MockSegment_Delete_Call) RunAndReturn ¶
func (_c *MockSegment_Delete_Call) RunAndReturn(run func(context.Context, []storage.PrimaryKey, []uint64) error) *MockSegment_Delete_Call
type MockSegment_ExistIndex_Call ¶
MockSegment_ExistIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExistIndex'
func (*MockSegment_ExistIndex_Call) Return ¶
func (_c *MockSegment_ExistIndex_Call) Return(_a0 bool) *MockSegment_ExistIndex_Call
func (*MockSegment_ExistIndex_Call) Run ¶
func (_c *MockSegment_ExistIndex_Call) Run(run func(fieldID int64)) *MockSegment_ExistIndex_Call
func (*MockSegment_ExistIndex_Call) RunAndReturn ¶
func (_c *MockSegment_ExistIndex_Call) RunAndReturn(run func(int64) bool) *MockSegment_ExistIndex_Call
type MockSegment_Expecter ¶
type MockSegment_Expecter struct {
// contains filtered or unexported fields
}
func (*MockSegment_Expecter) BatchPkExist ¶
func (_e *MockSegment_Expecter) BatchPkExist(lc interface{}) *MockSegment_BatchPkExist_Call
BatchPkExist is a helper method to define mock.On call
- lc *storage.BatchLocationsCache
func (*MockSegment_Expecter) CASVersion ¶
func (_e *MockSegment_Expecter) CASVersion(_a0 interface{}, _a1 interface{}) *MockSegment_CASVersion_Call
CASVersion is a helper method to define mock.On call
- _a0 int64
- _a1 int64
func (*MockSegment_Expecter) Collection ¶
func (_e *MockSegment_Expecter) Collection() *MockSegment_Collection_Call
Collection is a helper method to define mock.On call
func (*MockSegment_Expecter) DatabaseName ¶
func (_e *MockSegment_Expecter) DatabaseName() *MockSegment_DatabaseName_Call
DatabaseName is a helper method to define mock.On call
func (*MockSegment_Expecter) Delete ¶
func (_e *MockSegment_Expecter) Delete(ctx interface{}, primaryKeys interface{}, timestamps interface{}) *MockSegment_Delete_Call
Delete is a helper method to define mock.On call
- ctx context.Context
- primaryKeys []storage.PrimaryKey
- timestamps []uint64
func (*MockSegment_Expecter) ExistIndex ¶
func (_e *MockSegment_Expecter) ExistIndex(fieldID interface{}) *MockSegment_ExistIndex_Call
ExistIndex is a helper method to define mock.On call
- fieldID int64
func (*MockSegment_Expecter) GetIndex ¶
func (_e *MockSegment_Expecter) GetIndex(fieldID interface{}) *MockSegment_GetIndex_Call
GetIndex is a helper method to define mock.On call
- fieldID int64
func (*MockSegment_Expecter) HasRawData ¶
func (_e *MockSegment_Expecter) HasRawData(fieldID interface{}) *MockSegment_HasRawData_Call
HasRawData is a helper method to define mock.On call
- fieldID int64
func (*MockSegment_Expecter) ID ¶
func (_e *MockSegment_Expecter) ID() *MockSegment_ID_Call
ID is a helper method to define mock.On call
func (*MockSegment_Expecter) Indexes ¶
func (_e *MockSegment_Expecter) Indexes() *MockSegment_Indexes_Call
Indexes is a helper method to define mock.On call
func (*MockSegment_Expecter) Insert ¶
func (_e *MockSegment_Expecter) Insert(ctx interface{}, rowIDs interface{}, timestamps interface{}, record interface{}) *MockSegment_Insert_Call
Insert is a helper method to define mock.On call
- ctx context.Context
- rowIDs []int64
- timestamps []uint64
- record *segcorepb.InsertRecord
func (*MockSegment_Expecter) InsertCount ¶
func (_e *MockSegment_Expecter) InsertCount() *MockSegment_InsertCount_Call
InsertCount is a helper method to define mock.On call
func (*MockSegment_Expecter) IsLazyLoad ¶
func (_e *MockSegment_Expecter) IsLazyLoad() *MockSegment_IsLazyLoad_Call
IsLazyLoad is a helper method to define mock.On call
func (*MockSegment_Expecter) LastDeltaTimestamp ¶
func (_e *MockSegment_Expecter) LastDeltaTimestamp() *MockSegment_LastDeltaTimestamp_Call
LastDeltaTimestamp is a helper method to define mock.On call
func (*MockSegment_Expecter) Level ¶
func (_e *MockSegment_Expecter) Level() *MockSegment_Level_Call
Level is a helper method to define mock.On call
func (*MockSegment_Expecter) LoadDeltaData ¶
func (_e *MockSegment_Expecter) LoadDeltaData(ctx interface{}, deltaData interface{}) *MockSegment_LoadDeltaData_Call
LoadDeltaData is a helper method to define mock.On call
- ctx context.Context
- deltaData *storage.DeleteData
func (*MockSegment_Expecter) LoadDeltaData2 ¶
func (_e *MockSegment_Expecter) LoadDeltaData2(ctx interface{}, schema interface{}) *MockSegment_LoadDeltaData2_Call
LoadDeltaData2 is a helper method to define mock.On call
- ctx context.Context
- schema *schemapb.CollectionSchema
func (*MockSegment_Expecter) LoadInfo ¶
func (_e *MockSegment_Expecter) LoadInfo() *MockSegment_LoadInfo_Call
LoadInfo is a helper method to define mock.On call
func (*MockSegment_Expecter) MayPkExist ¶
func (_e *MockSegment_Expecter) MayPkExist(lc interface{}) *MockSegment_MayPkExist_Call
MayPkExist is a helper method to define mock.On call
- lc *storage.LocationsCache
func (*MockSegment_Expecter) MemSize ¶
func (_e *MockSegment_Expecter) MemSize() *MockSegment_MemSize_Call
MemSize is a helper method to define mock.On call
func (*MockSegment_Expecter) NeedUpdatedVersion ¶
func (_e *MockSegment_Expecter) NeedUpdatedVersion() *MockSegment_NeedUpdatedVersion_Call
NeedUpdatedVersion is a helper method to define mock.On call
func (*MockSegment_Expecter) Partition ¶
func (_e *MockSegment_Expecter) Partition() *MockSegment_Partition_Call
Partition is a helper method to define mock.On call
func (*MockSegment_Expecter) PinIfNotReleased ¶
func (_e *MockSegment_Expecter) PinIfNotReleased() *MockSegment_PinIfNotReleased_Call
PinIfNotReleased is a helper method to define mock.On call
func (*MockSegment_Expecter) Release ¶
func (_e *MockSegment_Expecter) Release(ctx interface{}, opts ...interface{}) *MockSegment_Release_Call
Release is a helper method to define mock.On call
- ctx context.Context
- opts ...releaseOption
func (*MockSegment_Expecter) RemoveUnusedFieldFiles ¶
func (_e *MockSegment_Expecter) RemoveUnusedFieldFiles() *MockSegment_RemoveUnusedFieldFiles_Call
RemoveUnusedFieldFiles is a helper method to define mock.On call
func (*MockSegment_Expecter) ResetIndexesLazyLoad ¶
func (_e *MockSegment_Expecter) ResetIndexesLazyLoad(lazyState interface{}) *MockSegment_ResetIndexesLazyLoad_Call
ResetIndexesLazyLoad is a helper method to define mock.On call
- lazyState bool
func (*MockSegment_Expecter) ResourceGroup ¶
func (_e *MockSegment_Expecter) ResourceGroup() *MockSegment_ResourceGroup_Call
ResourceGroup is a helper method to define mock.On call
func (*MockSegment_Expecter) ResourceUsageEstimate ¶
func (_e *MockSegment_Expecter) ResourceUsageEstimate() *MockSegment_ResourceUsageEstimate_Call
ResourceUsageEstimate is a helper method to define mock.On call
func (*MockSegment_Expecter) Retrieve ¶
func (_e *MockSegment_Expecter) Retrieve(ctx interface{}, plan interface{}) *MockSegment_Retrieve_Call
Retrieve is a helper method to define mock.On call
- ctx context.Context
- plan *RetrievePlan
func (*MockSegment_Expecter) RetrieveByOffsets ¶
func (_e *MockSegment_Expecter) RetrieveByOffsets(ctx interface{}, plan interface{}, offsets interface{}) *MockSegment_RetrieveByOffsets_Call
RetrieveByOffsets is a helper method to define mock.On call
- ctx context.Context
- plan *RetrievePlan
- offsets []int64
func (*MockSegment_Expecter) RowNum ¶
func (_e *MockSegment_Expecter) RowNum() *MockSegment_RowNum_Call
RowNum is a helper method to define mock.On call
func (*MockSegment_Expecter) Search ¶
func (_e *MockSegment_Expecter) Search(ctx interface{}, searchReq interface{}) *MockSegment_Search_Call
Search is a helper method to define mock.On call
- ctx context.Context
- searchReq *SearchRequest
func (*MockSegment_Expecter) Shard ¶
func (_e *MockSegment_Expecter) Shard() *MockSegment_Shard_Call
Shard is a helper method to define mock.On call
func (*MockSegment_Expecter) StartPosition ¶
func (_e *MockSegment_Expecter) StartPosition() *MockSegment_StartPosition_Call
StartPosition is a helper method to define mock.On call
func (*MockSegment_Expecter) Type ¶
func (_e *MockSegment_Expecter) Type() *MockSegment_Type_Call
Type is a helper method to define mock.On call
func (*MockSegment_Expecter) Unpin ¶
func (_e *MockSegment_Expecter) Unpin() *MockSegment_Unpin_Call
Unpin is a helper method to define mock.On call
func (*MockSegment_Expecter) UpdateBloomFilter ¶
func (_e *MockSegment_Expecter) UpdateBloomFilter(pks interface{}) *MockSegment_UpdateBloomFilter_Call
UpdateBloomFilter is a helper method to define mock.On call
- pks []storage.PrimaryKey
func (*MockSegment_Expecter) Version ¶
func (_e *MockSegment_Expecter) Version() *MockSegment_Version_Call
Version is a helper method to define mock.On call
type MockSegment_GetIndex_Call ¶
MockSegment_GetIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndex'
func (*MockSegment_GetIndex_Call) Return ¶
func (_c *MockSegment_GetIndex_Call) Return(_a0 *IndexedFieldInfo) *MockSegment_GetIndex_Call
func (*MockSegment_GetIndex_Call) Run ¶
func (_c *MockSegment_GetIndex_Call) Run(run func(fieldID int64)) *MockSegment_GetIndex_Call
func (*MockSegment_GetIndex_Call) RunAndReturn ¶
func (_c *MockSegment_GetIndex_Call) RunAndReturn(run func(int64) *IndexedFieldInfo) *MockSegment_GetIndex_Call
type MockSegment_HasRawData_Call ¶
MockSegment_HasRawData_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HasRawData'
func (*MockSegment_HasRawData_Call) Return ¶
func (_c *MockSegment_HasRawData_Call) Return(_a0 bool) *MockSegment_HasRawData_Call
func (*MockSegment_HasRawData_Call) Run ¶
func (_c *MockSegment_HasRawData_Call) Run(run func(fieldID int64)) *MockSegment_HasRawData_Call
func (*MockSegment_HasRawData_Call) RunAndReturn ¶
func (_c *MockSegment_HasRawData_Call) RunAndReturn(run func(int64) bool) *MockSegment_HasRawData_Call
type MockSegment_ID_Call ¶
MockSegment_ID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ID'
func (*MockSegment_ID_Call) Return ¶
func (_c *MockSegment_ID_Call) Return(_a0 int64) *MockSegment_ID_Call
func (*MockSegment_ID_Call) Run ¶
func (_c *MockSegment_ID_Call) Run(run func()) *MockSegment_ID_Call
func (*MockSegment_ID_Call) RunAndReturn ¶
func (_c *MockSegment_ID_Call) RunAndReturn(run func() int64) *MockSegment_ID_Call
type MockSegment_Indexes_Call ¶
MockSegment_Indexes_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Indexes'
func (*MockSegment_Indexes_Call) Return ¶
func (_c *MockSegment_Indexes_Call) Return(_a0 []*IndexedFieldInfo) *MockSegment_Indexes_Call
func (*MockSegment_Indexes_Call) Run ¶
func (_c *MockSegment_Indexes_Call) Run(run func()) *MockSegment_Indexes_Call
func (*MockSegment_Indexes_Call) RunAndReturn ¶
func (_c *MockSegment_Indexes_Call) RunAndReturn(run func() []*IndexedFieldInfo) *MockSegment_Indexes_Call
type MockSegment_InsertCount_Call ¶
MockSegment_InsertCount_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InsertCount'
func (*MockSegment_InsertCount_Call) Return ¶
func (_c *MockSegment_InsertCount_Call) Return(_a0 int64) *MockSegment_InsertCount_Call
func (*MockSegment_InsertCount_Call) Run ¶
func (_c *MockSegment_InsertCount_Call) Run(run func()) *MockSegment_InsertCount_Call
func (*MockSegment_InsertCount_Call) RunAndReturn ¶
func (_c *MockSegment_InsertCount_Call) RunAndReturn(run func() int64) *MockSegment_InsertCount_Call
type MockSegment_Insert_Call ¶
MockSegment_Insert_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Insert'
func (*MockSegment_Insert_Call) Return ¶
func (_c *MockSegment_Insert_Call) Return(_a0 error) *MockSegment_Insert_Call
func (*MockSegment_Insert_Call) Run ¶
func (_c *MockSegment_Insert_Call) Run(run func(ctx context.Context, rowIDs []int64, timestamps []uint64, record *segcorepb.InsertRecord)) *MockSegment_Insert_Call
func (*MockSegment_Insert_Call) RunAndReturn ¶
func (_c *MockSegment_Insert_Call) RunAndReturn(run func(context.Context, []int64, []uint64, *segcorepb.InsertRecord) error) *MockSegment_Insert_Call
type MockSegment_IsLazyLoad_Call ¶
MockSegment_IsLazyLoad_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsLazyLoad'
func (*MockSegment_IsLazyLoad_Call) Return ¶
func (_c *MockSegment_IsLazyLoad_Call) Return(_a0 bool) *MockSegment_IsLazyLoad_Call
func (*MockSegment_IsLazyLoad_Call) Run ¶
func (_c *MockSegment_IsLazyLoad_Call) Run(run func()) *MockSegment_IsLazyLoad_Call
func (*MockSegment_IsLazyLoad_Call) RunAndReturn ¶
func (_c *MockSegment_IsLazyLoad_Call) RunAndReturn(run func() bool) *MockSegment_IsLazyLoad_Call
type MockSegment_LastDeltaTimestamp_Call ¶
MockSegment_LastDeltaTimestamp_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LastDeltaTimestamp'
func (*MockSegment_LastDeltaTimestamp_Call) Return ¶
func (_c *MockSegment_LastDeltaTimestamp_Call) Return(_a0 uint64) *MockSegment_LastDeltaTimestamp_Call
func (*MockSegment_LastDeltaTimestamp_Call) Run ¶
func (_c *MockSegment_LastDeltaTimestamp_Call) Run(run func()) *MockSegment_LastDeltaTimestamp_Call
func (*MockSegment_LastDeltaTimestamp_Call) RunAndReturn ¶
func (_c *MockSegment_LastDeltaTimestamp_Call) RunAndReturn(run func() uint64) *MockSegment_LastDeltaTimestamp_Call
type MockSegment_Level_Call ¶
MockSegment_Level_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Level'
func (*MockSegment_Level_Call) Return ¶
func (_c *MockSegment_Level_Call) Return(_a0 datapb.SegmentLevel) *MockSegment_Level_Call
func (*MockSegment_Level_Call) Run ¶
func (_c *MockSegment_Level_Call) Run(run func()) *MockSegment_Level_Call
func (*MockSegment_Level_Call) RunAndReturn ¶
func (_c *MockSegment_Level_Call) RunAndReturn(run func() datapb.SegmentLevel) *MockSegment_Level_Call
type MockSegment_LoadDeltaData2_Call ¶
MockSegment_LoadDeltaData2_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadDeltaData2'
func (*MockSegment_LoadDeltaData2_Call) Return ¶
func (_c *MockSegment_LoadDeltaData2_Call) Return(_a0 error) *MockSegment_LoadDeltaData2_Call
func (*MockSegment_LoadDeltaData2_Call) Run ¶
func (_c *MockSegment_LoadDeltaData2_Call) Run(run func(ctx context.Context, schema *schemapb.CollectionSchema)) *MockSegment_LoadDeltaData2_Call
func (*MockSegment_LoadDeltaData2_Call) RunAndReturn ¶
func (_c *MockSegment_LoadDeltaData2_Call) RunAndReturn(run func(context.Context, *schemapb.CollectionSchema) error) *MockSegment_LoadDeltaData2_Call
type MockSegment_LoadDeltaData_Call ¶
MockSegment_LoadDeltaData_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadDeltaData'
func (*MockSegment_LoadDeltaData_Call) Return ¶
func (_c *MockSegment_LoadDeltaData_Call) Return(_a0 error) *MockSegment_LoadDeltaData_Call
func (*MockSegment_LoadDeltaData_Call) Run ¶
func (_c *MockSegment_LoadDeltaData_Call) Run(run func(ctx context.Context, deltaData *storage.DeleteData)) *MockSegment_LoadDeltaData_Call
func (*MockSegment_LoadDeltaData_Call) RunAndReturn ¶
func (_c *MockSegment_LoadDeltaData_Call) RunAndReturn(run func(context.Context, *storage.DeleteData) error) *MockSegment_LoadDeltaData_Call
type MockSegment_LoadInfo_Call ¶
MockSegment_LoadInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LoadInfo'
func (*MockSegment_LoadInfo_Call) Return ¶
func (_c *MockSegment_LoadInfo_Call) Return(_a0 *querypb.SegmentLoadInfo) *MockSegment_LoadInfo_Call
func (*MockSegment_LoadInfo_Call) Run ¶
func (_c *MockSegment_LoadInfo_Call) Run(run func()) *MockSegment_LoadInfo_Call
func (*MockSegment_LoadInfo_Call) RunAndReturn ¶
func (_c *MockSegment_LoadInfo_Call) RunAndReturn(run func() *querypb.SegmentLoadInfo) *MockSegment_LoadInfo_Call
type MockSegment_MayPkExist_Call ¶
MockSegment_MayPkExist_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'MayPkExist'
func (*MockSegment_MayPkExist_Call) Return ¶
func (_c *MockSegment_MayPkExist_Call) Return(_a0 bool) *MockSegment_MayPkExist_Call
func (*MockSegment_MayPkExist_Call) Run ¶
func (_c *MockSegment_MayPkExist_Call) Run(run func(lc *storage.LocationsCache)) *MockSegment_MayPkExist_Call
func (*MockSegment_MayPkExist_Call) RunAndReturn ¶
func (_c *MockSegment_MayPkExist_Call) RunAndReturn(run func(*storage.LocationsCache) bool) *MockSegment_MayPkExist_Call
type MockSegment_MemSize_Call ¶
MockSegment_MemSize_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'MemSize'
func (*MockSegment_MemSize_Call) Return ¶
func (_c *MockSegment_MemSize_Call) Return(_a0 int64) *MockSegment_MemSize_Call
func (*MockSegment_MemSize_Call) Run ¶
func (_c *MockSegment_MemSize_Call) Run(run func()) *MockSegment_MemSize_Call
func (*MockSegment_MemSize_Call) RunAndReturn ¶
func (_c *MockSegment_MemSize_Call) RunAndReturn(run func() int64) *MockSegment_MemSize_Call
type MockSegment_NeedUpdatedVersion_Call ¶
MockSegment_NeedUpdatedVersion_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'NeedUpdatedVersion'
func (*MockSegment_NeedUpdatedVersion_Call) Return ¶
func (_c *MockSegment_NeedUpdatedVersion_Call) Return(_a0 int64) *MockSegment_NeedUpdatedVersion_Call
func (*MockSegment_NeedUpdatedVersion_Call) Run ¶
func (_c *MockSegment_NeedUpdatedVersion_Call) Run(run func()) *MockSegment_NeedUpdatedVersion_Call
func (*MockSegment_NeedUpdatedVersion_Call) RunAndReturn ¶
func (_c *MockSegment_NeedUpdatedVersion_Call) RunAndReturn(run func() int64) *MockSegment_NeedUpdatedVersion_Call
type MockSegment_Partition_Call ¶
MockSegment_Partition_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Partition'
func (*MockSegment_Partition_Call) Return ¶
func (_c *MockSegment_Partition_Call) Return(_a0 int64) *MockSegment_Partition_Call
func (*MockSegment_Partition_Call) Run ¶
func (_c *MockSegment_Partition_Call) Run(run func()) *MockSegment_Partition_Call
func (*MockSegment_Partition_Call) RunAndReturn ¶
func (_c *MockSegment_Partition_Call) RunAndReturn(run func() int64) *MockSegment_Partition_Call
type MockSegment_PinIfNotReleased_Call ¶
MockSegment_PinIfNotReleased_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PinIfNotReleased'
func (*MockSegment_PinIfNotReleased_Call) Return ¶
func (_c *MockSegment_PinIfNotReleased_Call) Return(_a0 error) *MockSegment_PinIfNotReleased_Call
func (*MockSegment_PinIfNotReleased_Call) Run ¶
func (_c *MockSegment_PinIfNotReleased_Call) Run(run func()) *MockSegment_PinIfNotReleased_Call
func (*MockSegment_PinIfNotReleased_Call) RunAndReturn ¶
func (_c *MockSegment_PinIfNotReleased_Call) RunAndReturn(run func() error) *MockSegment_PinIfNotReleased_Call
type MockSegment_Release_Call ¶
MockSegment_Release_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Release'
func (*MockSegment_Release_Call) Return ¶
func (_c *MockSegment_Release_Call) Return() *MockSegment_Release_Call
func (*MockSegment_Release_Call) Run ¶
func (_c *MockSegment_Release_Call) Run(run func(ctx context.Context, opts ...releaseOption)) *MockSegment_Release_Call
func (*MockSegment_Release_Call) RunAndReturn ¶
func (_c *MockSegment_Release_Call) RunAndReturn(run func(context.Context, ...releaseOption)) *MockSegment_Release_Call
type MockSegment_RemoveUnusedFieldFiles_Call ¶
MockSegment_RemoveUnusedFieldFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoveUnusedFieldFiles'
func (*MockSegment_RemoveUnusedFieldFiles_Call) Return ¶
func (_c *MockSegment_RemoveUnusedFieldFiles_Call) Return(_a0 error) *MockSegment_RemoveUnusedFieldFiles_Call
func (*MockSegment_RemoveUnusedFieldFiles_Call) Run ¶
func (_c *MockSegment_RemoveUnusedFieldFiles_Call) Run(run func()) *MockSegment_RemoveUnusedFieldFiles_Call
func (*MockSegment_RemoveUnusedFieldFiles_Call) RunAndReturn ¶
func (_c *MockSegment_RemoveUnusedFieldFiles_Call) RunAndReturn(run func() error) *MockSegment_RemoveUnusedFieldFiles_Call
type MockSegment_ResetIndexesLazyLoad_Call ¶
MockSegment_ResetIndexesLazyLoad_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResetIndexesLazyLoad'
func (*MockSegment_ResetIndexesLazyLoad_Call) Return ¶
func (_c *MockSegment_ResetIndexesLazyLoad_Call) Return() *MockSegment_ResetIndexesLazyLoad_Call
func (*MockSegment_ResetIndexesLazyLoad_Call) Run ¶
func (_c *MockSegment_ResetIndexesLazyLoad_Call) Run(run func(lazyState bool)) *MockSegment_ResetIndexesLazyLoad_Call
func (*MockSegment_ResetIndexesLazyLoad_Call) RunAndReturn ¶
func (_c *MockSegment_ResetIndexesLazyLoad_Call) RunAndReturn(run func(bool)) *MockSegment_ResetIndexesLazyLoad_Call
type MockSegment_ResourceGroup_Call ¶
MockSegment_ResourceGroup_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResourceGroup'
func (*MockSegment_ResourceGroup_Call) Return ¶
func (_c *MockSegment_ResourceGroup_Call) Return(_a0 string) *MockSegment_ResourceGroup_Call
func (*MockSegment_ResourceGroup_Call) Run ¶
func (_c *MockSegment_ResourceGroup_Call) Run(run func()) *MockSegment_ResourceGroup_Call
func (*MockSegment_ResourceGroup_Call) RunAndReturn ¶
func (_c *MockSegment_ResourceGroup_Call) RunAndReturn(run func() string) *MockSegment_ResourceGroup_Call
type MockSegment_ResourceUsageEstimate_Call ¶
MockSegment_ResourceUsageEstimate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResourceUsageEstimate'
func (*MockSegment_ResourceUsageEstimate_Call) Return ¶
func (_c *MockSegment_ResourceUsageEstimate_Call) Return(_a0 ResourceUsage) *MockSegment_ResourceUsageEstimate_Call
func (*MockSegment_ResourceUsageEstimate_Call) Run ¶
func (_c *MockSegment_ResourceUsageEstimate_Call) Run(run func()) *MockSegment_ResourceUsageEstimate_Call
func (*MockSegment_ResourceUsageEstimate_Call) RunAndReturn ¶
func (_c *MockSegment_ResourceUsageEstimate_Call) RunAndReturn(run func() ResourceUsage) *MockSegment_ResourceUsageEstimate_Call
type MockSegment_RetrieveByOffsets_Call ¶
MockSegment_RetrieveByOffsets_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RetrieveByOffsets'
func (*MockSegment_RetrieveByOffsets_Call) Return ¶
func (_c *MockSegment_RetrieveByOffsets_Call) Return(_a0 *segcorepb.RetrieveResults, _a1 error) *MockSegment_RetrieveByOffsets_Call
func (*MockSegment_RetrieveByOffsets_Call) Run ¶
func (_c *MockSegment_RetrieveByOffsets_Call) Run(run func(ctx context.Context, plan *RetrievePlan, offsets []int64)) *MockSegment_RetrieveByOffsets_Call
func (*MockSegment_RetrieveByOffsets_Call) RunAndReturn ¶
func (_c *MockSegment_RetrieveByOffsets_Call) RunAndReturn(run func(context.Context, *RetrievePlan, []int64) (*segcorepb.RetrieveResults, error)) *MockSegment_RetrieveByOffsets_Call
type MockSegment_Retrieve_Call ¶
MockSegment_Retrieve_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Retrieve'
func (*MockSegment_Retrieve_Call) Return ¶
func (_c *MockSegment_Retrieve_Call) Return(_a0 *segcorepb.RetrieveResults, _a1 error) *MockSegment_Retrieve_Call
func (*MockSegment_Retrieve_Call) Run ¶
func (_c *MockSegment_Retrieve_Call) Run(run func(ctx context.Context, plan *RetrievePlan)) *MockSegment_Retrieve_Call
func (*MockSegment_Retrieve_Call) RunAndReturn ¶
func (_c *MockSegment_Retrieve_Call) RunAndReturn(run func(context.Context, *RetrievePlan) (*segcorepb.RetrieveResults, error)) *MockSegment_Retrieve_Call
type MockSegment_RowNum_Call ¶
MockSegment_RowNum_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RowNum'
func (*MockSegment_RowNum_Call) Return ¶
func (_c *MockSegment_RowNum_Call) Return(_a0 int64) *MockSegment_RowNum_Call
func (*MockSegment_RowNum_Call) Run ¶
func (_c *MockSegment_RowNum_Call) Run(run func()) *MockSegment_RowNum_Call
func (*MockSegment_RowNum_Call) RunAndReturn ¶
func (_c *MockSegment_RowNum_Call) RunAndReturn(run func() int64) *MockSegment_RowNum_Call
type MockSegment_Search_Call ¶
MockSegment_Search_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Search'
func (*MockSegment_Search_Call) Return ¶
func (_c *MockSegment_Search_Call) Return(_a0 *SearchResult, _a1 error) *MockSegment_Search_Call
func (*MockSegment_Search_Call) Run ¶
func (_c *MockSegment_Search_Call) Run(run func(ctx context.Context, searchReq *SearchRequest)) *MockSegment_Search_Call
func (*MockSegment_Search_Call) RunAndReturn ¶
func (_c *MockSegment_Search_Call) RunAndReturn(run func(context.Context, *SearchRequest) (*SearchResult, error)) *MockSegment_Search_Call
type MockSegment_Shard_Call ¶
MockSegment_Shard_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Shard'
func (*MockSegment_Shard_Call) Return ¶
func (_c *MockSegment_Shard_Call) Return(_a0 metautil.Channel) *MockSegment_Shard_Call
func (*MockSegment_Shard_Call) Run ¶
func (_c *MockSegment_Shard_Call) Run(run func()) *MockSegment_Shard_Call
func (*MockSegment_Shard_Call) RunAndReturn ¶
func (_c *MockSegment_Shard_Call) RunAndReturn(run func() metautil.Channel) *MockSegment_Shard_Call
type MockSegment_StartPosition_Call ¶
MockSegment_StartPosition_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'StartPosition'
func (*MockSegment_StartPosition_Call) Return ¶
func (_c *MockSegment_StartPosition_Call) Return(_a0 *msgpb.MsgPosition) *MockSegment_StartPosition_Call
func (*MockSegment_StartPosition_Call) Run ¶
func (_c *MockSegment_StartPosition_Call) Run(run func()) *MockSegment_StartPosition_Call
func (*MockSegment_StartPosition_Call) RunAndReturn ¶
func (_c *MockSegment_StartPosition_Call) RunAndReturn(run func() *msgpb.MsgPosition) *MockSegment_StartPosition_Call
type MockSegment_Type_Call ¶
MockSegment_Type_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Type'
func (*MockSegment_Type_Call) Return ¶
func (_c *MockSegment_Type_Call) Return(_a0 commonpb.SegmentState) *MockSegment_Type_Call
func (*MockSegment_Type_Call) Run ¶
func (_c *MockSegment_Type_Call) Run(run func()) *MockSegment_Type_Call
func (*MockSegment_Type_Call) RunAndReturn ¶
func (_c *MockSegment_Type_Call) RunAndReturn(run func() commonpb.SegmentState) *MockSegment_Type_Call
type MockSegment_Unpin_Call ¶
MockSegment_Unpin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Unpin'
func (*MockSegment_Unpin_Call) Return ¶
func (_c *MockSegment_Unpin_Call) Return() *MockSegment_Unpin_Call
func (*MockSegment_Unpin_Call) Run ¶
func (_c *MockSegment_Unpin_Call) Run(run func()) *MockSegment_Unpin_Call
func (*MockSegment_Unpin_Call) RunAndReturn ¶
func (_c *MockSegment_Unpin_Call) RunAndReturn(run func()) *MockSegment_Unpin_Call
type MockSegment_UpdateBloomFilter_Call ¶
MockSegment_UpdateBloomFilter_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateBloomFilter'
func (*MockSegment_UpdateBloomFilter_Call) Return ¶
func (_c *MockSegment_UpdateBloomFilter_Call) Return() *MockSegment_UpdateBloomFilter_Call
func (*MockSegment_UpdateBloomFilter_Call) Run ¶
func (_c *MockSegment_UpdateBloomFilter_Call) Run(run func(pks []storage.PrimaryKey)) *MockSegment_UpdateBloomFilter_Call
func (*MockSegment_UpdateBloomFilter_Call) RunAndReturn ¶
func (_c *MockSegment_UpdateBloomFilter_Call) RunAndReturn(run func([]storage.PrimaryKey)) *MockSegment_UpdateBloomFilter_Call
type MockSegment_Version_Call ¶
MockSegment_Version_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Version'
func (*MockSegment_Version_Call) Return ¶
func (_c *MockSegment_Version_Call) Return(_a0 int64) *MockSegment_Version_Call
func (*MockSegment_Version_Call) Run ¶
func (_c *MockSegment_Version_Call) Run(run func()) *MockSegment_Version_Call
func (*MockSegment_Version_Call) RunAndReturn ¶
func (_c *MockSegment_Version_Call) RunAndReturn(run func() int64) *MockSegment_Version_Call
type ReleaseScope ¶
type ReleaseScope int
const ( ReleaseScopeAll ReleaseScope = iota ReleaseScopeData )
type ResourceUsage ¶
ResourceUsage is used to estimate the resource usage of a sealed segment.
type RetrievePlan ¶
type RetrievePlan struct { Timestamp Timestamp // contains filtered or unexported fields }
RetrievePlan is a wrapper of the underlying C-structure C.CRetrievePlan
func NewRetrievePlan ¶
func NewRetrievePlan(ctx context.Context, col *Collection, expr []byte, timestamp Timestamp, msgID UniqueID) (*RetrievePlan, error)
func (*RetrievePlan) Delete ¶
func (plan *RetrievePlan) Delete()
func (*RetrievePlan) ShouldIgnoreNonPk ¶
func (plan *RetrievePlan) ShouldIgnoreNonPk() bool
type RetrieveResult ¶
type RetrieveResult struct {
// contains filtered or unexported fields
}
RetrieveResult contains a pointer to the retrieve result in C++ memory
type RetrieveSegmentResult ¶
type RetrieveSegmentResult struct { Result *segcorepb.RetrieveResults Segment Segment }
type SearchPlan ¶
type SearchPlan struct {
// contains filtered or unexported fields
}
SearchPlan is a wrapper of the underlying C-structure C.CSearchPlan
func (*SearchPlan) GetMetricType ¶
func (plan *SearchPlan) GetMetricType() string
type SearchRequest ¶
type SearchRequest struct {
// contains filtered or unexported fields
}
func NewSearchRequest ¶
func NewSearchRequest(ctx context.Context, collection *Collection, req *querypb.SearchRequest, placeholderGrp []byte) (*SearchRequest, error)
func (*SearchRequest) Delete ¶
func (req *SearchRequest) Delete()
func (*SearchRequest) Plan ¶
func (req *SearchRequest) Plan() *SearchPlan
type SearchResult ¶
type SearchResult struct {
// contains filtered or unexported fields
}
SearchResult contains a pointer to the search result in C++ memory
type SearchResultDataBlobs ¶
type SearchResultDataBlobs = C.CSearchResultDataBlobs
SearchResultDataBlobs is the CSearchResultsDataBlobs in C++
func GetStreamReduceResult ¶
func GetStreamReduceResult(ctx context.Context, streamReducer StreamSearchReducer) (SearchResultDataBlobs, error)
func ReduceSearchResultsAndFillData ¶
func ReduceSearchResultsAndFillData(ctx context.Context, plan *SearchPlan, searchResults []*SearchResult, numSegments int64, sliceNQs []int64, sliceTopKs []int64, ) (SearchResultDataBlobs, error)
type Segment ¶
type Segment interface { // Properties ID() int64 DatabaseName() string ResourceGroup() string Collection() int64 Partition() int64 Shard() metautil.Channel Version() int64 CASVersion(int64, int64) bool StartPosition() *msgpb.MsgPosition Type() SegmentType Level() datapb.SegmentLevel LoadInfo() *querypb.SegmentLoadInfo // PinIfNotReleased the segment to prevent it from being released PinIfNotReleased() error // Unpin the segment to allow it to be released Unpin() // Stats related // InsertCount returns the number of inserted rows, not effected by deletion InsertCount() int64 // RowNum returns the number of rows, it's slow, so DO NOT call it in a loop RowNum() int64 MemSize() int64 // ResourceUsageEstimate returns the estimated resource usage of the segment ResourceUsageEstimate() ResourceUsage // Index related GetIndex(fieldID int64) *IndexedFieldInfo ExistIndex(fieldID int64) bool Indexes() []*IndexedFieldInfo HasRawData(fieldID int64) bool // Modification related Insert(ctx context.Context, rowIDs []int64, timestamps []typeutil.Timestamp, record *segcorepb.InsertRecord) error Delete(ctx context.Context, primaryKeys []storage.PrimaryKey, timestamps []typeutil.Timestamp) error LoadDeltaData(ctx context.Context, deltaData *storage.DeleteData) error LastDeltaTimestamp() uint64 Release(ctx context.Context, opts ...releaseOption) // Bloom filter related UpdateBloomFilter(pks []storage.PrimaryKey) MayPkExist(lc *storage.LocationsCache) bool BatchPkExist(lc *storage.BatchLocationsCache) []bool // Read operations Search(ctx context.Context, searchReq *SearchRequest) (*SearchResult, error) Retrieve(ctx context.Context, plan *RetrievePlan) (*segcorepb.RetrieveResults, error) RetrieveByOffsets(ctx context.Context, plan *RetrievePlan, offsets []int64) (*segcorepb.RetrieveResults, error) IsLazyLoad() bool ResetIndexesLazyLoad(lazyState bool) // lazy load related NeedUpdatedVersion() int64 RemoveUnusedFieldFiles() error }
Segment is the interface of a segment implementation. Some methods can not apply to all segment types,such as LoadInfo, ResourceUsageEstimate. Add more interface to represent different segment types is a better implementation.
func NewL0Segment ¶
func NewL0Segment(collection *Collection, segmentType SegmentType, version int64, loadInfo *querypb.SegmentLoadInfo, ) (Segment, error)
func NewSegment ¶
func NewSegment(ctx context.Context, collection *Collection, segmentType SegmentType, version int64, loadInfo *querypb.SegmentLoadInfo, ) (Segment, error)
func RetrieveStream ¶
func RetrieveStream(ctx context.Context, manager *Manager, plan *RetrievePlan, req *querypb.QueryRequest, srv streamrpc.QueryStreamServer) ([]Segment, error)
retrieveStreaming will retrieve all the validate target segments and return by stream
type SegmentAction ¶
func IncreaseVersion ¶
func IncreaseVersion(version int64) SegmentAction
type SegmentFilter ¶
type SegmentFilter interface { Filter(segment Segment) bool SegmentType() (SegmentType, bool) SegmentIDs() ([]int64, bool) }
SegmentFilter is the interface for segment selection criteria.
func WithChannel ¶
func WithChannel(channel string) SegmentFilter
func WithID ¶
func WithID(id int64) SegmentFilter
func WithLevel ¶
func WithLevel(level datapb.SegmentLevel) SegmentFilter
func WithPartition ¶
func WithPartition(partitionID typeutil.UniqueID) SegmentFilter
func WithSkipEmpty ¶
func WithSkipEmpty() SegmentFilter
func WithType ¶
func WithType(typ SegmentType) SegmentFilter
type SegmentFilterFunc ¶
SegmentFilterFunc is a type wrapper for `func(Segment) bool` to SegmentFilter.
func (SegmentFilterFunc) Filter ¶
func (f SegmentFilterFunc) Filter(segment Segment) bool
func (SegmentFilterFunc) SegmentIDs ¶
func (s SegmentFilterFunc) SegmentIDs() ([]int64, bool)
func (SegmentFilterFunc) SegmentType ¶
func (f SegmentFilterFunc) SegmentType() (SegmentType, bool)
type SegmentIDFilter ¶
type SegmentIDFilter int64
SegmentIDFilter is the specific segment filter for SegmentID only.
func (SegmentIDFilter) Filter ¶
func (f SegmentIDFilter) Filter(segment Segment) bool
func (SegmentIDFilter) SegmentIDs ¶
func (f SegmentIDFilter) SegmentIDs() ([]int64, bool)
func (SegmentIDFilter) SegmentType ¶
func (f SegmentIDFilter) SegmentType() (SegmentType, bool)
type SegmentManager ¶
type SegmentManager interface { // Put puts the given segments in, // and increases the ref count of the corresponding collection, // dup segments will not increase the ref count Put(ctx context.Context, segmentType SegmentType, segments ...Segment) UpdateBy(action SegmentAction, filters ...SegmentFilter) int Get(segmentID typeutil.UniqueID) Segment GetWithType(segmentID typeutil.UniqueID, typ SegmentType) Segment GetBy(filters ...SegmentFilter) []Segment // Get segments and acquire the read locks GetAndPinBy(filters ...SegmentFilter) ([]Segment, error) GetAndPin(segments []int64, filters ...SegmentFilter) ([]Segment, error) Unpin(segments []Segment) GetSealed(segmentID typeutil.UniqueID) Segment GetGrowing(segmentID typeutil.UniqueID) Segment Empty() bool // Remove removes the given segment, // and decreases the ref count of the corresponding collection, // will not decrease the ref count if the given segment not exists Remove(ctx context.Context, segmentID typeutil.UniqueID, scope querypb.DataScope) (int, int) RemoveBy(ctx context.Context, filters ...SegmentFilter) (int, int) Clear(ctx context.Context) // Deprecated: quick fix critical issue: #30857 // TODO: All Segment assigned to querynode should be managed by SegmentManager, including loading or releasing to perform a transaction. Exist(segmentID typeutil.UniqueID, typ SegmentType) bool }
type SegmentStats ¶
SegmentStats struct for segment statistics.
type SegmentType ¶
type SegmentType = commonpb.SegmentState
type SegmentTypeFilter ¶
type SegmentTypeFilter SegmentType
func (SegmentTypeFilter) Filter ¶
func (f SegmentTypeFilter) Filter(segment Segment) bool
func (SegmentTypeFilter) SegmentIDs ¶
func (f SegmentTypeFilter) SegmentIDs() ([]int64, bool)
func (SegmentTypeFilter) SegmentType ¶
func (f SegmentTypeFilter) SegmentType() (SegmentType, bool)
type StreamSearchReducer ¶
type StreamSearchReducer = C.CSearchStreamReducer
SearchResultDataBlobs is the CSearchResultsDataBlobs in C++
func NewStreamReducer ¶
func NewStreamReducer(ctx context.Context, plan *SearchPlan, sliceNQs []int64, sliceTopKs []int64, ) (StreamSearchReducer, error)
type TimestampedRetrieveResult ¶
type TimestampedRetrieveResult[T interface { typeutil.ResultWithID GetFieldsData() []*schemapb.FieldData }] struct { Result T Timestamps []int64 }
func NewTimestampedRetrieveResult ¶
func NewTimestampedRetrieveResult[T interface { typeutil.ResultWithID GetFieldsData() []*schemapb.FieldData }](result T) (*TimestampedRetrieveResult[T], error)
func (*TimestampedRetrieveResult[T]) GetHasMoreResult ¶
func (r *TimestampedRetrieveResult[T]) GetHasMoreResult() bool
func (*TimestampedRetrieveResult[T]) GetIds ¶
func (r *TimestampedRetrieveResult[T]) GetIds() *schemapb.IDs
func (*TimestampedRetrieveResult[T]) GetTimestamps ¶
func (r *TimestampedRetrieveResult[T]) GetTimestamps() []int64
Source Files ¶
- cgo_util.go
- collection.go
- count_reducer.go
- default_limit_reducer.go
- index_attr_cache.go
- load_field_data_info.go
- load_index_info.go
- manager.go
- mock_collection_manager.go
- mock_data.go
- mock_loader.go
- mock_segment.go
- mock_segment_manager.go
- plan.go
- pool.go
- reduce.go
- reducer.go
- result.go
- result_sorter.go
- retrieve.go
- search.go
- segment.go
- segment_do.go
- segment_interface.go
- segment_l0.go
- segment_loader.go
- statistics.go
- trace.go
- utils.go
- validate.go