Documentation
¶
Index ¶
- Variables
- func Bootstrap(activeFunc func())
- func Destroy(cancel context.CancelFunc) (err error)
- func Exit() error
- func ExitWithTimeout(d time.Duration) error
- func ForceExit() error
- func ListenAndDestroy(cancel context.CancelFunc) error
- func RegisterHandler(seq int, name string, handler func(ctx *context.Context) Handler)
- func Startup(rootCtx *context.Context) error
- type DestroyUnit
- type Handler
- type Root
- type Unit
Constants ¶
This section is empty.
Variables ¶
View Source
var Log *log.Logger
Functions ¶
func Destroy ¶
func Destroy(cancel context.CancelFunc) (err error)
Destroy unregister all services immediately after calling
Deprecated
func Exit ¶
func Exit() error
Exit unregister all services immediately after calling
this func can only be called when ListenAndDestroy is used, otherwise an error will be return
Deprecated
func ListenAndDestroy ¶
func ListenAndDestroy(cancel context.CancelFunc) error
ListenAndDestroy
Deprecated
func RegisterHandler ¶
Types ¶
type DestroyUnit ¶
type Root ¶ added in v1.1.0
type Root struct {
Context context.Context
CancelFunc context.CancelFunc
// contains filtered or unexported fields
}
func (*Root) ListenAndDestroy ¶ added in v1.1.0
Click to show internal directories.
Click to hide internal directories.