manager

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2021 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ProviderSet = wire.NewSet(NewManager)

Functions

func Push added in v0.1.5

func Push(judgement *models.Judgement, block *engine.Block, inputs *models.Slots) <-chan *models.Slots

Types

type Handler

type Handler interface {
	IsMatched(tp string) bool
	Work(runtime *ProcessRuntime) error
}

type ProcessManager

type ProcessManager interface {
	Push(judgement *models.Judgement, block *engine.Block, inputs *models.Slots) <-chan *models.Slots
	Fetch(judgementId, processId, processType string, ignoreLock bool) *ProcessRuntime
	Finish(element *ProcessRuntime, slots *models.Slots) error
	FinishWithError(element *ProcessRuntime, message string) error
	Reserve(element *ProcessRuntime) bool
}

func NewManager

func NewManager(logger *zap.Logger, ins []Handler) ProcessManager

type ProcessRuntime added in v0.0.25

type ProcessRuntime struct {
	Mutex     *sync.Mutex
	Judgement *models.Judgement
	Process   *models.Process
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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