spotitn

package
v1.13.4 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// SpotITNKind is a const to define a Spot ITN kind of interruption event
	SpotITNKind = "SPOT_ITN"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type SpotInterruptionMonitor

type SpotInterruptionMonitor struct {
	IMDS             *ec2metadata.Service
	InterruptionChan chan<- monitor.InterruptionEvent
	CancelChan       chan<- monitor.InterruptionEvent
	NodeName         string
}

SpotInterruptionMonitor is a struct definition which facilitates monitoring of spot ITNs from IMDS

func NewSpotInterruptionMonitor

func NewSpotInterruptionMonitor(imds *ec2metadata.Service, interruptionChan chan<- monitor.InterruptionEvent, cancelChan chan<- monitor.InterruptionEvent, nodeName string) SpotInterruptionMonitor

NewSpotInterruptionMonitor creates an instance of a spot ITN IMDS monitor

func (SpotInterruptionMonitor) Kind

Kind denotes the kind of event that is processed

func (SpotInterruptionMonitor) Monitor

func (m SpotInterruptionMonitor) Monitor() error

Monitor continuously monitors metadata for spot ITNs and sends interruption events to the passed in channel

Jump to

Keyboard shortcuts

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