preprocessing

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Enable preprocessing child workflow.
	Enabled bool
	// Extract package in preprocessing.
	Extract bool
	// Local path shared between workers.
	SharedPath string
	// Temporal configuration.
	Temporal Temporal
}

func (Config) Validate

func (c Config) Validate() error

Validate implements config.ConfigurationValidator.

type Outcome

type Outcome int
const (
	OutcomeSuccess Outcome = iota
	OutcomeSystemError
	OutcomeContentError
)

type Task

type Task struct {
	// Name is the name of the task.
	Name string

	// Message is a human readable description of the task operations or result.
	Message string

	// Outcome indicates the completion state of the task.
	Outcome enums.PreprocessingTaskOutcome

	// StartedAt is the timestamp of the task initiation.
	StartedAt time.Time

	// StartedAt is the timestamp of the task completion.
	CompletedAt time.Time
}

type Temporal

type Temporal struct {
	Namespace    string
	TaskQueue    string
	WorkflowName string
}

type WorkflowParams

type WorkflowParams struct {
	// Relative path to the shared path.
	RelativePath string
}

type WorkflowResult

type WorkflowResult struct {
	// Outcome is an integer indicating if the workflow completed successfully,
	// or with errors.
	Outcome Outcome

	// Relative path to the shared path.
	RelativePath string

	// PreservationTasks is a log of the preservation tasks performed by
	// preprocessing.
	PreservationTasks []Task
}

Jump to

Keyboard shortcuts

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