Documentation
¶
Index ¶
Constants ¶
View Source
const ( // DefaultRefreshDelay pool monitor poll delay default in seconds. DefaultRefreshDelay = 1 * time.Second // DefaultMaxIPs default maximum allocatable IPs DefaultMaxIPs = 250 )
Variables ¶
This section is empty.
Functions ¶
func CalculateMaxFreeIPs ¶
CalculateMaxFreeIPs calculates the maximum free IP quantity based on the Scaler in the passed NodeNetworkConfig.
func CalculateMinFreeIPs ¶
CalculateMinFreeIPs calculates the minimum free IP quantity based on the Scaler in the passed NodeNetworkConfig.
Types ¶
type Monitor ¶
type Monitor struct {
// contains filtered or unexported fields
}
func NewMonitor ¶
func NewMonitor(httpService cns.HTTPService, nnccli nodeNetworkConfigSpecUpdater, opts *Options) *Monitor
func (*Monitor) GetStateSnapshot ¶
func (pm *Monitor) GetStateSnapshot() cns.IpamPoolMonitorStateSnapshot
GetStateSnapshot gets a snapshot of the IPAMPoolMonitor struct.
func (*Monitor) Update ¶
func (pm *Monitor) Update(nnc *v1alpha.NodeNetworkConfig)
Update ingests a NodeNetworkConfig, clamping some values to ensure they are legal and then pushing it to the Monitor's source channel.
Click to show internal directories.
Click to hide internal directories.