component

package
v0.0.0-...-a864060 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2018 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GrpcClient

func GrpcClient(conn *grpc.ClientConn) interface{}

GrpcClient returns a grpc client

Types

type ServiceInitializer

type ServiceInitializer struct {
}

func (*ServiceInitializer) InitService

func (i *ServiceInitializer) InitService(s turbo.Servable) error

InitService is run before the service is started, do initializing staffs for your service here. For example, init turbo components, such as interceptors, pre/postprocessors, errorHandlers, etc.

func (*ServiceInitializer) StopService

func (i *ServiceInitializer) StopService(s turbo.Servable)

StopService is run after both grpc server and http server are stopped, do your cleaning up work here.

Jump to

Keyboard shortcuts

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