Documentation ¶ Index ¶ Variables type Manager func New(opts ...Option) Manager type Option type Options type Runnable type Server func (e *Server) Add(r ...Runnable) func (e *Server) Start(ctx context.Context) (err error) Constants ¶ This section is empty. Variables ¶ View Source var Manage = New() Manage server Functions ¶ This section is empty. Types ¶ type Manager ¶ type Manager interface { Add(...Runnable) Start(context.Context) error } Manager server manage func New ¶ func New(opts ...Option) Manager New 实例化 type Option ¶ type Option func(*Options) Option set Options type Options ¶ type Options struct { // contains filtered or unexported fields } Options options type Runnable ¶ type Runnable interface { fmt.Stringer // Start 启动 Start(ctx context.Context) error } Runnable runnable type Server ¶ type Server struct { // contains filtered or unexported fields } Server server func (*Server) Add ¶ func (e *Server) Add(r ...Runnable) Add add runnable func (*Server) Start ¶ func (e *Server) Start(ctx context.Context) (err error) Start start runnable Source Files ¶ View all Source files default.gomanager.gooptions.goserver.go Directories ¶ Show internal Expand all Path Synopsis grpc interceptors/logging interceptors/logging/ctxlog interceptors/request_tag listener task Click to show internal directories. Click to hide internal directories.