lib

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2025 License: Apache-2.0 Imports: 19 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckImpact added in v0.8.0

func CheckImpact(triggerList []*triggers.Trigger) (highImpact, reboot bool)

CheckImpact will return whether any trigger has high impact or will reboot.

func MatchTriggersInUpdate added in v0.4.0

func MatchTriggersInUpdate(request sub.UpdateRequest) []*triggers.Trigger

MatchTriggersInUpdate will return a list of triggers in an update request that match the list of changes. Since there is no file-system to compare to, potential mtime-only changes will also match.

func Update

func Update(request sub.UpdateRequest, rootDirectoryName string,
	objectsDir string, oldTriggers *triggers.Triggers,
	skipFilter *filter.Filter, triggersRunner TriggersRunner,
	logger log.Logger) (
	bool, time.Duration, error)

Update is deprecated. Use UpdateWithOptions instead.

func UpdateWithOptions added in v0.3.2

func UpdateWithOptions(request sub.UpdateRequest, options UpdateOptions) (
	bool, time.Duration, error)

UpdateWithOptions will process an update request, modifying the local file-system and running triggers.

Types

type DisruptionCancelor added in v0.3.2

type DisruptionCancelor func()

type DisruptionRequestor added in v0.3.2

type DisruptionRequestor func() sub.DisruptionState

type TriggersRunner

type TriggersRunner func(triggers []*triggers.Trigger, action string,
	logger log.Logger) bool

type UpdateOptions added in v0.3.2

type UpdateOptions struct {
	DisruptionCancel  DisruptionCancelor
	DisruptionRequest DisruptionRequestor
	Logger            log.Logger
	ObjectsDir        string
	OldTriggers       *triggers.Triggers
	RootDirectoryName string
	RunTriggers       TriggersRunner
	SkipFilter        *filter.Filter
}

Jump to

Keyboard shortcuts

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