Measure scheduler throughput in density test

This commit is contained in:
Shyam Jeedigunta
2018-05-24 16:47:38 +02:00
parent bebc5c1c4f
commit f363f549c0
3 changed files with 43 additions and 25 deletions

View File

@@ -655,6 +655,7 @@ type RCStartupStatus struct {
RunningButNotReady int
Waiting int
Pending int
Scheduled int
Unknown int
Inactive int
FailedContainers int
@@ -708,6 +709,10 @@ func ComputeRCStartupStatus(pods []*v1.Pod, expected int) RCStartupStatus {
} else if p.Status.Phase == v1.PodUnknown {
startupStatus.Unknown++
}
// Record count of scheduled pods (useful for computing scheduler throughput).
if p.Spec.NodeName != "" {
startupStatus.Scheduled++
}
}
return startupStatus
}