spotitn

package
v1.20.0 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const SpotITNMonitorKind = "SPOT_ITN_MONITOR"

SpotITNMonitorKind is a const to define this monitor kind

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 monitor

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