flow

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2024 License: MIT Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrFlowNotFound          = fmt.Errorf("flow not found")
	ErrProcessorNotFound     = fmt.Errorf("processor not found")
	ErrLastProcessorNotFound = fmt.Errorf("last processor not found")
)

Functions

func NewInMemoryFlowManager added in v0.1.0

func NewInMemoryFlowManager() definitions.FlowManager

Types

type InMemoryFlowManager added in v0.1.0

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

func (*InMemoryFlowManager) AddProcessorToFlowAfter added in v0.1.0

func (fm *InMemoryFlowManager) AddProcessorToFlowAfter(flowID uuid.UUID, processor *definitions.SimpleProcessor, referenceProcessorID uuid.UUID) error

AddProcessorToFlowAfter adds a processor after the reference processor.

func (*InMemoryFlowManager) AddProcessorToFlowBefore added in v0.1.0

func (fm *InMemoryFlowManager) AddProcessorToFlowBefore(flowID uuid.UUID, processor *definitions.SimpleProcessor, referenceProcessorID uuid.UUID) error

AddProcessorToFlowBefore adds a processor before the reference processor by adjusting NextProcessorIDs.

func (*InMemoryFlowManager) GetFirstProcessorsForFlow added in v0.1.0

func (fm *InMemoryFlowManager) GetFirstProcessorsForFlow(flowID uuid.UUID) ([]definitions.SimpleProcessor, error)

GetFirstProcessorsForFlow retrieves processors that are not referenced as "next processors".

func (*InMemoryFlowManager) GetFlowByID added in v0.1.0

func (fm *InMemoryFlowManager) GetFlowByID(flowID uuid.UUID) (*definitions.Flow, error)

GetFlowByID retrieves a flow by its unique identifier.

func (*InMemoryFlowManager) GetFlowProcessors added in v0.1.0

func (fm *InMemoryFlowManager) GetFlowProcessors(flowID uuid.UUID) ([]definitions.SimpleProcessor, error)

GetFlowProcessors retrieves all processors for a given flow.

func (*InMemoryFlowManager) GetLastUpdateTime added in v0.1.0

func (fm *InMemoryFlowManager) GetLastUpdateTime(flowIDs []uuid.UUID) (map[uuid.UUID]time.Time, error)

GetLastUpdateTime retrieves the last update time for the given flow IDs.

func (*InMemoryFlowManager) GetNextProcessors added in v0.1.0

func (fm *InMemoryFlowManager) GetNextProcessors(flowID uuid.UUID, processorID uuid.UUID) ([]definitions.SimpleProcessor, error)

GetNextProcessors retrieves processors referenced in the NextProcessorIDs of the specified processor.

func (*InMemoryFlowManager) GetProcessorByID added in v0.1.0

func (fm *InMemoryFlowManager) GetProcessorByID(flowID uuid.UUID, processorID uuid.UUID) (*definitions.SimpleProcessor, error)

GetProcessorByID retrieves a processor by its ID within a flow.

func (*InMemoryFlowManager) GetProcessors added in v0.1.0

func (fm *InMemoryFlowManager) GetProcessors(processorIDs []uuid.UUID) ([]definitions.SimpleProcessor, error)

GetProcessors retrieves processors by their unique identifiers.

func (*InMemoryFlowManager) GetTriggerProcessorsForFlow added in v0.1.0

func (fm *InMemoryFlowManager) GetTriggerProcessorsForFlow(flowID uuid.UUID) ([]*definitions.SimpleTriggerProcessor, error)

GetTriggerProcessorsForFlow retrieves the trigger processors for the specified flow.

func (*InMemoryFlowManager) ListFlows added in v0.1.0

ListFlows lists flows with pagination and a time filter.

func (*InMemoryFlowManager) SaveFlow added in v0.1.0

func (fm *InMemoryFlowManager) SaveFlow(flow *definitions.Flow) error

SaveFlow saves the flow and its processors.

func (*InMemoryFlowManager) SetFlowActive added in v0.1.0

func (fm *InMemoryFlowManager) SetFlowActive(flowID uuid.UUID, active bool) error

SetFlowActive marks a flow as active or inactive.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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