Merge pull request #108919 from denkensk/rename-usQ

Rename unschedulableQ to unschedulablePods
This commit is contained in:
Kubernetes Prow Robot
2022-03-24 12:18:53 -07:00
committed by GitHub
12 changed files with 218 additions and 213 deletions

View File

@@ -32,7 +32,7 @@
subsystem: scheduler
help: Number of pending pods, by the queue type. 'active' means number of pods in
activeQ; 'backoff' means number of pods in backoffQ; 'unschedulable' means number
of pods in unschedulableQ.
of pods in unschedulablePods.
type: Gauge
stabilityLevel: STABLE
labels:

View File

@@ -107,12 +107,12 @@ func TestCoreResourceEnqueue(t *testing.T) {
testCtx.Scheduler.Error(podInfo, fitError)
// Scheduling cycle is incremented by one after NextPod() is called, so
// pass a number larger than i to move Pod to unschedulableQ.
// pass a number larger than i to move Pod to unschedulablePods.
testCtx.Scheduler.SchedulingQueue.AddUnschedulableIfNotPresent(podInfo, int64(i+10))
}
// Trigger a NodeTaintChange event.
// We expect this event to trigger moving the test Pod from unschedulableQ to activeQ.
// We expect this event to trigger moving the test Pod from unschedulablePods to activeQ.
node.Spec.Taints = nil
if _, err := cs.CoreV1().Nodes().Update(ctx, node, metav1.UpdateOptions{}); err != nil {
t.Fatalf("Failed to remove taints off the node: %v", err)
@@ -285,11 +285,11 @@ func TestCustomResourceEnqueue(t *testing.T) {
testCtx.Scheduler.Error(podInfo, fitError)
// Scheduling cycle is incremented from 0 to 1 after NextPod() is called, so
// pass a number larger than 1 to move Pod to unschedulableQ.
// pass a number larger than 1 to move Pod to unschedulablePods.
testCtx.Scheduler.SchedulingQueue.AddUnschedulableIfNotPresent(podInfo, 10)
// Trigger a Custom Resource event.
// We expect this event to trigger moving the test Pod from unschedulableQ to activeQ.
// We expect this event to trigger moving the test Pod from unschedulablePods to activeQ.
crdGVR := schema.GroupVersionResource{Group: fooCRD.Spec.Group, Version: fooCRD.Spec.Versions[0].Name, Resource: "foos"}
crClient := dynamicClient.Resource(crdGVR).Namespace(ns)
if _, err := crClient.Create(ctx, &unstructured.Unstructured{