Documentation ¶
Index ¶
- Variables
- func GetCloudTaint(taints []v1.Taint) *v1.Taint
- func PatchNodeStatus(c v1core.CoreV1Interface, nodeName types.NodeName, oldNode *v1.Node, ...) (*v1.Node, []byte, error)
- type CloudNodeController
- func (cnc *CloudNodeController) AddCloudNode(ctx context.Context, obj interface{})
- func (cnc *CloudNodeController) Run(stopCh <-chan struct{})
- func (cnc *CloudNodeController) UpdateCloudNode(ctx context.Context, _, newObj interface{})
- func (cnc *CloudNodeController) UpdateNodeStatus(ctx context.Context)
- type NodeProvider
Constants ¶
This section is empty.
Variables ¶
View Source
var UpdateNodeSpecBackoff = wait.Backoff{ Steps: 20, Duration: 50 * time.Millisecond, Jitter: 1.0, }
UpdateNodeSpecBackoff is the back configure for node update.
Functions ¶
Types ¶
type CloudNodeController ¶
type CloudNodeController struct {
// contains filtered or unexported fields
}
CloudNodeController reconciles node information.
func NewCloudNodeController ¶
func NewCloudNodeController( nodeName string, nodeInformer coreinformers.NodeInformer, kubeClient clientset.Interface, nodeProvider NodeProvider, nodeStatusUpdateFrequency time.Duration, waitForRoutes bool) *CloudNodeController
NewCloudNodeController creates a CloudNodeController object
func (*CloudNodeController) AddCloudNode ¶
func (cnc *CloudNodeController) AddCloudNode(ctx context.Context, obj interface{})
AddCloudNode handles initializing new nodes registered with the cloud taint.
func (*CloudNodeController) Run ¶
func (cnc *CloudNodeController) Run(stopCh <-chan struct{})
Run controller updates newly registered nodes with information from the cloud provider. This call is blocking so should be called via a goroutine
func (*CloudNodeController) UpdateCloudNode ¶
func (cnc *CloudNodeController) UpdateCloudNode(ctx context.Context, _, newObj interface{})
UpdateCloudNode handles node update event.
func (*CloudNodeController) UpdateNodeStatus ¶
func (cnc *CloudNodeController) UpdateNodeStatus(ctx context.Context)
UpdateNodeStatus updates the node status, such as node addresses
type NodeProvider ¶
type NodeProvider interface { // NodeAddresses returns the addresses of the specified instance. NodeAddresses(ctx context.Context, name types.NodeName) ([]v1.NodeAddress, error) // InstanceID returns the cloud provider ID of the specified instance. InstanceID(ctx context.Context, name types.NodeName) (string, error) // InstanceType returns the type of the specified instance. InstanceType(ctx context.Context, name types.NodeName) (string, error) // GetZone returns the Zone containing the current failure zone and locality region that the program is running in GetZone(ctx context.Context, name types.NodeName) (cloudprovider.Zone, error) // GetPlatformSubFaultDomain returns the PlatformSubFaultDomain from IMDS if set. GetPlatformSubFaultDomain() (string, error) }
NodeProvider defines the interfaces for node provider.
Click to show internal directories.
Click to hide internal directories.