taskmanager

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TaskManager

type TaskManager struct {
	DryRun bool
	// contains filtered or unexported fields
}

TaskManager is a wrapper for executing processes.

func NewTaskManager

func NewTaskManager(dryRun bool) *TaskManager

NewTaskManager creates a new TaskManager.

func (*TaskManager) DeletePid

func (tm *TaskManager) DeletePid(pid int)

DeletePid deletes the specified pid from the internal map.

func (*TaskManager) Run

func (tm *TaskManager) Run(
	ctx context.Context,
	args []string,
	stdIn io.Reader,
	stdOut io.Writer,
	stdErr io.Writer,
	cmdDir string) error

Run runs a command based on the specified params.

func (*TaskManager) Stop

func (tm *TaskManager) Stop() util.Errors

Stop stops the task manager and tries to kill any running processes.

Jump to

Keyboard shortcuts

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