Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNilAppStatusHandler = errors.New("appStatusHandler is nil")
ErrNilAppStatusHandler will be returned when the AppStatusHandler is nil
View Source
var ErrNilHandlerFunc = errors.New("handler function is nil")
ErrNilHandlerFunc will be returned when the handler function is nil
View Source
var ErrPollingDurationToSmall = errors.New("polling duration it's to small")
ErrPollingDurationToSmall will be returned when the polling duration is to small
Functions ¶
This section is empty.
Types ¶
type AppStatusPolling ¶
type AppStatusPolling struct {
// contains filtered or unexported fields
}
AppStatusPolling will update an AppStatusHandler by polling components at a predefined interval
func NewAppStatusPolling ¶
func NewAppStatusPolling(appStatusHandler core.AppStatusHandler, pollingDuration time.Duration, logger core.Logger) (*AppStatusPolling, error)
NewAppStatusPolling will return an instance of AppStatusPolling
func (*AppStatusPolling) Poll ¶
func (asp *AppStatusPolling) Poll(ctx context.Context)
Poll will notify the AppStatusHandler at a given time
func (*AppStatusPolling) RegisterPollingFunc ¶
func (asp *AppStatusPolling) RegisterPollingFunc(handler func(appStatusHandler core.AppStatusHandler)) error
RegisterPollingFunc will register a new handler function
Click to show internal directories.
Click to hide internal directories.