strategy

package
v0.0.0-...-c009273 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UpdateDeploymentStep

func UpdateDeploymentStep[I any, O any](steps StepSet[I, O], result *drss_pb.StepResult, outputData O) error

func UpdateStepDependencies

func UpdateStepDependencies[I any, O any](stepMap StepSet[I, O]) error

Types

type DoneOutcome

type DoneOutcome[O any] struct {
	Output O
}

type EventOutput

type EventOutput[O any] interface {
	GetOutput() O
	GetStepId() string
	GetStatus() drss_pb.StepStatus
	GetError() *string
}

type Outcome

type Outcome[O any] interface {
	// contains filtered or unexported methods
}

type RequestOutcome

type RequestOutcome struct {
	Request SideEffect
}

type SideEffect

type SideEffect interface {
	GetRequest() *messaging_j5pb.RequestMetadata
	SetJ5RequestMetadata(*messaging_j5pb.RequestMetadata)
	o5msg.Message
}

type Step

type Step[T any, O any] interface {
	GetMeta() *drss_pb.StepMeta
	GetOutput() O
	SetOutput(O)
	GetStep() T
}

type StepBatonImpl

type StepBatonImpl[I any, O any] struct {
	// contains filtered or unexported fields
}

func NewStepBaton

func NewStepBaton[I any, O any](step Step[I, O], deps map[string]Step[I, O]) *StepBatonImpl[I, O]

func (*StepBatonImpl[I, O]) Done

func (ds *StepBatonImpl[I, O]) Done()

func (*StepBatonImpl[I, O]) GetDependency

func (ds *StepBatonImpl[I, O]) GetDependency(id string) (dep O, ok bool)

func (*StepBatonImpl[I, O]) GetID

func (ds *StepBatonImpl[I, O]) GetID() string

func (*StepBatonImpl[I, O]) SideEffect

func (ds *StepBatonImpl[I, O]) SideEffect(effect SideEffect)

type StepNextOutcome

type StepNextOutcome int
const (
	StepNextWait StepNextOutcome = iota
	StepNextFail
	StepNextDone
	StepNextDeadlock
)

func StepNext

func StepNext[I any, O any](stepMap StepSet[I, O], start func(string)) (StepNextOutcome, error)

type StepSet

type StepSet[I any, O any] map[string]Step[I, O]

func (StepSet[I, O]) BuildBaton

func (ss StepSet[I, O]) BuildBaton(stepID string) (Step[I, O], *StepBatonImpl[I, O], error)

Jump to

Keyboard shortcuts

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