workflow

package
v0.1.21 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Option

type Option func(*Service)

func WithMetaService

func WithMetaService(meta *meta.Service) Option

WithMetaService sets the meta service

func WithRootTaskNodeName

func WithRootTaskNodeName(name string) Option

WithRootTaskNodeName sets the root task node name

type Service

type Service struct {
	// contains filtered or unexported fields
}

func New

func New(opts ...Option) *Service

New creates a new workflow service instance

func (*Service) DecodeYAML

func (s *Service) DecodeYAML(encoded []byte) (*model.Workflow, error)

DecodeYAML decodes a workflow from YAML

func (*Service) Load

func (s *Service) Load(ctx context.Context, URL string) (*model.Workflow, error)

Load loads a workflow from YAML at the specified Location

func (*Service) ParseWorkflow

func (s *Service) ParseWorkflow(URL string, node *yaml.Node) (*model.Workflow, error)

func (*Service) Refresh added in v0.1.19

func (s *Service) Refresh(location string)

Refresh discards any cached copy of the workflow definition identified by the provided location. The next Load call will reload the file via the meta-service.

func (*Service) RootTaskNodeName

func (s *Service) RootTaskNodeName() string

RootTaskNodeName returns the root task node name

func (*Service) Upsert added in v0.1.19

func (s *Service) Upsert(location string, wf *model.Workflow)

Upsert stores the supplied workflow definition in the cache under the given location, replacing any existing entry.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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