test/e2e/framework/:use the term 'Control Plane' in comment

This commit is contained in:
tanjunchen 2020-10-02 08:54:29 -07:00
parent 112dbd5586
commit 818238ae74
4 changed files with 8 additions and 10 deletions

View File

@ -883,8 +883,8 @@ func getPortURL(client clientset.Interface, ns, name string, svcPort int) (strin
if err != nil { if err != nil {
return "", err return "", err
} }
// This list of nodes must not include the master, which is marked // This list of nodes must not include the any control plane nodes, which are marked
// unschedulable, since the master doesn't run kube-proxy. Without // unschedulable, since control plane nodes don't run kube-proxy. Without
// kube-proxy NodePorts won't work. // kube-proxy NodePorts won't work.
var nodes *v1.NodeList var nodes *v1.NodeList
if wait.PollImmediate(poll, framework.SingleCallTimeout, func() (bool, error) { if wait.PollImmediate(poll, framework.SingleCallTimeout, func() (bool, error) {

View File

@ -191,7 +191,7 @@ func Filter(nodeList *v1.NodeList, fn func(node v1.Node) bool) {
nodeList.Items = l nodeList.Items = l
} }
// TotalRegistered returns number of registered Nodes excluding Master Node. // TotalRegistered returns number of schedulable Nodes.
func TotalRegistered(c clientset.Interface) (int, error) { func TotalRegistered(c clientset.Interface) (int, error) {
nodes, err := waitListSchedulableNodes(c) nodes, err := waitListSchedulableNodes(c)
if err != nil { if err != nil {
@ -201,7 +201,7 @@ func TotalRegistered(c clientset.Interface) (int, error) {
return len(nodes.Items), nil return len(nodes.Items), nil
} }
// TotalReady returns number of ready Nodes excluding Master Node. // TotalReady returns number of ready schedulable Nodes.
func TotalReady(c clientset.Interface) (int, error) { func TotalReady(c clientset.Interface) (int, error) {
nodes, err := waitListSchedulableNodes(c) nodes, err := waitListSchedulableNodes(c)
if err != nil { if err != nil {

View File

@ -40,8 +40,7 @@ var requiredPerNodePods = []*regexp.Regexp{
} }
// WaitForReadyNodes waits up to timeout for cluster to has desired size and // WaitForReadyNodes waits up to timeout for cluster to has desired size and
// there is no not-ready nodes in it. By cluster size we mean number of Nodes // there is no not-ready nodes in it. By cluster size we mean number of schedulable Nodes.
// excluding Master Node.
func WaitForReadyNodes(c clientset.Interface, size int, timeout time.Duration) error { func WaitForReadyNodes(c clientset.Interface, size int, timeout time.Duration) error {
_, err := CheckReady(c, size, timeout) _, err := CheckReady(c, size, timeout)
return err return err
@ -149,8 +148,7 @@ func WaitForNodeToBeReady(c clientset.Interface, name string, timeout time.Durat
} }
// CheckReady waits up to timeout for cluster to has desired size and // CheckReady waits up to timeout for cluster to has desired size and
// there is no not-ready nodes in it. By cluster size we mean number of Nodes // there is no not-ready nodes in it. By cluster size we mean number of schedulable Nodes.
// excluding Master Node.
func CheckReady(c clientset.Interface, size int, timeout time.Duration) ([]v1.Node, error) { func CheckReady(c clientset.Interface, size int, timeout time.Duration) ([]v1.Node, error) {
for start := time.Now(); time.Since(start) < timeout; time.Sleep(sleepTime) { for start := time.Now(); time.Since(start) < timeout; time.Sleep(sleepTime) {
nodes, err := waitListSchedulableNodes(c) nodes, err := waitListSchedulableNodes(c)

View File

@ -112,8 +112,8 @@ func makePrivateKeySignerFromFile(key string) (ssh.Signer, error) {
return signer, err return signer, err
} }
// NodeSSHHosts returns SSH-able host names for all schedulable nodes - this // NodeSSHHosts returns SSH-able host names for all schedulable nodes.
// excludes master node. If it can't find any external IPs, it falls back to // If it can't find any external IPs, it falls back to
// looking for internal IPs. If it can't find an internal IP for every node it // looking for internal IPs. If it can't find an internal IP for every node it
// returns an error, though it still returns all hosts that it found in that // returns an error, though it still returns all hosts that it found in that
// case. // case.