function

package
v0.7.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 14, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Overview

Package funcmock is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApplyUDFErr

type ApplyUDFErr struct {
	UserUDFErr bool
	Message    string
	InternalErr
}

ApplyUDFErr represents any UDF related error

func (ApplyUDFErr) Error

func (e ApplyUDFErr) Error() string

func (ApplyUDFErr) IsInternalErr

func (e ApplyUDFErr) IsInternalErr() bool

IsInternalErr is true if this is a platform issue. This is a blocking error.

func (ApplyUDFErr) IsUserUDFErr

func (e ApplyUDFErr) IsUserUDFErr() bool

IsUserUDFErr is true if the problem is due to the user code in the UDF.

type InternalErr

type InternalErr struct {
	Flag        bool
	MainCarDown bool
}

InternalErr represents errors internal to the platform

type MockUserDefinedFunction_ReduceFnClient

type MockUserDefinedFunction_ReduceFnClient struct {
	// contains filtered or unexported fields
}

MockUserDefinedFunction_ReduceFnClient is a mock of UserDefinedFunction_ReduceFnClient interface.

func NewMockUserDefinedFunction_ReduceFnClient

func NewMockUserDefinedFunction_ReduceFnClient(ctrl *gomock.Controller) *MockUserDefinedFunction_ReduceFnClient

NewMockUserDefinedFunction_ReduceFnClient creates a new mock instance.

func (*MockUserDefinedFunction_ReduceFnClient) CloseAndRecv

CloseAndRecv mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) CloseSend

CloseSend mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) Context

Context mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockUserDefinedFunction_ReduceFnClient) Header

Header mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) RecvMsg

func (m *MockUserDefinedFunction_ReduceFnClient) RecvMsg(arg0 interface{}) error

RecvMsg mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) Send

Send mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) SendMsg

func (m *MockUserDefinedFunction_ReduceFnClient) SendMsg(arg0 interface{}) error

SendMsg mocks base method.

func (*MockUserDefinedFunction_ReduceFnClient) Trailer

Trailer mocks base method.

type MockUserDefinedFunction_ReduceFnClientMockRecorder

type MockUserDefinedFunction_ReduceFnClientMockRecorder struct {
	// contains filtered or unexported fields
}

MockUserDefinedFunction_ReduceFnClientMockRecorder is the mock recorder for MockUserDefinedFunction_ReduceFnClient.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) CloseAndRecv

CloseAndRecv indicates an expected call of CloseAndRecv.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) CloseSend

CloseSend indicates an expected call of CloseSend.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) Context

Context indicates an expected call of Context.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) Header

Header indicates an expected call of Header.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) RecvMsg

func (mr *MockUserDefinedFunction_ReduceFnClientMockRecorder) RecvMsg(arg0 interface{}) *gomock.Call

RecvMsg indicates an expected call of RecvMsg.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) Send

Send indicates an expected call of Send.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) SendMsg

func (mr *MockUserDefinedFunction_ReduceFnClientMockRecorder) SendMsg(arg0 interface{}) *gomock.Call

SendMsg indicates an expected call of SendMsg.

func (*MockUserDefinedFunction_ReduceFnClientMockRecorder) Trailer

Trailer indicates an expected call of Trailer.

type UDSgRPCBasedUDF added in v0.7.1

type UDSgRPCBasedUDF struct {
	// contains filtered or unexported fields
}

UDSgRPCBasedUDF applies user defined function over gRPC (over Unix Domain Socket) client/server where server is the UDF.

func NewUDSgRPCBasedUDF added in v0.7.1

func NewUDSgRPCBasedUDF(c functionsdk.Client) (*UDSgRPCBasedUDF, error)

NewUDSgRPCBasedUDF returns a new UDSgRPCBasedUDF object.

func NewUDSgRPCBasedUDFWithClient added in v0.7.1

func NewUDSgRPCBasedUDFWithClient(client functionsdk.Client) *UDSgRPCBasedUDF

NewUDSgRPCBasedUDFWithClient need this for testing

func (*UDSgRPCBasedUDF) ApplyMap added in v0.7.1

func (u *UDSgRPCBasedUDF) ApplyMap(ctx context.Context, readMessage *isb.ReadMessage) ([]*isb.Message, error)

func (*UDSgRPCBasedUDF) ApplyReduce added in v0.7.1

func (u *UDSgRPCBasedUDF) ApplyReduce(ctx context.Context, partitionID *partition.ID, messageStream <-chan *isb.ReadMessage) ([]*isb.Message, error)

ApplyReduce accepts a channel of isbMessages and returns the aggregated result

func (*UDSgRPCBasedUDF) CloseConn added in v0.7.1

func (u *UDSgRPCBasedUDF) CloseConn(ctx context.Context) error

CloseConn closes the gRPC client connection.

func (*UDSgRPCBasedUDF) IsHealthy added in v0.7.1

func (u *UDSgRPCBasedUDF) IsHealthy(ctx context.Context) error

IsHealthy checks if the udf is healthy.

func (*UDSgRPCBasedUDF) WaitUntilReady added in v0.7.1

func (u *UDSgRPCBasedUDF) WaitUntilReady(ctx context.Context) error

WaitUntilReady waits until the udf is connected.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL