parallelmodulerun

package
v1.21.21 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2026 License: Apache-2.0 Imports: 17 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterTaskHandler

func RegisterTaskHandler(svc TaskDependencies) func(t sh_task.Task, logger *log.Logger) task.Task

RegisterTaskHandler creates a factory function for ParallelModuleRun tasks

Types

type Task

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

Task handles running multiple module tasks in parallel

func NewTask

func NewTask(
	shellTask sh_task.Task,
	moduleManager *module_manager.ModuleManager,
	queueService *taskqueue.Service,
	parallelTaskChannels *paralleltask.TaskChannels,
	logger *log.Logger,
) *Task

NewTask creates a new task handler for parallel module execution

func (*Task) CreateAndStartQueuesForModuleHooks

func (s *Task) CreateAndStartQueuesForModuleHooks(moduleName string)

CreateAndStartQueuesForModuleHooks creates queues for registered module hooks. It is safe to run this method multiple times, as it checks for existing queues.

func (*Task) Handle

func (s *Task) Handle(ctx context.Context) queue.TaskResult

Handle runs multiple ModuleRun tasks in parallel and aggregates their results. It creates tasks for each module in separate parallel queues, then monitors their completion through a communication channel.

type TaskDependencies

type TaskDependencies interface {
	GetModuleManager() *module_manager.ModuleManager
	GetQueueService() *taskqueue.Service
	GetParallelTaskChannels() *paralleltask.TaskChannels
}

TaskDependencies defines the interface for accessing necessary components

Jump to

Keyboard shortcuts

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