tasks

package
v0.0.0-...-ac6a2c4 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service interface {
	// Dequeue fetches some tasks from the service.
	Dequeue(ctx context.Context, taskType resmgr.TaskType, batchSize int, timeout int) (assignments []models.Task)

	// SetPlacements sets successful and unsuccessful placements back to the service.
	SetPlacements(
		ctx context.Context,
		successFullPlacements []models.Task,
		failedAssignments []models.Task,
	)
}

Service will manage gangs/tasks and placements used by any placement strategy.

func NewService

func NewService(
	resourceManager resmgrsvc.ResourceManagerServiceYARPCClient,
	cfg *config.PlacementConfig,
	metrics *metrics.Metrics) Service

NewService will create a new task service.

Jump to

Keyboard shortcuts

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