Documentation ¶
Index ¶
- func NewCoordinatorBroker(rootCoord types.RootCoordClient) *coordinatorBroker
- type Broker
- type MockBroker
- func (_m *MockBroker) DescribeCollectionInternal(ctx context.Context, collectionID int64) (*milvuspb.DescribeCollectionResponse, error)
- func (_m *MockBroker) EXPECT() *MockBroker_Expecter
- func (_m *MockBroker) HasCollection(ctx context.Context, collectionID int64) (bool, error)
- func (_m *MockBroker) ListDatabases(ctx context.Context) (*milvuspb.ListDatabasesResponse, error)
- func (_m *MockBroker) ShowCollections(ctx context.Context, dbName string) (*milvuspb.ShowCollectionsResponse, error)
- func (_m *MockBroker) ShowPartitionsInternal(ctx context.Context, collectionID int64) ([]int64, error)
- type MockBroker_DescribeCollectionInternal_Call
- func (_c *MockBroker_DescribeCollectionInternal_Call) Return(_a0 *milvuspb.DescribeCollectionResponse, _a1 error) *MockBroker_DescribeCollectionInternal_Call
- func (_c *MockBroker_DescribeCollectionInternal_Call) Run(run func(ctx context.Context, collectionID int64)) *MockBroker_DescribeCollectionInternal_Call
- func (_c *MockBroker_DescribeCollectionInternal_Call) RunAndReturn(run func(context.Context, int64) (*milvuspb.DescribeCollectionResponse, error)) *MockBroker_DescribeCollectionInternal_Call
- type MockBroker_Expecter
- func (_e *MockBroker_Expecter) DescribeCollectionInternal(ctx interface{}, collectionID interface{}) *MockBroker_DescribeCollectionInternal_Call
- func (_e *MockBroker_Expecter) HasCollection(ctx interface{}, collectionID interface{}) *MockBroker_HasCollection_Call
- func (_e *MockBroker_Expecter) ListDatabases(ctx interface{}) *MockBroker_ListDatabases_Call
- func (_e *MockBroker_Expecter) ShowCollections(ctx interface{}, dbName interface{}) *MockBroker_ShowCollections_Call
- func (_e *MockBroker_Expecter) ShowPartitionsInternal(ctx interface{}, collectionID interface{}) *MockBroker_ShowPartitionsInternal_Call
- type MockBroker_HasCollection_Call
- func (_c *MockBroker_HasCollection_Call) Return(_a0 bool, _a1 error) *MockBroker_HasCollection_Call
- func (_c *MockBroker_HasCollection_Call) Run(run func(ctx context.Context, collectionID int64)) *MockBroker_HasCollection_Call
- func (_c *MockBroker_HasCollection_Call) RunAndReturn(run func(context.Context, int64) (bool, error)) *MockBroker_HasCollection_Call
- type MockBroker_ListDatabases_Call
- func (_c *MockBroker_ListDatabases_Call) Return(_a0 *milvuspb.ListDatabasesResponse, _a1 error) *MockBroker_ListDatabases_Call
- func (_c *MockBroker_ListDatabases_Call) Run(run func(ctx context.Context)) *MockBroker_ListDatabases_Call
- func (_c *MockBroker_ListDatabases_Call) RunAndReturn(run func(context.Context) (*milvuspb.ListDatabasesResponse, error)) *MockBroker_ListDatabases_Call
- type MockBroker_ShowCollections_Call
- func (_c *MockBroker_ShowCollections_Call) Return(_a0 *milvuspb.ShowCollectionsResponse, _a1 error) *MockBroker_ShowCollections_Call
- func (_c *MockBroker_ShowCollections_Call) Run(run func(ctx context.Context, dbName string)) *MockBroker_ShowCollections_Call
- func (_c *MockBroker_ShowCollections_Call) RunAndReturn(run func(context.Context, string) (*milvuspb.ShowCollectionsResponse, error)) *MockBroker_ShowCollections_Call
- type MockBroker_ShowPartitionsInternal_Call
- func (_c *MockBroker_ShowPartitionsInternal_Call) Return(_a0 []int64, _a1 error) *MockBroker_ShowPartitionsInternal_Call
- func (_c *MockBroker_ShowPartitionsInternal_Call) Run(run func(ctx context.Context, collectionID int64)) *MockBroker_ShowPartitionsInternal_Call
- func (_c *MockBroker_ShowPartitionsInternal_Call) RunAndReturn(run func(context.Context, int64) ([]int64, error)) *MockBroker_ShowPartitionsInternal_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCoordinatorBroker ¶
func NewCoordinatorBroker(rootCoord types.RootCoordClient) *coordinatorBroker
Types ¶
type Broker ¶
type Broker interface { DescribeCollectionInternal(ctx context.Context, collectionID int64) (*milvuspb.DescribeCollectionResponse, error) ShowPartitionsInternal(ctx context.Context, collectionID int64) ([]int64, error) ShowCollections(ctx context.Context, dbName string) (*milvuspb.ShowCollectionsResponse, error) ListDatabases(ctx context.Context) (*milvuspb.ListDatabasesResponse, error) HasCollection(ctx context.Context, collectionID int64) (bool, error) }
type MockBroker ¶
MockBroker is an autogenerated mock type for the Broker type
func NewMockBroker ¶
func NewMockBroker(t interface { mock.TestingT Cleanup(func()) }) *MockBroker
NewMockBroker creates a new instance of MockBroker. 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 (*MockBroker) DescribeCollectionInternal ¶
func (_m *MockBroker) DescribeCollectionInternal(ctx context.Context, collectionID int64) (*milvuspb.DescribeCollectionResponse, error)
DescribeCollectionInternal provides a mock function with given fields: ctx, collectionID
func (*MockBroker) EXPECT ¶
func (_m *MockBroker) EXPECT() *MockBroker_Expecter
func (*MockBroker) HasCollection ¶
HasCollection provides a mock function with given fields: ctx, collectionID
func (*MockBroker) ListDatabases ¶
func (_m *MockBroker) ListDatabases(ctx context.Context) (*milvuspb.ListDatabasesResponse, error)
ListDatabases provides a mock function with given fields: ctx
func (*MockBroker) ShowCollections ¶
func (_m *MockBroker) ShowCollections(ctx context.Context, dbName string) (*milvuspb.ShowCollectionsResponse, error)
ShowCollections provides a mock function with given fields: ctx, dbName
func (*MockBroker) ShowPartitionsInternal ¶
func (_m *MockBroker) ShowPartitionsInternal(ctx context.Context, collectionID int64) ([]int64, error)
ShowPartitionsInternal provides a mock function with given fields: ctx, collectionID
type MockBroker_DescribeCollectionInternal_Call ¶
MockBroker_DescribeCollectionInternal_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DescribeCollectionInternal'
func (*MockBroker_DescribeCollectionInternal_Call) Return ¶
func (_c *MockBroker_DescribeCollectionInternal_Call) Return(_a0 *milvuspb.DescribeCollectionResponse, _a1 error) *MockBroker_DescribeCollectionInternal_Call
func (*MockBroker_DescribeCollectionInternal_Call) Run ¶
func (_c *MockBroker_DescribeCollectionInternal_Call) Run(run func(ctx context.Context, collectionID int64)) *MockBroker_DescribeCollectionInternal_Call
func (*MockBroker_DescribeCollectionInternal_Call) RunAndReturn ¶
func (_c *MockBroker_DescribeCollectionInternal_Call) RunAndReturn(run func(context.Context, int64) (*milvuspb.DescribeCollectionResponse, error)) *MockBroker_DescribeCollectionInternal_Call
type MockBroker_Expecter ¶
type MockBroker_Expecter struct {
// contains filtered or unexported fields
}
func (*MockBroker_Expecter) DescribeCollectionInternal ¶
func (_e *MockBroker_Expecter) DescribeCollectionInternal(ctx interface{}, collectionID interface{}) *MockBroker_DescribeCollectionInternal_Call
DescribeCollectionInternal is a helper method to define mock.On call
- ctx context.Context
- collectionID int64
func (*MockBroker_Expecter) HasCollection ¶
func (_e *MockBroker_Expecter) HasCollection(ctx interface{}, collectionID interface{}) *MockBroker_HasCollection_Call
HasCollection is a helper method to define mock.On call
- ctx context.Context
- collectionID int64
func (*MockBroker_Expecter) ListDatabases ¶
func (_e *MockBroker_Expecter) ListDatabases(ctx interface{}) *MockBroker_ListDatabases_Call
ListDatabases is a helper method to define mock.On call
- ctx context.Context
func (*MockBroker_Expecter) ShowCollections ¶
func (_e *MockBroker_Expecter) ShowCollections(ctx interface{}, dbName interface{}) *MockBroker_ShowCollections_Call
ShowCollections is a helper method to define mock.On call
- ctx context.Context
- dbName string
func (*MockBroker_Expecter) ShowPartitionsInternal ¶
func (_e *MockBroker_Expecter) ShowPartitionsInternal(ctx interface{}, collectionID interface{}) *MockBroker_ShowPartitionsInternal_Call
ShowPartitionsInternal is a helper method to define mock.On call
- ctx context.Context
- collectionID int64
type MockBroker_HasCollection_Call ¶
MockBroker_HasCollection_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HasCollection'
func (*MockBroker_HasCollection_Call) Return ¶
func (_c *MockBroker_HasCollection_Call) Return(_a0 bool, _a1 error) *MockBroker_HasCollection_Call
func (*MockBroker_HasCollection_Call) Run ¶
func (_c *MockBroker_HasCollection_Call) Run(run func(ctx context.Context, collectionID int64)) *MockBroker_HasCollection_Call
func (*MockBroker_HasCollection_Call) RunAndReturn ¶
func (_c *MockBroker_HasCollection_Call) RunAndReturn(run func(context.Context, int64) (bool, error)) *MockBroker_HasCollection_Call
type MockBroker_ListDatabases_Call ¶
MockBroker_ListDatabases_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListDatabases'
func (*MockBroker_ListDatabases_Call) Return ¶
func (_c *MockBroker_ListDatabases_Call) Return(_a0 *milvuspb.ListDatabasesResponse, _a1 error) *MockBroker_ListDatabases_Call
func (*MockBroker_ListDatabases_Call) Run ¶
func (_c *MockBroker_ListDatabases_Call) Run(run func(ctx context.Context)) *MockBroker_ListDatabases_Call
func (*MockBroker_ListDatabases_Call) RunAndReturn ¶
func (_c *MockBroker_ListDatabases_Call) RunAndReturn(run func(context.Context) (*milvuspb.ListDatabasesResponse, error)) *MockBroker_ListDatabases_Call
type MockBroker_ShowCollections_Call ¶
MockBroker_ShowCollections_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ShowCollections'
func (*MockBroker_ShowCollections_Call) Return ¶
func (_c *MockBroker_ShowCollections_Call) Return(_a0 *milvuspb.ShowCollectionsResponse, _a1 error) *MockBroker_ShowCollections_Call
func (*MockBroker_ShowCollections_Call) Run ¶
func (_c *MockBroker_ShowCollections_Call) Run(run func(ctx context.Context, dbName string)) *MockBroker_ShowCollections_Call
func (*MockBroker_ShowCollections_Call) RunAndReturn ¶
func (_c *MockBroker_ShowCollections_Call) RunAndReturn(run func(context.Context, string) (*milvuspb.ShowCollectionsResponse, error)) *MockBroker_ShowCollections_Call
type MockBroker_ShowPartitionsInternal_Call ¶
MockBroker_ShowPartitionsInternal_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ShowPartitionsInternal'
func (*MockBroker_ShowPartitionsInternal_Call) Return ¶
func (_c *MockBroker_ShowPartitionsInternal_Call) Return(_a0 []int64, _a1 error) *MockBroker_ShowPartitionsInternal_Call
func (*MockBroker_ShowPartitionsInternal_Call) Run ¶
func (_c *MockBroker_ShowPartitionsInternal_Call) Run(run func(ctx context.Context, collectionID int64)) *MockBroker_ShowPartitionsInternal_Call
func (*MockBroker_ShowPartitionsInternal_Call) RunAndReturn ¶
func (_c *MockBroker_ShowPartitionsInternal_Call) RunAndReturn(run func(context.Context, int64) ([]int64, error)) *MockBroker_ShowPartitionsInternal_Call