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 ¶
func (m SpotInterruptionMonitor) Kind() string
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
Click to show internal directories.
Click to hide internal directories.