add operator for allocateMemory.available signal

This commit is contained in:
Pingan2017 2020-12-24 10:04:09 +08:00
parent 9858bc2925
commit 2f76666ff4

View File

@ -58,12 +58,13 @@ const (
// from either above or below, never both). There is thus no reason to expose the // from either above or below, never both). There is thus no reason to expose the
// operator in the Kubelet's public API. Instead, we internally map signal types to operators. // operator in the Kubelet's public API. Instead, we internally map signal types to operators.
var OpForSignal = map[Signal]ThresholdOperator{ var OpForSignal = map[Signal]ThresholdOperator{
SignalMemoryAvailable: OpLessThan, SignalMemoryAvailable: OpLessThan,
SignalNodeFsAvailable: OpLessThan, SignalNodeFsAvailable: OpLessThan,
SignalNodeFsInodesFree: OpLessThan, SignalNodeFsInodesFree: OpLessThan,
SignalImageFsAvailable: OpLessThan, SignalImageFsAvailable: OpLessThan,
SignalImageFsInodesFree: OpLessThan, SignalImageFsInodesFree: OpLessThan,
SignalPIDAvailable: OpLessThan, SignalAllocatableMemoryAvailable: OpLessThan,
SignalPIDAvailable: OpLessThan,
} }
// ThresholdValue is a value holder that abstracts literal versus percentage based quantity // ThresholdValue is a value holder that abstracts literal versus percentage based quantity