daemon

package
v3.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WaitForServerReady

func WaitForServerReady(serverAddr string, insecureSkipVerify bool) error

WaitForServerReady waits until the HTTP(S) server can respond to a GET request. Should NOT allow cancelling the retry as shuting down non-ready server may cause deadlock.

Types

type Daemon

type Daemon interface {
	// Start starts the daemon and creates required background go routines synchronously
	Start(ctx context.Context) error

	// Shutdown shutdown the daemon gracefully and synchronously
	Shutdown()
}

type NewDaemonFunc

type NewDaemonFunc func(ctx context.Context, idCfg *config.IdentityConfig) (Daemon, error)

NewDaemonFunc defines the New() function. New() creates and initializes the daemon synchronously. New should stop processing gracefully when the context is cancelled.

Jump to

Keyboard shortcuts

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