grpcx

package
v0.0.0-...-5a780e0 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2024 License: GPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is the grpc client

func NewClient

func NewClient(config *configx.Configuration) (*Client, error)

NewClient is used to create a new grpc client

func (*Client) Dial

func (c *Client) Dial(service string) (*grpc.ClientConn, error)

Dial is used to dial the grpc service

type InitServers

type InitServers func(s *grpc.Server)

InitServers define register handler

type Server

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

Server represents the grpc server.

func NewServer

func NewServer(app *configx.Application, init InitServers) (*Server, error)

NewServer creates a new grpc server.

func (*Server) GetAddr

func (s *Server) GetAddr() string

GetAddr returns the server address.

func (*Server) Start

func (s *Server) Start(ctx contextx.Contextx) error

Start begins the server.

func (*Server) Stop

func (s *Server) Stop(ctx contextx.Contextx) error

Stop stops the server.

Jump to

Keyboard shortcuts

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