taskrunner

package
v0.0.0-...-ee3d319 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2018 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// "dispatch starts agents on free hosts"
	RunnerName = "taskrunner"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AgentHostGateway

type AgentHostGateway struct {
	// Destination directory for the agent executables
	ExecutablesDir string
}

Implementation of the HostGateway that builds and copies over the MCI agent to run tasks.

func (*AgentHostGateway) StartAgentOnHost

func (agbh *AgentHostGateway) StartAgentOnHost(ctx context.Context, settings *evergreen.Settings, hostObj host.Host) error

Start an agent on the host specified. First runs any necessary preparation on the remote machine, then kicks off the agent process on the machine. Returns an error if any step along the way fails.

type HostGateway

type HostGateway interface {
	// run the specified task on the specified host, return the revision of the
	// agent running the task on that host
	StartAgentOnHost(context.Context, *evergreen.Settings, host.Host) error
}

HostGateway is responsible for kicking off tasks on remote machines.

type Runner

type Runner struct{}

func (*Runner) Name

func (r *Runner) Name() string

func (*Runner) Run

func (r *Runner) Run(ctx context.Context, config *evergreen.Settings) error

type TaskRunner

type TaskRunner struct {
	*evergreen.Settings
	HostGateway
}

TODO: take out task queue finder and host finder once transition is complete

func NewTaskRunner

func NewTaskRunner(settings *evergreen.Settings) *TaskRunner

func (*TaskRunner) Run

func (tr *TaskRunner) Run(ctx context.Context) error

Jump to

Keyboard shortcuts

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