mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-01 11:29:48 +08:00
7f7c71ea7d
Co-authored-by:: aoiasd <zhicheng.yue@zilliz.com> Signed-off-by: jaime <yun.zhang@zilliz.com>
3170 lines
121 KiB
Go
3170 lines
121 KiB
Go
// Code generated by mockery v2.32.4. DO NOT EDIT.
|
|
|
|
package mocks
|
|
|
|
import (
|
|
context "context"
|
|
|
|
commonpb "github.com/milvus-io/milvus-proto/go-api/v2/commonpb"
|
|
|
|
datapb "github.com/milvus-io/milvus/internal/proto/datapb"
|
|
|
|
grpc "google.golang.org/grpc"
|
|
|
|
indexpb "github.com/milvus-io/milvus/internal/proto/indexpb"
|
|
|
|
internalpb "github.com/milvus-io/milvus/internal/proto/internalpb"
|
|
|
|
milvuspb "github.com/milvus-io/milvus-proto/go-api/v2/milvuspb"
|
|
|
|
mock "github.com/stretchr/testify/mock"
|
|
)
|
|
|
|
// MockDataCoordClient is an autogenerated mock type for the DataCoordClient type
|
|
type MockDataCoordClient struct {
|
|
mock.Mock
|
|
}
|
|
|
|
type MockDataCoordClient_Expecter struct {
|
|
mock *mock.Mock
|
|
}
|
|
|
|
func (_m *MockDataCoordClient) EXPECT() *MockDataCoordClient_Expecter {
|
|
return &MockDataCoordClient_Expecter{mock: &_m.Mock}
|
|
}
|
|
|
|
// AssignSegmentID provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) AssignSegmentID(ctx context.Context, in *datapb.AssignSegmentIDRequest, opts ...grpc.CallOption) (*datapb.AssignSegmentIDResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.AssignSegmentIDResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.AssignSegmentIDRequest, ...grpc.CallOption) (*datapb.AssignSegmentIDResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.AssignSegmentIDRequest, ...grpc.CallOption) *datapb.AssignSegmentIDResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.AssignSegmentIDResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.AssignSegmentIDRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_AssignSegmentID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AssignSegmentID'
|
|
type MockDataCoordClient_AssignSegmentID_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// AssignSegmentID is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.AssignSegmentIDRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) AssignSegmentID(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_AssignSegmentID_Call {
|
|
return &MockDataCoordClient_AssignSegmentID_Call{Call: _e.mock.On("AssignSegmentID",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_AssignSegmentID_Call) Run(run func(ctx context.Context, in *datapb.AssignSegmentIDRequest, opts ...grpc.CallOption)) *MockDataCoordClient_AssignSegmentID_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.AssignSegmentIDRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_AssignSegmentID_Call) Return(_a0 *datapb.AssignSegmentIDResponse, _a1 error) *MockDataCoordClient_AssignSegmentID_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_AssignSegmentID_Call) RunAndReturn(run func(context.Context, *datapb.AssignSegmentIDRequest, ...grpc.CallOption) (*datapb.AssignSegmentIDResponse, error)) *MockDataCoordClient_AssignSegmentID_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// BroadcastAlteredCollection provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) BroadcastAlteredCollection(ctx context.Context, in *datapb.AlterCollectionRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.AlterCollectionRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.AlterCollectionRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.AlterCollectionRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_BroadcastAlteredCollection_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'BroadcastAlteredCollection'
|
|
type MockDataCoordClient_BroadcastAlteredCollection_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// BroadcastAlteredCollection is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.AlterCollectionRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) BroadcastAlteredCollection(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_BroadcastAlteredCollection_Call {
|
|
return &MockDataCoordClient_BroadcastAlteredCollection_Call{Call: _e.mock.On("BroadcastAlteredCollection",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_BroadcastAlteredCollection_Call) Run(run func(ctx context.Context, in *datapb.AlterCollectionRequest, opts ...grpc.CallOption)) *MockDataCoordClient_BroadcastAlteredCollection_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.AlterCollectionRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_BroadcastAlteredCollection_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_BroadcastAlteredCollection_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_BroadcastAlteredCollection_Call) RunAndReturn(run func(context.Context, *datapb.AlterCollectionRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_BroadcastAlteredCollection_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// CheckHealth provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) CheckHealth(ctx context.Context, in *milvuspb.CheckHealthRequest, opts ...grpc.CallOption) (*milvuspb.CheckHealthResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.CheckHealthResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CheckHealthRequest, ...grpc.CallOption) (*milvuspb.CheckHealthResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CheckHealthRequest, ...grpc.CallOption) *milvuspb.CheckHealthResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.CheckHealthResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CheckHealthRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_CheckHealth_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckHealth'
|
|
type MockDataCoordClient_CheckHealth_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// CheckHealth is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.CheckHealthRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) CheckHealth(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_CheckHealth_Call {
|
|
return &MockDataCoordClient_CheckHealth_Call{Call: _e.mock.On("CheckHealth",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_CheckHealth_Call) Run(run func(ctx context.Context, in *milvuspb.CheckHealthRequest, opts ...grpc.CallOption)) *MockDataCoordClient_CheckHealth_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.CheckHealthRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_CheckHealth_Call) Return(_a0 *milvuspb.CheckHealthResponse, _a1 error) *MockDataCoordClient_CheckHealth_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_CheckHealth_Call) RunAndReturn(run func(context.Context, *milvuspb.CheckHealthRequest, ...grpc.CallOption) (*milvuspb.CheckHealthResponse, error)) *MockDataCoordClient_CheckHealth_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// Close provides a mock function with given fields:
|
|
func (_m *MockDataCoordClient) Close() error {
|
|
ret := _m.Called()
|
|
|
|
var r0 error
|
|
if rf, ok := ret.Get(0).(func() error); ok {
|
|
r0 = rf()
|
|
} else {
|
|
r0 = ret.Error(0)
|
|
}
|
|
|
|
return r0
|
|
}
|
|
|
|
// MockDataCoordClient_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'
|
|
type MockDataCoordClient_Close_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Close is a helper method to define mock.On call
|
|
func (_e *MockDataCoordClient_Expecter) Close() *MockDataCoordClient_Close_Call {
|
|
return &MockDataCoordClient_Close_Call{Call: _e.mock.On("Close")}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Close_Call) Run(run func()) *MockDataCoordClient_Close_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
run()
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Close_Call) Return(_a0 error) *MockDataCoordClient_Close_Call {
|
|
_c.Call.Return(_a0)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Close_Call) RunAndReturn(run func() error) *MockDataCoordClient_Close_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// CreateIndex provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) CreateIndex(ctx context.Context, in *indexpb.CreateIndexRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.CreateIndexRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.CreateIndexRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.CreateIndexRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_CreateIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateIndex'
|
|
type MockDataCoordClient_CreateIndex_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// CreateIndex is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.CreateIndexRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) CreateIndex(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_CreateIndex_Call {
|
|
return &MockDataCoordClient_CreateIndex_Call{Call: _e.mock.On("CreateIndex",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_CreateIndex_Call) Run(run func(ctx context.Context, in *indexpb.CreateIndexRequest, opts ...grpc.CallOption)) *MockDataCoordClient_CreateIndex_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.CreateIndexRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_CreateIndex_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_CreateIndex_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_CreateIndex_Call) RunAndReturn(run func(context.Context, *indexpb.CreateIndexRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_CreateIndex_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// DescribeIndex provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) DescribeIndex(ctx context.Context, in *indexpb.DescribeIndexRequest, opts ...grpc.CallOption) (*indexpb.DescribeIndexResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *indexpb.DescribeIndexResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.DescribeIndexRequest, ...grpc.CallOption) (*indexpb.DescribeIndexResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.DescribeIndexRequest, ...grpc.CallOption) *indexpb.DescribeIndexResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*indexpb.DescribeIndexResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.DescribeIndexRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_DescribeIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DescribeIndex'
|
|
type MockDataCoordClient_DescribeIndex_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// DescribeIndex is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.DescribeIndexRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) DescribeIndex(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_DescribeIndex_Call {
|
|
return &MockDataCoordClient_DescribeIndex_Call{Call: _e.mock.On("DescribeIndex",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DescribeIndex_Call) Run(run func(ctx context.Context, in *indexpb.DescribeIndexRequest, opts ...grpc.CallOption)) *MockDataCoordClient_DescribeIndex_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.DescribeIndexRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DescribeIndex_Call) Return(_a0 *indexpb.DescribeIndexResponse, _a1 error) *MockDataCoordClient_DescribeIndex_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DescribeIndex_Call) RunAndReturn(run func(context.Context, *indexpb.DescribeIndexRequest, ...grpc.CallOption) (*indexpb.DescribeIndexResponse, error)) *MockDataCoordClient_DescribeIndex_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// DropIndex provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) DropIndex(ctx context.Context, in *indexpb.DropIndexRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.DropIndexRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.DropIndexRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.DropIndexRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_DropIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DropIndex'
|
|
type MockDataCoordClient_DropIndex_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// DropIndex is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.DropIndexRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) DropIndex(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_DropIndex_Call {
|
|
return &MockDataCoordClient_DropIndex_Call{Call: _e.mock.On("DropIndex",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DropIndex_Call) Run(run func(ctx context.Context, in *indexpb.DropIndexRequest, opts ...grpc.CallOption)) *MockDataCoordClient_DropIndex_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.DropIndexRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DropIndex_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_DropIndex_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DropIndex_Call) RunAndReturn(run func(context.Context, *indexpb.DropIndexRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_DropIndex_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// DropVirtualChannel provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) DropVirtualChannel(ctx context.Context, in *datapb.DropVirtualChannelRequest, opts ...grpc.CallOption) (*datapb.DropVirtualChannelResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.DropVirtualChannelResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.DropVirtualChannelRequest, ...grpc.CallOption) (*datapb.DropVirtualChannelResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.DropVirtualChannelRequest, ...grpc.CallOption) *datapb.DropVirtualChannelResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.DropVirtualChannelResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.DropVirtualChannelRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_DropVirtualChannel_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DropVirtualChannel'
|
|
type MockDataCoordClient_DropVirtualChannel_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// DropVirtualChannel is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.DropVirtualChannelRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) DropVirtualChannel(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_DropVirtualChannel_Call {
|
|
return &MockDataCoordClient_DropVirtualChannel_Call{Call: _e.mock.On("DropVirtualChannel",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DropVirtualChannel_Call) Run(run func(ctx context.Context, in *datapb.DropVirtualChannelRequest, opts ...grpc.CallOption)) *MockDataCoordClient_DropVirtualChannel_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.DropVirtualChannelRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DropVirtualChannel_Call) Return(_a0 *datapb.DropVirtualChannelResponse, _a1 error) *MockDataCoordClient_DropVirtualChannel_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_DropVirtualChannel_Call) RunAndReturn(run func(context.Context, *datapb.DropVirtualChannelRequest, ...grpc.CallOption) (*datapb.DropVirtualChannelResponse, error)) *MockDataCoordClient_DropVirtualChannel_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// Flush provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) Flush(ctx context.Context, in *datapb.FlushRequest, opts ...grpc.CallOption) (*datapb.FlushResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.FlushResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.FlushRequest, ...grpc.CallOption) (*datapb.FlushResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.FlushRequest, ...grpc.CallOption) *datapb.FlushResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.FlushResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.FlushRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_Flush_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Flush'
|
|
type MockDataCoordClient_Flush_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Flush is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.FlushRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) Flush(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_Flush_Call {
|
|
return &MockDataCoordClient_Flush_Call{Call: _e.mock.On("Flush",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Flush_Call) Run(run func(ctx context.Context, in *datapb.FlushRequest, opts ...grpc.CallOption)) *MockDataCoordClient_Flush_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.FlushRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Flush_Call) Return(_a0 *datapb.FlushResponse, _a1 error) *MockDataCoordClient_Flush_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Flush_Call) RunAndReturn(run func(context.Context, *datapb.FlushRequest, ...grpc.CallOption) (*datapb.FlushResponse, error)) *MockDataCoordClient_Flush_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GcConfirm provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GcConfirm(ctx context.Context, in *datapb.GcConfirmRequest, opts ...grpc.CallOption) (*datapb.GcConfirmResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GcConfirmResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GcConfirmRequest, ...grpc.CallOption) (*datapb.GcConfirmResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GcConfirmRequest, ...grpc.CallOption) *datapb.GcConfirmResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GcConfirmResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GcConfirmRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GcConfirm_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GcConfirm'
|
|
type MockDataCoordClient_GcConfirm_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GcConfirm is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GcConfirmRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GcConfirm(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GcConfirm_Call {
|
|
return &MockDataCoordClient_GcConfirm_Call{Call: _e.mock.On("GcConfirm",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GcConfirm_Call) Run(run func(ctx context.Context, in *datapb.GcConfirmRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GcConfirm_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GcConfirmRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GcConfirm_Call) Return(_a0 *datapb.GcConfirmResponse, _a1 error) *MockDataCoordClient_GcConfirm_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GcConfirm_Call) RunAndReturn(run func(context.Context, *datapb.GcConfirmRequest, ...grpc.CallOption) (*datapb.GcConfirmResponse, error)) *MockDataCoordClient_GcConfirm_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetCollectionStatistics provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetCollectionStatistics(ctx context.Context, in *datapb.GetCollectionStatisticsRequest, opts ...grpc.CallOption) (*datapb.GetCollectionStatisticsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetCollectionStatisticsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetCollectionStatisticsRequest, ...grpc.CallOption) (*datapb.GetCollectionStatisticsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetCollectionStatisticsRequest, ...grpc.CallOption) *datapb.GetCollectionStatisticsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetCollectionStatisticsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetCollectionStatisticsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetCollectionStatistics_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCollectionStatistics'
|
|
type MockDataCoordClient_GetCollectionStatistics_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetCollectionStatistics is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetCollectionStatisticsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetCollectionStatistics(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetCollectionStatistics_Call {
|
|
return &MockDataCoordClient_GetCollectionStatistics_Call{Call: _e.mock.On("GetCollectionStatistics",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCollectionStatistics_Call) Run(run func(ctx context.Context, in *datapb.GetCollectionStatisticsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetCollectionStatistics_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetCollectionStatisticsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCollectionStatistics_Call) Return(_a0 *datapb.GetCollectionStatisticsResponse, _a1 error) *MockDataCoordClient_GetCollectionStatistics_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCollectionStatistics_Call) RunAndReturn(run func(context.Context, *datapb.GetCollectionStatisticsRequest, ...grpc.CallOption) (*datapb.GetCollectionStatisticsResponse, error)) *MockDataCoordClient_GetCollectionStatistics_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetCompactionState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetCompactionState(ctx context.Context, in *milvuspb.GetCompactionStateRequest, opts ...grpc.CallOption) (*milvuspb.GetCompactionStateResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.GetCompactionStateResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionStateRequest, ...grpc.CallOption) (*milvuspb.GetCompactionStateResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionStateRequest, ...grpc.CallOption) *milvuspb.GetCompactionStateResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.GetCompactionStateResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetCompactionStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetCompactionState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCompactionState'
|
|
type MockDataCoordClient_GetCompactionState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetCompactionState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.GetCompactionStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetCompactionState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetCompactionState_Call {
|
|
return &MockDataCoordClient_GetCompactionState_Call{Call: _e.mock.On("GetCompactionState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCompactionState_Call) Run(run func(ctx context.Context, in *milvuspb.GetCompactionStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetCompactionState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.GetCompactionStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCompactionState_Call) Return(_a0 *milvuspb.GetCompactionStateResponse, _a1 error) *MockDataCoordClient_GetCompactionState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCompactionState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetCompactionStateRequest, ...grpc.CallOption) (*milvuspb.GetCompactionStateResponse, error)) *MockDataCoordClient_GetCompactionState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetCompactionStateWithPlans provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetCompactionStateWithPlans(ctx context.Context, in *milvuspb.GetCompactionPlansRequest, opts ...grpc.CallOption) (*milvuspb.GetCompactionPlansResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.GetCompactionPlansResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionPlansRequest, ...grpc.CallOption) (*milvuspb.GetCompactionPlansResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionPlansRequest, ...grpc.CallOption) *milvuspb.GetCompactionPlansResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.GetCompactionPlansResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetCompactionPlansRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetCompactionStateWithPlans_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCompactionStateWithPlans'
|
|
type MockDataCoordClient_GetCompactionStateWithPlans_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetCompactionStateWithPlans is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.GetCompactionPlansRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetCompactionStateWithPlans(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetCompactionStateWithPlans_Call {
|
|
return &MockDataCoordClient_GetCompactionStateWithPlans_Call{Call: _e.mock.On("GetCompactionStateWithPlans",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCompactionStateWithPlans_Call) Run(run func(ctx context.Context, in *milvuspb.GetCompactionPlansRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetCompactionStateWithPlans_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.GetCompactionPlansRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCompactionStateWithPlans_Call) Return(_a0 *milvuspb.GetCompactionPlansResponse, _a1 error) *MockDataCoordClient_GetCompactionStateWithPlans_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetCompactionStateWithPlans_Call) RunAndReturn(run func(context.Context, *milvuspb.GetCompactionPlansRequest, ...grpc.CallOption) (*milvuspb.GetCompactionPlansResponse, error)) *MockDataCoordClient_GetCompactionStateWithPlans_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetComponentStates provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetComponentStates(ctx context.Context, in *milvuspb.GetComponentStatesRequest, opts ...grpc.CallOption) (*milvuspb.ComponentStates, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.ComponentStates
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetComponentStatesRequest, ...grpc.CallOption) (*milvuspb.ComponentStates, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetComponentStatesRequest, ...grpc.CallOption) *milvuspb.ComponentStates); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.ComponentStates)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetComponentStatesRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetComponentStates_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetComponentStates'
|
|
type MockDataCoordClient_GetComponentStates_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetComponentStates is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.GetComponentStatesRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetComponentStates(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetComponentStates_Call {
|
|
return &MockDataCoordClient_GetComponentStates_Call{Call: _e.mock.On("GetComponentStates",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetComponentStates_Call) Run(run func(ctx context.Context, in *milvuspb.GetComponentStatesRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetComponentStates_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.GetComponentStatesRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetComponentStates_Call) Return(_a0 *milvuspb.ComponentStates, _a1 error) *MockDataCoordClient_GetComponentStates_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetComponentStates_Call) RunAndReturn(run func(context.Context, *milvuspb.GetComponentStatesRequest, ...grpc.CallOption) (*milvuspb.ComponentStates, error)) *MockDataCoordClient_GetComponentStates_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetFlushAllState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetFlushAllState(ctx context.Context, in *milvuspb.GetFlushAllStateRequest, opts ...grpc.CallOption) (*milvuspb.GetFlushAllStateResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.GetFlushAllStateResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetFlushAllStateRequest, ...grpc.CallOption) (*milvuspb.GetFlushAllStateResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetFlushAllStateRequest, ...grpc.CallOption) *milvuspb.GetFlushAllStateResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.GetFlushAllStateResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetFlushAllStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetFlushAllState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetFlushAllState'
|
|
type MockDataCoordClient_GetFlushAllState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetFlushAllState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.GetFlushAllStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetFlushAllState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetFlushAllState_Call {
|
|
return &MockDataCoordClient_GetFlushAllState_Call{Call: _e.mock.On("GetFlushAllState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushAllState_Call) Run(run func(ctx context.Context, in *milvuspb.GetFlushAllStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetFlushAllState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.GetFlushAllStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushAllState_Call) Return(_a0 *milvuspb.GetFlushAllStateResponse, _a1 error) *MockDataCoordClient_GetFlushAllState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushAllState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetFlushAllStateRequest, ...grpc.CallOption) (*milvuspb.GetFlushAllStateResponse, error)) *MockDataCoordClient_GetFlushAllState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetFlushState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetFlushState(ctx context.Context, in *datapb.GetFlushStateRequest, opts ...grpc.CallOption) (*milvuspb.GetFlushStateResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.GetFlushStateResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetFlushStateRequest, ...grpc.CallOption) (*milvuspb.GetFlushStateResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetFlushStateRequest, ...grpc.CallOption) *milvuspb.GetFlushStateResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.GetFlushStateResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetFlushStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetFlushState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetFlushState'
|
|
type MockDataCoordClient_GetFlushState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetFlushState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetFlushStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetFlushState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetFlushState_Call {
|
|
return &MockDataCoordClient_GetFlushState_Call{Call: _e.mock.On("GetFlushState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushState_Call) Run(run func(ctx context.Context, in *datapb.GetFlushStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetFlushState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetFlushStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushState_Call) Return(_a0 *milvuspb.GetFlushStateResponse, _a1 error) *MockDataCoordClient_GetFlushState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushState_Call) RunAndReturn(run func(context.Context, *datapb.GetFlushStateRequest, ...grpc.CallOption) (*milvuspb.GetFlushStateResponse, error)) *MockDataCoordClient_GetFlushState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetFlushedSegments provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetFlushedSegments(ctx context.Context, in *datapb.GetFlushedSegmentsRequest, opts ...grpc.CallOption) (*datapb.GetFlushedSegmentsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetFlushedSegmentsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetFlushedSegmentsRequest, ...grpc.CallOption) (*datapb.GetFlushedSegmentsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetFlushedSegmentsRequest, ...grpc.CallOption) *datapb.GetFlushedSegmentsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetFlushedSegmentsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetFlushedSegmentsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetFlushedSegments_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetFlushedSegments'
|
|
type MockDataCoordClient_GetFlushedSegments_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetFlushedSegments is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetFlushedSegmentsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetFlushedSegments(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetFlushedSegments_Call {
|
|
return &MockDataCoordClient_GetFlushedSegments_Call{Call: _e.mock.On("GetFlushedSegments",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushedSegments_Call) Run(run func(ctx context.Context, in *datapb.GetFlushedSegmentsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetFlushedSegments_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetFlushedSegmentsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushedSegments_Call) Return(_a0 *datapb.GetFlushedSegmentsResponse, _a1 error) *MockDataCoordClient_GetFlushedSegments_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetFlushedSegments_Call) RunAndReturn(run func(context.Context, *datapb.GetFlushedSegmentsRequest, ...grpc.CallOption) (*datapb.GetFlushedSegmentsResponse, error)) *MockDataCoordClient_GetFlushedSegments_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetIndexBuildProgress provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetIndexBuildProgress(ctx context.Context, in *indexpb.GetIndexBuildProgressRequest, opts ...grpc.CallOption) (*indexpb.GetIndexBuildProgressResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *indexpb.GetIndexBuildProgressResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexBuildProgressRequest, ...grpc.CallOption) (*indexpb.GetIndexBuildProgressResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexBuildProgressRequest, ...grpc.CallOption) *indexpb.GetIndexBuildProgressResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*indexpb.GetIndexBuildProgressResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.GetIndexBuildProgressRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetIndexBuildProgress_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndexBuildProgress'
|
|
type MockDataCoordClient_GetIndexBuildProgress_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetIndexBuildProgress is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.GetIndexBuildProgressRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetIndexBuildProgress(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetIndexBuildProgress_Call {
|
|
return &MockDataCoordClient_GetIndexBuildProgress_Call{Call: _e.mock.On("GetIndexBuildProgress",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexBuildProgress_Call) Run(run func(ctx context.Context, in *indexpb.GetIndexBuildProgressRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetIndexBuildProgress_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.GetIndexBuildProgressRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexBuildProgress_Call) Return(_a0 *indexpb.GetIndexBuildProgressResponse, _a1 error) *MockDataCoordClient_GetIndexBuildProgress_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexBuildProgress_Call) RunAndReturn(run func(context.Context, *indexpb.GetIndexBuildProgressRequest, ...grpc.CallOption) (*indexpb.GetIndexBuildProgressResponse, error)) *MockDataCoordClient_GetIndexBuildProgress_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetIndexInfos provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetIndexInfos(ctx context.Context, in *indexpb.GetIndexInfoRequest, opts ...grpc.CallOption) (*indexpb.GetIndexInfoResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *indexpb.GetIndexInfoResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexInfoRequest, ...grpc.CallOption) (*indexpb.GetIndexInfoResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexInfoRequest, ...grpc.CallOption) *indexpb.GetIndexInfoResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*indexpb.GetIndexInfoResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.GetIndexInfoRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetIndexInfos_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndexInfos'
|
|
type MockDataCoordClient_GetIndexInfos_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetIndexInfos is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.GetIndexInfoRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetIndexInfos(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetIndexInfos_Call {
|
|
return &MockDataCoordClient_GetIndexInfos_Call{Call: _e.mock.On("GetIndexInfos",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexInfos_Call) Run(run func(ctx context.Context, in *indexpb.GetIndexInfoRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetIndexInfos_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.GetIndexInfoRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexInfos_Call) Return(_a0 *indexpb.GetIndexInfoResponse, _a1 error) *MockDataCoordClient_GetIndexInfos_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexInfos_Call) RunAndReturn(run func(context.Context, *indexpb.GetIndexInfoRequest, ...grpc.CallOption) (*indexpb.GetIndexInfoResponse, error)) *MockDataCoordClient_GetIndexInfos_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetIndexState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetIndexState(ctx context.Context, in *indexpb.GetIndexStateRequest, opts ...grpc.CallOption) (*indexpb.GetIndexStateResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *indexpb.GetIndexStateResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexStateRequest, ...grpc.CallOption) (*indexpb.GetIndexStateResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexStateRequest, ...grpc.CallOption) *indexpb.GetIndexStateResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*indexpb.GetIndexStateResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.GetIndexStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetIndexState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndexState'
|
|
type MockDataCoordClient_GetIndexState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetIndexState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.GetIndexStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetIndexState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetIndexState_Call {
|
|
return &MockDataCoordClient_GetIndexState_Call{Call: _e.mock.On("GetIndexState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexState_Call) Run(run func(ctx context.Context, in *indexpb.GetIndexStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetIndexState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.GetIndexStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexState_Call) Return(_a0 *indexpb.GetIndexStateResponse, _a1 error) *MockDataCoordClient_GetIndexState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexState_Call) RunAndReturn(run func(context.Context, *indexpb.GetIndexStateRequest, ...grpc.CallOption) (*indexpb.GetIndexStateResponse, error)) *MockDataCoordClient_GetIndexState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetIndexStatistics provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetIndexStatistics(ctx context.Context, in *indexpb.GetIndexStatisticsRequest, opts ...grpc.CallOption) (*indexpb.GetIndexStatisticsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *indexpb.GetIndexStatisticsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexStatisticsRequest, ...grpc.CallOption) (*indexpb.GetIndexStatisticsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetIndexStatisticsRequest, ...grpc.CallOption) *indexpb.GetIndexStatisticsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*indexpb.GetIndexStatisticsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.GetIndexStatisticsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetIndexStatistics_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndexStatistics'
|
|
type MockDataCoordClient_GetIndexStatistics_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetIndexStatistics is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.GetIndexStatisticsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetIndexStatistics(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetIndexStatistics_Call {
|
|
return &MockDataCoordClient_GetIndexStatistics_Call{Call: _e.mock.On("GetIndexStatistics",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexStatistics_Call) Run(run func(ctx context.Context, in *indexpb.GetIndexStatisticsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetIndexStatistics_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.GetIndexStatisticsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexStatistics_Call) Return(_a0 *indexpb.GetIndexStatisticsResponse, _a1 error) *MockDataCoordClient_GetIndexStatistics_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetIndexStatistics_Call) RunAndReturn(run func(context.Context, *indexpb.GetIndexStatisticsRequest, ...grpc.CallOption) (*indexpb.GetIndexStatisticsResponse, error)) *MockDataCoordClient_GetIndexStatistics_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetInsertBinlogPaths provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetInsertBinlogPaths(ctx context.Context, in *datapb.GetInsertBinlogPathsRequest, opts ...grpc.CallOption) (*datapb.GetInsertBinlogPathsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetInsertBinlogPathsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetInsertBinlogPathsRequest, ...grpc.CallOption) (*datapb.GetInsertBinlogPathsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetInsertBinlogPathsRequest, ...grpc.CallOption) *datapb.GetInsertBinlogPathsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetInsertBinlogPathsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetInsertBinlogPathsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetInsertBinlogPaths_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetInsertBinlogPaths'
|
|
type MockDataCoordClient_GetInsertBinlogPaths_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetInsertBinlogPaths is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetInsertBinlogPathsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetInsertBinlogPaths(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetInsertBinlogPaths_Call {
|
|
return &MockDataCoordClient_GetInsertBinlogPaths_Call{Call: _e.mock.On("GetInsertBinlogPaths",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetInsertBinlogPaths_Call) Run(run func(ctx context.Context, in *datapb.GetInsertBinlogPathsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetInsertBinlogPaths_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetInsertBinlogPathsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetInsertBinlogPaths_Call) Return(_a0 *datapb.GetInsertBinlogPathsResponse, _a1 error) *MockDataCoordClient_GetInsertBinlogPaths_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetInsertBinlogPaths_Call) RunAndReturn(run func(context.Context, *datapb.GetInsertBinlogPathsRequest, ...grpc.CallOption) (*datapb.GetInsertBinlogPathsResponse, error)) *MockDataCoordClient_GetInsertBinlogPaths_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetMetrics provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetMetrics(ctx context.Context, in *milvuspb.GetMetricsRequest, opts ...grpc.CallOption) (*milvuspb.GetMetricsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.GetMetricsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetMetricsRequest, ...grpc.CallOption) (*milvuspb.GetMetricsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetMetricsRequest, ...grpc.CallOption) *milvuspb.GetMetricsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.GetMetricsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetMetricsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetMetrics_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetMetrics'
|
|
type MockDataCoordClient_GetMetrics_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetMetrics is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.GetMetricsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetMetrics(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetMetrics_Call {
|
|
return &MockDataCoordClient_GetMetrics_Call{Call: _e.mock.On("GetMetrics",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetMetrics_Call) Run(run func(ctx context.Context, in *milvuspb.GetMetricsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetMetrics_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.GetMetricsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetMetrics_Call) Return(_a0 *milvuspb.GetMetricsResponse, _a1 error) *MockDataCoordClient_GetMetrics_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetMetrics_Call) RunAndReturn(run func(context.Context, *milvuspb.GetMetricsRequest, ...grpc.CallOption) (*milvuspb.GetMetricsResponse, error)) *MockDataCoordClient_GetMetrics_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetPartitionStatistics provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetPartitionStatistics(ctx context.Context, in *datapb.GetPartitionStatisticsRequest, opts ...grpc.CallOption) (*datapb.GetPartitionStatisticsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetPartitionStatisticsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetPartitionStatisticsRequest, ...grpc.CallOption) (*datapb.GetPartitionStatisticsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetPartitionStatisticsRequest, ...grpc.CallOption) *datapb.GetPartitionStatisticsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetPartitionStatisticsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetPartitionStatisticsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetPartitionStatistics_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPartitionStatistics'
|
|
type MockDataCoordClient_GetPartitionStatistics_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetPartitionStatistics is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetPartitionStatisticsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetPartitionStatistics(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetPartitionStatistics_Call {
|
|
return &MockDataCoordClient_GetPartitionStatistics_Call{Call: _e.mock.On("GetPartitionStatistics",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetPartitionStatistics_Call) Run(run func(ctx context.Context, in *datapb.GetPartitionStatisticsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetPartitionStatistics_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetPartitionStatisticsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetPartitionStatistics_Call) Return(_a0 *datapb.GetPartitionStatisticsResponse, _a1 error) *MockDataCoordClient_GetPartitionStatistics_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetPartitionStatistics_Call) RunAndReturn(run func(context.Context, *datapb.GetPartitionStatisticsRequest, ...grpc.CallOption) (*datapb.GetPartitionStatisticsResponse, error)) *MockDataCoordClient_GetPartitionStatistics_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetRecoveryInfo provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetRecoveryInfo(ctx context.Context, in *datapb.GetRecoveryInfoRequest, opts ...grpc.CallOption) (*datapb.GetRecoveryInfoResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetRecoveryInfoResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetRecoveryInfoRequest, ...grpc.CallOption) (*datapb.GetRecoveryInfoResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetRecoveryInfoRequest, ...grpc.CallOption) *datapb.GetRecoveryInfoResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetRecoveryInfoResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetRecoveryInfoRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetRecoveryInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRecoveryInfo'
|
|
type MockDataCoordClient_GetRecoveryInfo_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetRecoveryInfo is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetRecoveryInfoRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetRecoveryInfo(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetRecoveryInfo_Call {
|
|
return &MockDataCoordClient_GetRecoveryInfo_Call{Call: _e.mock.On("GetRecoveryInfo",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetRecoveryInfo_Call) Run(run func(ctx context.Context, in *datapb.GetRecoveryInfoRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetRecoveryInfo_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetRecoveryInfoRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetRecoveryInfo_Call) Return(_a0 *datapb.GetRecoveryInfoResponse, _a1 error) *MockDataCoordClient_GetRecoveryInfo_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetRecoveryInfo_Call) RunAndReturn(run func(context.Context, *datapb.GetRecoveryInfoRequest, ...grpc.CallOption) (*datapb.GetRecoveryInfoResponse, error)) *MockDataCoordClient_GetRecoveryInfo_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetRecoveryInfoV2 provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetRecoveryInfoV2(ctx context.Context, in *datapb.GetRecoveryInfoRequestV2, opts ...grpc.CallOption) (*datapb.GetRecoveryInfoResponseV2, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetRecoveryInfoResponseV2
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetRecoveryInfoRequestV2, ...grpc.CallOption) (*datapb.GetRecoveryInfoResponseV2, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetRecoveryInfoRequestV2, ...grpc.CallOption) *datapb.GetRecoveryInfoResponseV2); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetRecoveryInfoResponseV2)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetRecoveryInfoRequestV2, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetRecoveryInfoV2_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRecoveryInfoV2'
|
|
type MockDataCoordClient_GetRecoveryInfoV2_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetRecoveryInfoV2 is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetRecoveryInfoRequestV2
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetRecoveryInfoV2(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetRecoveryInfoV2_Call {
|
|
return &MockDataCoordClient_GetRecoveryInfoV2_Call{Call: _e.mock.On("GetRecoveryInfoV2",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetRecoveryInfoV2_Call) Run(run func(ctx context.Context, in *datapb.GetRecoveryInfoRequestV2, opts ...grpc.CallOption)) *MockDataCoordClient_GetRecoveryInfoV2_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetRecoveryInfoRequestV2), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetRecoveryInfoV2_Call) Return(_a0 *datapb.GetRecoveryInfoResponseV2, _a1 error) *MockDataCoordClient_GetRecoveryInfoV2_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetRecoveryInfoV2_Call) RunAndReturn(run func(context.Context, *datapb.GetRecoveryInfoRequestV2, ...grpc.CallOption) (*datapb.GetRecoveryInfoResponseV2, error)) *MockDataCoordClient_GetRecoveryInfoV2_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetSegmentIndexState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetSegmentIndexState(ctx context.Context, in *indexpb.GetSegmentIndexStateRequest, opts ...grpc.CallOption) (*indexpb.GetSegmentIndexStateResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *indexpb.GetSegmentIndexStateResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetSegmentIndexStateRequest, ...grpc.CallOption) (*indexpb.GetSegmentIndexStateResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *indexpb.GetSegmentIndexStateRequest, ...grpc.CallOption) *indexpb.GetSegmentIndexStateResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*indexpb.GetSegmentIndexStateResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *indexpb.GetSegmentIndexStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetSegmentIndexState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSegmentIndexState'
|
|
type MockDataCoordClient_GetSegmentIndexState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetSegmentIndexState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *indexpb.GetSegmentIndexStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetSegmentIndexState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetSegmentIndexState_Call {
|
|
return &MockDataCoordClient_GetSegmentIndexState_Call{Call: _e.mock.On("GetSegmentIndexState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentIndexState_Call) Run(run func(ctx context.Context, in *indexpb.GetSegmentIndexStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetSegmentIndexState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*indexpb.GetSegmentIndexStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentIndexState_Call) Return(_a0 *indexpb.GetSegmentIndexStateResponse, _a1 error) *MockDataCoordClient_GetSegmentIndexState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentIndexState_Call) RunAndReturn(run func(context.Context, *indexpb.GetSegmentIndexStateRequest, ...grpc.CallOption) (*indexpb.GetSegmentIndexStateResponse, error)) *MockDataCoordClient_GetSegmentIndexState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetSegmentInfo provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetSegmentInfo(ctx context.Context, in *datapb.GetSegmentInfoRequest, opts ...grpc.CallOption) (*datapb.GetSegmentInfoResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetSegmentInfoResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentInfoRequest, ...grpc.CallOption) (*datapb.GetSegmentInfoResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentInfoRequest, ...grpc.CallOption) *datapb.GetSegmentInfoResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetSegmentInfoResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetSegmentInfoRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetSegmentInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSegmentInfo'
|
|
type MockDataCoordClient_GetSegmentInfo_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetSegmentInfo is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetSegmentInfoRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetSegmentInfo(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetSegmentInfo_Call {
|
|
return &MockDataCoordClient_GetSegmentInfo_Call{Call: _e.mock.On("GetSegmentInfo",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentInfo_Call) Run(run func(ctx context.Context, in *datapb.GetSegmentInfoRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetSegmentInfo_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetSegmentInfoRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentInfo_Call) Return(_a0 *datapb.GetSegmentInfoResponse, _a1 error) *MockDataCoordClient_GetSegmentInfo_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentInfo_Call) RunAndReturn(run func(context.Context, *datapb.GetSegmentInfoRequest, ...grpc.CallOption) (*datapb.GetSegmentInfoResponse, error)) *MockDataCoordClient_GetSegmentInfo_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetSegmentInfoChannel provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetSegmentInfoChannel(ctx context.Context, in *datapb.GetSegmentInfoChannelRequest, opts ...grpc.CallOption) (*milvuspb.StringResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.StringResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentInfoChannelRequest, ...grpc.CallOption) (*milvuspb.StringResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentInfoChannelRequest, ...grpc.CallOption) *milvuspb.StringResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.StringResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetSegmentInfoChannelRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetSegmentInfoChannel_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSegmentInfoChannel'
|
|
type MockDataCoordClient_GetSegmentInfoChannel_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetSegmentInfoChannel is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetSegmentInfoChannelRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetSegmentInfoChannel(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetSegmentInfoChannel_Call {
|
|
return &MockDataCoordClient_GetSegmentInfoChannel_Call{Call: _e.mock.On("GetSegmentInfoChannel",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentInfoChannel_Call) Run(run func(ctx context.Context, in *datapb.GetSegmentInfoChannelRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetSegmentInfoChannel_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetSegmentInfoChannelRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentInfoChannel_Call) Return(_a0 *milvuspb.StringResponse, _a1 error) *MockDataCoordClient_GetSegmentInfoChannel_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentInfoChannel_Call) RunAndReturn(run func(context.Context, *datapb.GetSegmentInfoChannelRequest, ...grpc.CallOption) (*milvuspb.StringResponse, error)) *MockDataCoordClient_GetSegmentInfoChannel_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetSegmentStates provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetSegmentStates(ctx context.Context, in *datapb.GetSegmentStatesRequest, opts ...grpc.CallOption) (*datapb.GetSegmentStatesResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetSegmentStatesResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentStatesRequest, ...grpc.CallOption) (*datapb.GetSegmentStatesResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentStatesRequest, ...grpc.CallOption) *datapb.GetSegmentStatesResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetSegmentStatesResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetSegmentStatesRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetSegmentStates_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSegmentStates'
|
|
type MockDataCoordClient_GetSegmentStates_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetSegmentStates is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetSegmentStatesRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetSegmentStates(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetSegmentStates_Call {
|
|
return &MockDataCoordClient_GetSegmentStates_Call{Call: _e.mock.On("GetSegmentStates",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentStates_Call) Run(run func(ctx context.Context, in *datapb.GetSegmentStatesRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetSegmentStates_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetSegmentStatesRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentStates_Call) Return(_a0 *datapb.GetSegmentStatesResponse, _a1 error) *MockDataCoordClient_GetSegmentStates_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentStates_Call) RunAndReturn(run func(context.Context, *datapb.GetSegmentStatesRequest, ...grpc.CallOption) (*datapb.GetSegmentStatesResponse, error)) *MockDataCoordClient_GetSegmentStates_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetSegmentsByStates provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetSegmentsByStates(ctx context.Context, in *datapb.GetSegmentsByStatesRequest, opts ...grpc.CallOption) (*datapb.GetSegmentsByStatesResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.GetSegmentsByStatesResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentsByStatesRequest, ...grpc.CallOption) (*datapb.GetSegmentsByStatesResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.GetSegmentsByStatesRequest, ...grpc.CallOption) *datapb.GetSegmentsByStatesResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.GetSegmentsByStatesResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.GetSegmentsByStatesRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetSegmentsByStates_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetSegmentsByStates'
|
|
type MockDataCoordClient_GetSegmentsByStates_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetSegmentsByStates is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.GetSegmentsByStatesRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetSegmentsByStates(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetSegmentsByStates_Call {
|
|
return &MockDataCoordClient_GetSegmentsByStates_Call{Call: _e.mock.On("GetSegmentsByStates",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentsByStates_Call) Run(run func(ctx context.Context, in *datapb.GetSegmentsByStatesRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetSegmentsByStates_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.GetSegmentsByStatesRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentsByStates_Call) Return(_a0 *datapb.GetSegmentsByStatesResponse, _a1 error) *MockDataCoordClient_GetSegmentsByStates_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetSegmentsByStates_Call) RunAndReturn(run func(context.Context, *datapb.GetSegmentsByStatesRequest, ...grpc.CallOption) (*datapb.GetSegmentsByStatesResponse, error)) *MockDataCoordClient_GetSegmentsByStates_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetStatisticsChannel provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetStatisticsChannel(ctx context.Context, in *internalpb.GetStatisticsChannelRequest, opts ...grpc.CallOption) (*milvuspb.StringResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.StringResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *internalpb.GetStatisticsChannelRequest, ...grpc.CallOption) (*milvuspb.StringResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *internalpb.GetStatisticsChannelRequest, ...grpc.CallOption) *milvuspb.StringResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.StringResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *internalpb.GetStatisticsChannelRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetStatisticsChannel_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetStatisticsChannel'
|
|
type MockDataCoordClient_GetStatisticsChannel_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetStatisticsChannel is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *internalpb.GetStatisticsChannelRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetStatisticsChannel(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetStatisticsChannel_Call {
|
|
return &MockDataCoordClient_GetStatisticsChannel_Call{Call: _e.mock.On("GetStatisticsChannel",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetStatisticsChannel_Call) Run(run func(ctx context.Context, in *internalpb.GetStatisticsChannelRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetStatisticsChannel_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*internalpb.GetStatisticsChannelRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetStatisticsChannel_Call) Return(_a0 *milvuspb.StringResponse, _a1 error) *MockDataCoordClient_GetStatisticsChannel_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetStatisticsChannel_Call) RunAndReturn(run func(context.Context, *internalpb.GetStatisticsChannelRequest, ...grpc.CallOption) (*milvuspb.StringResponse, error)) *MockDataCoordClient_GetStatisticsChannel_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// GetTimeTickChannel provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) GetTimeTickChannel(ctx context.Context, in *internalpb.GetTimeTickChannelRequest, opts ...grpc.CallOption) (*milvuspb.StringResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.StringResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *internalpb.GetTimeTickChannelRequest, ...grpc.CallOption) (*milvuspb.StringResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *internalpb.GetTimeTickChannelRequest, ...grpc.CallOption) *milvuspb.StringResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.StringResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *internalpb.GetTimeTickChannelRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_GetTimeTickChannel_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTimeTickChannel'
|
|
type MockDataCoordClient_GetTimeTickChannel_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// GetTimeTickChannel is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *internalpb.GetTimeTickChannelRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) GetTimeTickChannel(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_GetTimeTickChannel_Call {
|
|
return &MockDataCoordClient_GetTimeTickChannel_Call{Call: _e.mock.On("GetTimeTickChannel",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetTimeTickChannel_Call) Run(run func(ctx context.Context, in *internalpb.GetTimeTickChannelRequest, opts ...grpc.CallOption)) *MockDataCoordClient_GetTimeTickChannel_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*internalpb.GetTimeTickChannelRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetTimeTickChannel_Call) Return(_a0 *milvuspb.StringResponse, _a1 error) *MockDataCoordClient_GetTimeTickChannel_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_GetTimeTickChannel_Call) RunAndReturn(run func(context.Context, *internalpb.GetTimeTickChannelRequest, ...grpc.CallOption) (*milvuspb.StringResponse, error)) *MockDataCoordClient_GetTimeTickChannel_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// Import provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) Import(ctx context.Context, in *datapb.ImportTaskRequest, opts ...grpc.CallOption) (*datapb.ImportTaskResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.ImportTaskResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.ImportTaskRequest, ...grpc.CallOption) (*datapb.ImportTaskResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.ImportTaskRequest, ...grpc.CallOption) *datapb.ImportTaskResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.ImportTaskResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.ImportTaskRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_Import_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Import'
|
|
type MockDataCoordClient_Import_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Import is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.ImportTaskRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) Import(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_Import_Call {
|
|
return &MockDataCoordClient_Import_Call{Call: _e.mock.On("Import",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Import_Call) Run(run func(ctx context.Context, in *datapb.ImportTaskRequest, opts ...grpc.CallOption)) *MockDataCoordClient_Import_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.ImportTaskRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Import_Call) Return(_a0 *datapb.ImportTaskResponse, _a1 error) *MockDataCoordClient_Import_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_Import_Call) RunAndReturn(run func(context.Context, *datapb.ImportTaskRequest, ...grpc.CallOption) (*datapb.ImportTaskResponse, error)) *MockDataCoordClient_Import_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// ManualCompaction provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) ManualCompaction(ctx context.Context, in *milvuspb.ManualCompactionRequest, opts ...grpc.CallOption) (*milvuspb.ManualCompactionResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *milvuspb.ManualCompactionResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ManualCompactionRequest, ...grpc.CallOption) (*milvuspb.ManualCompactionResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ManualCompactionRequest, ...grpc.CallOption) *milvuspb.ManualCompactionResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*milvuspb.ManualCompactionResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ManualCompactionRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_ManualCompaction_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ManualCompaction'
|
|
type MockDataCoordClient_ManualCompaction_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// ManualCompaction is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *milvuspb.ManualCompactionRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) ManualCompaction(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_ManualCompaction_Call {
|
|
return &MockDataCoordClient_ManualCompaction_Call{Call: _e.mock.On("ManualCompaction",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ManualCompaction_Call) Run(run func(ctx context.Context, in *milvuspb.ManualCompactionRequest, opts ...grpc.CallOption)) *MockDataCoordClient_ManualCompaction_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*milvuspb.ManualCompactionRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ManualCompaction_Call) Return(_a0 *milvuspb.ManualCompactionResponse, _a1 error) *MockDataCoordClient_ManualCompaction_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ManualCompaction_Call) RunAndReturn(run func(context.Context, *milvuspb.ManualCompactionRequest, ...grpc.CallOption) (*milvuspb.ManualCompactionResponse, error)) *MockDataCoordClient_ManualCompaction_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// MarkSegmentsDropped provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) MarkSegmentsDropped(ctx context.Context, in *datapb.MarkSegmentsDroppedRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.MarkSegmentsDroppedRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.MarkSegmentsDroppedRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.MarkSegmentsDroppedRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_MarkSegmentsDropped_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'MarkSegmentsDropped'
|
|
type MockDataCoordClient_MarkSegmentsDropped_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// MarkSegmentsDropped is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.MarkSegmentsDroppedRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) MarkSegmentsDropped(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_MarkSegmentsDropped_Call {
|
|
return &MockDataCoordClient_MarkSegmentsDropped_Call{Call: _e.mock.On("MarkSegmentsDropped",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_MarkSegmentsDropped_Call) Run(run func(ctx context.Context, in *datapb.MarkSegmentsDroppedRequest, opts ...grpc.CallOption)) *MockDataCoordClient_MarkSegmentsDropped_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.MarkSegmentsDroppedRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_MarkSegmentsDropped_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_MarkSegmentsDropped_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_MarkSegmentsDropped_Call) RunAndReturn(run func(context.Context, *datapb.MarkSegmentsDroppedRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_MarkSegmentsDropped_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// ReportDataNodeTtMsgs provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) ReportDataNodeTtMsgs(ctx context.Context, in *datapb.ReportDataNodeTtMsgsRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.ReportDataNodeTtMsgsRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.ReportDataNodeTtMsgsRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.ReportDataNodeTtMsgsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_ReportDataNodeTtMsgs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ReportDataNodeTtMsgs'
|
|
type MockDataCoordClient_ReportDataNodeTtMsgs_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// ReportDataNodeTtMsgs is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.ReportDataNodeTtMsgsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) ReportDataNodeTtMsgs(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_ReportDataNodeTtMsgs_Call {
|
|
return &MockDataCoordClient_ReportDataNodeTtMsgs_Call{Call: _e.mock.On("ReportDataNodeTtMsgs",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ReportDataNodeTtMsgs_Call) Run(run func(ctx context.Context, in *datapb.ReportDataNodeTtMsgsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_ReportDataNodeTtMsgs_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.ReportDataNodeTtMsgsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ReportDataNodeTtMsgs_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_ReportDataNodeTtMsgs_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ReportDataNodeTtMsgs_Call) RunAndReturn(run func(context.Context, *datapb.ReportDataNodeTtMsgsRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_ReportDataNodeTtMsgs_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// SaveBinlogPaths provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) SaveBinlogPaths(ctx context.Context, in *datapb.SaveBinlogPathsRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.SaveBinlogPathsRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.SaveBinlogPathsRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.SaveBinlogPathsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_SaveBinlogPaths_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SaveBinlogPaths'
|
|
type MockDataCoordClient_SaveBinlogPaths_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// SaveBinlogPaths is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.SaveBinlogPathsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) SaveBinlogPaths(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_SaveBinlogPaths_Call {
|
|
return &MockDataCoordClient_SaveBinlogPaths_Call{Call: _e.mock.On("SaveBinlogPaths",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SaveBinlogPaths_Call) Run(run func(ctx context.Context, in *datapb.SaveBinlogPathsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_SaveBinlogPaths_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.SaveBinlogPathsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SaveBinlogPaths_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_SaveBinlogPaths_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SaveBinlogPaths_Call) RunAndReturn(run func(context.Context, *datapb.SaveBinlogPathsRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_SaveBinlogPaths_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// SaveImportSegment provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) SaveImportSegment(ctx context.Context, in *datapb.SaveImportSegmentRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.SaveImportSegmentRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.SaveImportSegmentRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.SaveImportSegmentRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_SaveImportSegment_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SaveImportSegment'
|
|
type MockDataCoordClient_SaveImportSegment_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// SaveImportSegment is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.SaveImportSegmentRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) SaveImportSegment(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_SaveImportSegment_Call {
|
|
return &MockDataCoordClient_SaveImportSegment_Call{Call: _e.mock.On("SaveImportSegment",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SaveImportSegment_Call) Run(run func(ctx context.Context, in *datapb.SaveImportSegmentRequest, opts ...grpc.CallOption)) *MockDataCoordClient_SaveImportSegment_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.SaveImportSegmentRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SaveImportSegment_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_SaveImportSegment_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SaveImportSegment_Call) RunAndReturn(run func(context.Context, *datapb.SaveImportSegmentRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_SaveImportSegment_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// SetSegmentState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) SetSegmentState(ctx context.Context, in *datapb.SetSegmentStateRequest, opts ...grpc.CallOption) (*datapb.SetSegmentStateResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.SetSegmentStateResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.SetSegmentStateRequest, ...grpc.CallOption) (*datapb.SetSegmentStateResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.SetSegmentStateRequest, ...grpc.CallOption) *datapb.SetSegmentStateResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.SetSegmentStateResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.SetSegmentStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_SetSegmentState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetSegmentState'
|
|
type MockDataCoordClient_SetSegmentState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// SetSegmentState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.SetSegmentStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) SetSegmentState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_SetSegmentState_Call {
|
|
return &MockDataCoordClient_SetSegmentState_Call{Call: _e.mock.On("SetSegmentState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SetSegmentState_Call) Run(run func(ctx context.Context, in *datapb.SetSegmentStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_SetSegmentState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.SetSegmentStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SetSegmentState_Call) Return(_a0 *datapb.SetSegmentStateResponse, _a1 error) *MockDataCoordClient_SetSegmentState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_SetSegmentState_Call) RunAndReturn(run func(context.Context, *datapb.SetSegmentStateRequest, ...grpc.CallOption) (*datapb.SetSegmentStateResponse, error)) *MockDataCoordClient_SetSegmentState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// ShowConfigurations provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) ShowConfigurations(ctx context.Context, in *internalpb.ShowConfigurationsRequest, opts ...grpc.CallOption) (*internalpb.ShowConfigurationsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *internalpb.ShowConfigurationsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *internalpb.ShowConfigurationsRequest, ...grpc.CallOption) (*internalpb.ShowConfigurationsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *internalpb.ShowConfigurationsRequest, ...grpc.CallOption) *internalpb.ShowConfigurationsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*internalpb.ShowConfigurationsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *internalpb.ShowConfigurationsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_ShowConfigurations_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ShowConfigurations'
|
|
type MockDataCoordClient_ShowConfigurations_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// ShowConfigurations is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *internalpb.ShowConfigurationsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) ShowConfigurations(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_ShowConfigurations_Call {
|
|
return &MockDataCoordClient_ShowConfigurations_Call{Call: _e.mock.On("ShowConfigurations",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ShowConfigurations_Call) Run(run func(ctx context.Context, in *internalpb.ShowConfigurationsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_ShowConfigurations_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*internalpb.ShowConfigurationsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ShowConfigurations_Call) Return(_a0 *internalpb.ShowConfigurationsResponse, _a1 error) *MockDataCoordClient_ShowConfigurations_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_ShowConfigurations_Call) RunAndReturn(run func(context.Context, *internalpb.ShowConfigurationsRequest, ...grpc.CallOption) (*internalpb.ShowConfigurationsResponse, error)) *MockDataCoordClient_ShowConfigurations_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// UnsetIsImportingState provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) UnsetIsImportingState(ctx context.Context, in *datapb.UnsetIsImportingStateRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.UnsetIsImportingStateRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.UnsetIsImportingStateRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.UnsetIsImportingStateRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_UnsetIsImportingState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UnsetIsImportingState'
|
|
type MockDataCoordClient_UnsetIsImportingState_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// UnsetIsImportingState is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.UnsetIsImportingStateRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) UnsetIsImportingState(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_UnsetIsImportingState_Call {
|
|
return &MockDataCoordClient_UnsetIsImportingState_Call{Call: _e.mock.On("UnsetIsImportingState",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UnsetIsImportingState_Call) Run(run func(ctx context.Context, in *datapb.UnsetIsImportingStateRequest, opts ...grpc.CallOption)) *MockDataCoordClient_UnsetIsImportingState_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.UnsetIsImportingStateRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UnsetIsImportingState_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_UnsetIsImportingState_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UnsetIsImportingState_Call) RunAndReturn(run func(context.Context, *datapb.UnsetIsImportingStateRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_UnsetIsImportingState_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// UpdateChannelCheckpoint provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) UpdateChannelCheckpoint(ctx context.Context, in *datapb.UpdateChannelCheckpointRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.UpdateChannelCheckpointRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.UpdateChannelCheckpointRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.UpdateChannelCheckpointRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_UpdateChannelCheckpoint_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateChannelCheckpoint'
|
|
type MockDataCoordClient_UpdateChannelCheckpoint_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// UpdateChannelCheckpoint is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.UpdateChannelCheckpointRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) UpdateChannelCheckpoint(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_UpdateChannelCheckpoint_Call {
|
|
return &MockDataCoordClient_UpdateChannelCheckpoint_Call{Call: _e.mock.On("UpdateChannelCheckpoint",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UpdateChannelCheckpoint_Call) Run(run func(ctx context.Context, in *datapb.UpdateChannelCheckpointRequest, opts ...grpc.CallOption)) *MockDataCoordClient_UpdateChannelCheckpoint_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.UpdateChannelCheckpointRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UpdateChannelCheckpoint_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_UpdateChannelCheckpoint_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UpdateChannelCheckpoint_Call) RunAndReturn(run func(context.Context, *datapb.UpdateChannelCheckpointRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_UpdateChannelCheckpoint_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// UpdateSegmentStatistics provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) UpdateSegmentStatistics(ctx context.Context, in *datapb.UpdateSegmentStatisticsRequest, opts ...grpc.CallOption) (*commonpb.Status, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *commonpb.Status
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.UpdateSegmentStatisticsRequest, ...grpc.CallOption) (*commonpb.Status, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.UpdateSegmentStatisticsRequest, ...grpc.CallOption) *commonpb.Status); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*commonpb.Status)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.UpdateSegmentStatisticsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_UpdateSegmentStatistics_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateSegmentStatistics'
|
|
type MockDataCoordClient_UpdateSegmentStatistics_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// UpdateSegmentStatistics is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.UpdateSegmentStatisticsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) UpdateSegmentStatistics(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_UpdateSegmentStatistics_Call {
|
|
return &MockDataCoordClient_UpdateSegmentStatistics_Call{Call: _e.mock.On("UpdateSegmentStatistics",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UpdateSegmentStatistics_Call) Run(run func(ctx context.Context, in *datapb.UpdateSegmentStatisticsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_UpdateSegmentStatistics_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.UpdateSegmentStatisticsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UpdateSegmentStatistics_Call) Return(_a0 *commonpb.Status, _a1 error) *MockDataCoordClient_UpdateSegmentStatistics_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_UpdateSegmentStatistics_Call) RunAndReturn(run func(context.Context, *datapb.UpdateSegmentStatisticsRequest, ...grpc.CallOption) (*commonpb.Status, error)) *MockDataCoordClient_UpdateSegmentStatistics_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// WatchChannels provides a mock function with given fields: ctx, in, opts
|
|
func (_m *MockDataCoordClient) WatchChannels(ctx context.Context, in *datapb.WatchChannelsRequest, opts ...grpc.CallOption) (*datapb.WatchChannelsResponse, error) {
|
|
_va := make([]interface{}, len(opts))
|
|
for _i := range opts {
|
|
_va[_i] = opts[_i]
|
|
}
|
|
var _ca []interface{}
|
|
_ca = append(_ca, ctx, in)
|
|
_ca = append(_ca, _va...)
|
|
ret := _m.Called(_ca...)
|
|
|
|
var r0 *datapb.WatchChannelsResponse
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.WatchChannelsRequest, ...grpc.CallOption) (*datapb.WatchChannelsResponse, error)); ok {
|
|
return rf(ctx, in, opts...)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(context.Context, *datapb.WatchChannelsRequest, ...grpc.CallOption) *datapb.WatchChannelsResponse); ok {
|
|
r0 = rf(ctx, in, opts...)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*datapb.WatchChannelsResponse)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(context.Context, *datapb.WatchChannelsRequest, ...grpc.CallOption) error); ok {
|
|
r1 = rf(ctx, in, opts...)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// MockDataCoordClient_WatchChannels_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'WatchChannels'
|
|
type MockDataCoordClient_WatchChannels_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// WatchChannels is a helper method to define mock.On call
|
|
// - ctx context.Context
|
|
// - in *datapb.WatchChannelsRequest
|
|
// - opts ...grpc.CallOption
|
|
func (_e *MockDataCoordClient_Expecter) WatchChannels(ctx interface{}, in interface{}, opts ...interface{}) *MockDataCoordClient_WatchChannels_Call {
|
|
return &MockDataCoordClient_WatchChannels_Call{Call: _e.mock.On("WatchChannels",
|
|
append([]interface{}{ctx, in}, opts...)...)}
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_WatchChannels_Call) Run(run func(ctx context.Context, in *datapb.WatchChannelsRequest, opts ...grpc.CallOption)) *MockDataCoordClient_WatchChannels_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
variadicArgs := make([]grpc.CallOption, len(args)-2)
|
|
for i, a := range args[2:] {
|
|
if a != nil {
|
|
variadicArgs[i] = a.(grpc.CallOption)
|
|
}
|
|
}
|
|
run(args[0].(context.Context), args[1].(*datapb.WatchChannelsRequest), variadicArgs...)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_WatchChannels_Call) Return(_a0 *datapb.WatchChannelsResponse, _a1 error) *MockDataCoordClient_WatchChannels_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *MockDataCoordClient_WatchChannels_Call) RunAndReturn(run func(context.Context, *datapb.WatchChannelsRequest, ...grpc.CallOption) (*datapb.WatchChannelsResponse, error)) *MockDataCoordClient_WatchChannels_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// NewMockDataCoordClient creates a new instance of MockDataCoordClient. 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 NewMockDataCoordClient(t interface {
|
|
mock.TestingT
|
|
Cleanup(func())
|
|
}) *MockDataCoordClient {
|
|
mock := &MockDataCoordClient{}
|
|
mock.Mock.Test(t)
|
|
|
|
t.Cleanup(func() { mock.AssertExpectations(t) })
|
|
|
|
return mock
|
|
}
|