shutdown

package
v0.16.2 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ChildProcReaper added in v0.16.0

func ChildProcReaper(ctx context.Context, logger logrus.FieldLogger) context.Context

ChildProcReaper spawns a goroutine to listen for SIGCHLD signals to cleanup zombie child processes. The returned context will be canceled once all child processes have been cleaned up, and should be waited on before exiting.

This only applies to Unix platforms, and returns an already canceled context on Windows.

func GetSignals

func GetSignals() []os.Signal

GetSignals returns the appropriate signals to catch for a clean shutdown, dependent on the OS.

On Unix-like operating systems, it is important to catch SIGTERM in addition to SIGINT.

Types

This section is empty.

Jump to

Keyboard shortcuts

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