internal

package
v0.1442.0 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const MAX_RESULT_SIZE = 1024 * 50
View Source
const TaskCompletionReasonFailedToFetchResult = "failed to fetch result"
View Source
const TaskCompletionReasonFailedToRunContainer = "failed to run container"
View Source
const TaskCompletionReasonInvalidTransition = "invalid state transition"
View Source
const TaskCompletionReasonMissingContainer = "task container does not exist"

Variables

View Source
var ErrResultFileTooLarge = errors.New(
	fmt.Sprintf("result file is too large (over %d bytes)", MAX_RESULT_SIZE),
)

Functions

This section is empty.

Types

type ContainerDelegate

type ContainerDelegate interface {
	GetContainer(logger lager.Logger, guid string) (executor.Container, bool)
	RunContainer(logger lager.Logger, traceID string, req *executor.RunRequest) bool
	StopContainer(logger lager.Logger, traceID string, guid string) bool
	DeleteContainer(logger lager.Logger, traceID string, guid string) bool
	FetchContainerResultFile(logger lager.Logger, guid string, filename string) (string, error)
}

func NewContainerDelegate

func NewContainerDelegate(client executor.Client) ContainerDelegate

type LRPProcessor

type LRPProcessor interface {
	Process(lager.Logger, string, executor.Container)
}

func NewLRPProcessor

func NewLRPProcessor(
	bbsClient bbs.InternalClient,
	containerDelegate ContainerDelegate,
	metronClient loggingclient.IngressClient,
	cellID string,
	availabilityZone string,
	stackPathMap rep.StackPathMap,
	layeringMode string,
	evacuationReporter evacuation_context.EvacuationReporter,
) LRPProcessor

type TaskProcessor

type TaskProcessor interface {
	Process(lager.Logger, string, executor.Container)
}

func NewTaskProcessor

func NewTaskProcessor(bbs bbs.InternalClient, containerDelegate ContainerDelegate, cellID string, stackPathMap rep.StackPathMap, layeringMode string) TaskProcessor

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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