serv

package
v0.0.0-...-e77dc18 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2022 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Logger

type Logger interface {
	Debug(args ...interface{})
	Info(args ...interface{})
	Error(args ...interface{})
	Fatal(args ...interface{})
	Debugf(format string, args ...interface{})
	Infof(format string, args ...interface{})
	Errorf(format string, args ...interface{})
	Fatalf(format string, args ...interface{})
}

Logger ...

type Option

type Option func(*Serv)

Option ...

func WithDebugPort

func WithDebugPort(portPrivateHTTP string) Option

WithDebugPort ...

func WithGRPC

func WithGRPC(ctx context.Context, cfg *configs.Configs, handler handler, fns ...func(*grpc.Server)) Option

WithGRPC ...

func WithLogger

func WithLogger(l Logger) Option

WithLogger ...

func WithPublicPort

func WithPublicPort(portPublicHTTP string) Option

WithPublicPort ...

func WithSwaggerUI

func WithSwaggerUI(on bool) Option

WithSwaggerUI ...

type Serv

type Serv struct {
	Logger Logger
	// contains filtered or unexported fields
}

Serv ...

func New

func New(ctx context.Context, opts ...Option) *Serv

New ...

func (*Serv) Run

func (s *Serv) Run(ctx context.Context, handles http.Handler, logger hclog.Logger, RegisterEndpointFns ...func(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) error)

Run ...

Jump to

Keyboard shortcuts

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