submitter

package
v0.0.0-...-55e4108 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2019 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DeleteEvent

type DeleteEvent struct {
	PodName      string
	PodNamespace string
}

DeleteEvent represents an event of deleting a pod from a cluster.

func (*DeleteEvent) IsSubmitterEvent

func (d *DeleteEvent) IsSubmitterEvent() bool

type Event

type Event interface {
	IsSubmitterEvent() bool
}

Event defines the interface of a submitter event. Submit can returns any type in a list that implements this interface.

type SubmitEvent

type SubmitEvent struct {
	Pod *v1.Pod
}

SubmitEvent represents an event of submitting a pod to a cluster.

func (*SubmitEvent) IsSubmitterEvent

func (s *SubmitEvent) IsSubmitterEvent() bool

type Submitter

type Submitter interface {
	// Submit submits pods to a simulated cluster.
	// The return value is a list of submitter events.
	// Submitters are called serially in the same order that they are registered to the simulated
	// cluster.
	// This method must never block.
	Submit(
		clock clock.Clock,
		nodeLister algorithm.NodeLister,
		metrics metrics.Metrics) ([]Event, error)
}

Submitter defines the submitter interface.

type TerminateSubmitterEvent

type TerminateSubmitterEvent struct {
}

TerminateSubmitterEvent represents an event of terminating the submission process.

func (*TerminateSubmitterEvent) IsSubmitterEvent

func (t *TerminateSubmitterEvent) IsSubmitterEvent() bool

type UpdateEvent

type UpdateEvent struct {
	PodName      string
	PodNamespace string
	NewPod       *v1.Pod
}

UpdateEvent represents an event of updating the manifest of a pending pod.

func (*UpdateEvent) IsSubmitterEvent

func (u *UpdateEvent) IsSubmitterEvent() bool

Jump to

Keyboard shortcuts

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