shutdown

package
v0.0.1-20220801-0001 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2022 License: MIT Imports: 11 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var WaitFinished, WaitCancel = context.WithCancel(context.Background())

var WaitFinished = make(chan bool) TODO: should be set here the default context instead of the background?!

Functions

func GracefullShutdown

func GracefullShutdown(
	callback func() error,
	teardown func(context.Context) error,
) error

func MonitorSigMessages

func MonitorSigMessages(onShutdown ...func())

MonitorSigMessages -> receives the signal of termination, and reacts based on this It should call the Cancel Context, and the entire app should terminate gracefully

Types

This section is empty.

Jump to

Keyboard shortcuts

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