migrator

package
v0.30.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// EventJobFailed is sent when a job fails.
	EventJobFailed = "Migration Job Failed"
	// EventJobCompleted is sent when a job completes successfully.
	EventJobCompleted = "Migration Job Completed"
	// EventUpdateJobStateFailed is sent when updating a job state fails.
	EventUpdateJobStateFailed = "Failed to update job state"
	// EventUpdateTaskStateFailed is sent when updating a task state fails.
	EventUpdateTaskStateFailed = "Failed to update task state"
)

Variables

This section is empty.

Functions

func NewDefaultMigrator

func NewDefaultMigrator(cfg *config.Config, jobService application.JobService, appClients *clients.ClientList, slackClient slack.Clienter, topicCache *cache.TopicCache) (*migrator, error)

NewDefaultMigrator creates a new default migrator with the provided job service and clients. topicCache must not be nil.

Types

type Migrator

type Migrator interface {
	Shutdown(ctx context.Context) error
	Start(ctx context.Context)
}

Migrator defines the contract for migration operations

type StateTransitionRule added in v0.22.0

type StateTransitionRule struct {
	// TaskTargetState is the state all tasks must reach
	TaskTargetState domain.State
	// JobTargetState is the state the job should transition to
	JobTargetState domain.State
	// Description explains the rule
	Description string
}

StateTransitionRule defines when a job should transition based on task states

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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