grpc

package
v4.0.0-alpha1 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2022 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(ctx context.Context, opt ...Option) server.Server

New creates the generic grpc.Server

func NewWithServer

func NewWithServer(ctx context.Context, s *grpc.Server, listen string) server.Server

NewWithServer can pass preset grpc.Server with custom listen address

Types

type Handler added in v4.0.1

type Handler struct{}

func (*Handler) Check added in v4.0.1

func (*Handler) Watch added in v4.0.1

type Option

type Option func(*Options)

func WithListener

func WithListener(lis net.Listener) Option

type Options

type Options struct {
	Listener net.Listener
}

type Server

type Server struct {
	*grpc.Server
	// contains filtered or unexported fields
}

func (*Server) Address

func (s *Server) Address() []string

func (*Server) As

func (s *Server) As(i interface{}) bool

func (*Server) Endpoints

func (s *Server) Endpoints() []string

func (*Server) ID

func (s *Server) ID() string

func (*Server) Metadata

func (s *Server) Metadata() map[string]string

func (*Server) Name

func (s *Server) Name() string

func (*Server) Serve

func (s *Server) Serve() error

func (*Server) Stop

func (s *Server) Stop() error

func (*Server) Type

func (s *Server) Type() server.ServerType

Jump to

Keyboard shortcuts

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