client

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewStream

func NewStream(
	ctx context.Context,
	id uint64,
	method string,
	rw types.RpcReadWriter,
	teardown func(),
	sourceAddress, destAddress string,
	statsHandlers []stats.Handler,
	beginTime time.Time,
) grpc.ClientStream

Types

type RpcMultiplexer

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

func NewRpcMultiplexer

func NewRpcMultiplexer(rw types.RpcReadWriter) *RpcMultiplexer

func (*RpcMultiplexer) CallUnaryMethod

func (rm *RpcMultiplexer) CallUnaryMethod(
	ctx context.Context,
	header *goatorepo.RequestHeader,
	body *goatorepo.Body,
	statsHandlers []stats.Handler,
) (*goatorepo.Body, error)

func (*RpcMultiplexer) Close

func (rm *RpcMultiplexer) Close()

func (*RpcMultiplexer) NewStreamReadWriter

func (rm *RpcMultiplexer) NewStreamReadWriter(
	ctx context.Context,
) (uint64, types.RpcReadWriter, func(), error)

NewStreamReadWriter returns a new goat.RpcReadWriter which will read and write Rpcs using the returned id. Also returns a teardown function which will close the stream.

Jump to

Keyboard shortcuts

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