forked from kubernetes/perf-tests
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
127 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
111 changes: 111 additions & 0 deletions
111
clusterloader2/testing/load/modules/scheduler-throughput.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
## Input params | ||
# Valid actions: "create", "delete" | ||
{{$action := .action}} | ||
{{$namespaces := .namespaces}} | ||
{{$replicasPerNamespace := .replicasPerNamespace}} | ||
{{$schedulerThroughputNamespaces := .schedulerThroughputNamespaces}} | ||
{{$schedulerThroughputPodsPerDeployment := .schedulerThroughputPodsPerDeployment}} | ||
|
||
## Derivative variables | ||
{{$is_creating := (eq .action "create")}} | ||
{{$is_deleting := (eq .action "delete")}} | ||
|
||
## CL2 params | ||
{{$ENABLE_HUGE_SERVICES := DefaultParam .CL2_ENABLE_HUGE_SERVICES false}} | ||
{{$SCHEDULER_THROUGHPUT_THRESHOLD := DefaultParam .CL2_SCHEDULER_THROUGHPUT_THRESHOLD 100}} | ||
|
||
steps: | ||
{{if $is_creating}} | ||
- name: Creating scheduler throughput measurements | ||
measurements: | ||
- Identifier: HighThroughputPodStartupLatency | ||
Method: PodStartupLatency | ||
Params: | ||
action: start | ||
labelSelector: group = scheduler-throughput | ||
threshold: 1h # TODO(https://github.com/kubernetes/perf-tests/issues/1024): Ideally, this should be 5s | ||
- Identifier: WaitForSchedulerThroughputDeployments | ||
Method: WaitForControlledPodsRunning | ||
Params: | ||
action: start | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
labelSelector: group = scheduler-throughput | ||
# The operation timeout shouldn't be less than 20m to make sure that ~10m node | ||
# failure won't fail the test. See https://github.com/kubernetes/kubernetes/issues/73461#issuecomment-467338711 | ||
operationTimeout: 20m | ||
- Identifier: SchedulingThroughput | ||
Method: SchedulingThroughput | ||
Params: | ||
action: start | ||
labelSelector: group = scheduler-throughput | ||
measurmentInterval: 1s | ||
{{if $ENABLE_HUGE_SERVICES}} | ||
- name: Creating huge services | ||
phases: | ||
- namespaceRange: | ||
min: {{AddInt $namespaces 1}} | ||
max: {{AddInt $namespaces $schedulerThroughputNamespaces}} | ||
replicasPerNamespace: 1 | ||
tuningSet: Sequence | ||
objectBundle: | ||
- basename: huge-service | ||
objectTemplatePath: service.yaml | ||
{{end}} | ||
{{end}} | ||
- name: {{$action}} scheduler throughput pods | ||
phases: | ||
- namespaceRange: | ||
min: {{AddInt $namespaces 1}} | ||
max: {{AddInt $namespaces $schedulerThroughputNamespaces}} | ||
replicasPerNamespace: {{$replicasPerNamespace}} | ||
tuningSet: SchedulerThroughputParallel | ||
objectBundle: | ||
- basename: scheduler-throughput-deployment | ||
objectTemplatePath: simple-deployment.yaml | ||
templateFillMap: | ||
Replicas: {{$schedulerThroughputPodsPerDeployment}} | ||
Group: scheduler-throughput | ||
CpuRequest: 1m | ||
MemoryRequest: 10M | ||
{{if $ENABLE_HUGE_SERVICES}} | ||
SvcName: huge-service | ||
{{end}} | ||
- name: Waiting for scheduler throughput pods to be {{$action}}d | ||
measurements: | ||
- Identifier: WaitForSchedulerThroughputDeployments | ||
Method: WaitForControlledPodsRunning | ||
Params: | ||
action: gather | ||
{{if and $is_deleting $ENABLE_HUGE_SERVICES}} | ||
- name: Deleting huge services | ||
phases: | ||
- namespaceRange: | ||
min: {{AddInt $namespaces 1}} | ||
max: {{AddInt $namespaces $schedulerThroughputNamespaces}} | ||
replicasPerNamespace: 0 | ||
tuningSet: Sequence | ||
objectBundle: | ||
- basename: huge-service | ||
objectTemplatePath: service.yaml | ||
- name: Sleeping after deleting huge services | ||
measurements: | ||
- Identifier: WaitAfterHugeServicesDeletion | ||
Method: Sleep | ||
Params: | ||
duration: "3m" | ||
{{end}} | ||
{{if $is_creating}} | ||
- name: Collecting scheduler throughput measurements | ||
measurements: | ||
- Identifier: HighThroughputPodStartupLatency | ||
Method: PodStartupLatency | ||
Params: | ||
action: gather | ||
- Identifier: SchedulingThroughput | ||
Method: SchedulingThroughput | ||
Params: | ||
action: gather | ||
enableViolations: true | ||
threshold: {{$SCHEDULER_THROUGHPUT_THRESHOLD}} | ||
{{end}} |