executions

package
v1.2.8 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ConcreteExecutionsScannerWFTypeName defines workflow type name for concrete executions scanner
	ConcreteExecutionsScannerWFTypeName = "cadence-sys-executions-scanner-workflow"

	// ConcreteExecutionsFixerWFTypeName defines workflow type name for concrete executions fixer
	ConcreteExecutionsFixerWFTypeName = "cadence-sys-executions-fixer-workflow"
)
View Source
const (

	// CurrentExecutionsScannerWFTypeName is the current execution scanner workflow type
	CurrentExecutionsScannerWFTypeName = "cadence-sys-current-executions-scanner-workflow"
	// CurrentExecutionsScannerTaskListName is the current execution scanner workflow tasklist
	CurrentExecutionsScannerTaskListName = "cadence-sys-current-executions-scanner-tasklist-0"

	// CurrentExecutionsFixerWFTypeName is the current execution fixer workflow ID
	CurrentExecutionsFixerWFTypeName = "cadence-sys-current-executions-fixer-workflow"

	// CurrentExecutionsFixerTaskListName is the current execution fixer workflow tasklist
	CurrentExecutionsFixerTaskListName = "cadence-sys-current-executions-fixer-tasklist-0"
)

Variables

This section is empty.

Functions

func ConcreteExecutionConfig added in v0.18.0

func ConcreteExecutionConfig(dc *dynamicconfig.Collection) *shardscanner.ScannerConfig

ConcreteExecutionConfig configures concrete execution scanner

func ConcreteFixerWorkflow added in v0.18.0

func ConcreteFixerWorkflow(ctx workflow.Context, params shardscanner.FixerWorkflowParams) error

ConcreteFixerWorkflow starts concrete executions fixer.

func ConcreteScannerWorkflow added in v0.18.0

func ConcreteScannerWorkflow(ctx workflow.Context, params shardscanner.ScannerWorkflowParams) error

ConcreteScannerWorkflow starts concrete executions scanner.

func CurrentExecutionConfig added in v0.18.0

func CurrentExecutionConfig(dc *dynamicconfig.Collection) *shardscanner.ScannerConfig

CurrentExecutionConfig configures current execution scanner

func CurrentFixerWorkflow added in v0.18.0

func CurrentFixerWorkflow(
	ctx workflow.Context,
	params shardscanner.FixerWorkflowParams,
) error

CurrentFixerWorkflow starts current executions fixer.

func CurrentScannerWorkflow added in v0.18.0

func CurrentScannerWorkflow(
	ctx workflow.Context,
	params shardscanner.ScannerWorkflowParams,
) error

CurrentScannerWorkflow is the workflow that scans over all current executions

func ParseCollections added in v0.18.0

func ParseCollections(params shardscanner.CustomScannerConfig) []invariant.Collection

ParseCollections converts string based map to list of collections

func ScanTypeStrings added in v0.16.0

func ScanTypeStrings() []string

ScanTypeStrings returns a slice of all String values of the enum

Types

type ExecutionFetcher added in v0.16.0

type ExecutionFetcher func(ctx context.Context, retryer persistence.Retryer, request fetcher.ExecutionRequest) (entity.Entity, error)

ExecutionFetcher represents a function which returns specific execution entity

type InvariantFactory added in v0.16.0

type InvariantFactory func(retryer persistence.Retryer, domainCache cache.DomainCache) invariant.Invariant

InvariantFactory represents a function which returns Invariant

type ScanType added in v0.16.0

type ScanType int

ScanType is the enum for representing different entity types to scan

const (
	// ConcreteExecutionType concrete execution entity
	ConcreteExecutionType ScanType = iota
	// CurrentExecutionType current execution entity
	CurrentExecutionType
)

func ScanTypeString added in v0.16.0

func ScanTypeString(s string) (ScanType, error)

ScanTypeString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.

func ScanTypeValues added in v0.16.0

func ScanTypeValues() []ScanType

ScanTypeValues returns all values of the enum

func (ScanType) IsAScanType added in v0.16.0

func (i ScanType) IsAScanType() bool

IsAScanType returns "true" if the value is listed in the enum definition. "false" otherwise

func (ScanType) String added in v0.16.0

func (i ScanType) String() string

func (ScanType) ToBlobstoreEntity added in v0.16.0

func (st ScanType) ToBlobstoreEntity() entity.Entity

ToBlobstoreEntity picks struct depending on scanner type.

func (ScanType) ToExecutionFetcher added in v0.16.0

func (st ScanType) ToExecutionFetcher() ExecutionFetcher

ToExecutionFetcher selects appropriate execution fetcher. Fetcher returns single execution entity. It will panic if scan type is unknown.

func (ScanType) ToInvariants added in v0.16.0

func (st ScanType) ToInvariants(collections []invariant.Collection, logger *zap.Logger) []InvariantFactory

ToInvariants returns list of invariants to be checked depending on scan type.

func (ScanType) ToIterator added in v0.16.0

func (st ScanType) ToIterator() func(ctx context.Context, retryer persistence.Retryer, pageSize int) pagination.Iterator

ToIterator selects appropriate iterator. It will panic if scan type is unknown.

Jump to

Keyboard shortcuts

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