processfx

package
v0.6.32 Latest Latest
Warning

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

Go to latest
Published: May 27, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultShutdownTimeout = 30 * time.Second
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Process

type Process struct {
	BaseCtx context.Context //nolint:containedctx

	Ctx    context.Context //nolint:containedctx
	Logger *logfx.Logger

	Cancel context.CancelFunc

	Signal chan os.Signal

	WaitGroups map[string]*sync.WaitGroup

	ShutdownTimeout time.Duration
}

func New

func New(baseCtx context.Context, logger *logfx.Logger) *Process

func (*Process) Shutdown

func (p *Process) Shutdown()

func (*Process) StartGoroutine

func (p *Process) StartGoroutine(name string, fn func(ctx context.Context) error)

func (*Process) Wait

func (p *Process) Wait()

Jump to

Keyboard shortcuts

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