grpcsrv

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2017 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type T

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

func New

func New(addr string, proxySet *proxy.Set) (*T, error)

New creates a gRPC server instance.

func (*T) Ack added in v0.13.0

func (s *T) Ack(ctx context.Context, req *pb.AckRq) (*pb.AckRs, error)

func (*T) ConsumeNAck added in v0.13.0

func (s *T) ConsumeNAck(ctx context.Context, req *pb.ConsNAckRq) (*pb.ConsRs, error)

ConsumeNAck implements pb.KafkaPixyServer

func (*T) ErrorCh

func (s *T) ErrorCh() <-chan error

ErrorCh returns an output channel that HTTP server running in another goroutine will use if it stops with error if one occurs. The channel will be closed when the server is fully stopped due to an error or otherwise..

func (*T) GetOffsets added in v0.14.0

func (s *T) GetOffsets(ctx context.Context, req *pb.GetOffsetsRq) (*pb.GetOffsetsRs, error)

func (*T) Produce

func (s *T) Produce(ctx context.Context, req *pb.ProdRq) (*pb.ProdRs, error)

Produce implements pb.KafkaPixyServer

func (*T) Start

func (s *T) Start()

Starts triggers asynchronous gRPC server start. If it fails then the error will be sent down to `ErrorCh()`.

func (*T) Stop

func (s *T) Stop()

Stop immediately stops gRPC server. So it is caller's responsibility to make sure that all pending requests are completed.

Jump to

Keyboard shortcuts

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