Skip to content

Commit c3ebd95

Browse files
authored
Merge pull request #127236 from macsko/scheduler_perf_test_case_for_hints_memory_leak_scenario
Add scheduler_perf test case for queueing hints memory leak scenario
2 parents 7c599d3 + dba24fd commit c3ebd95

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

test/integration/scheduler_perf/config/performance-config.yaml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1383,3 +1383,39 @@
13831383
params:
13841384
gatedPods: 10000
13851385
measurePods: 20000
1386+
1387+
# This test case simulates the scheduling when pods selected to schedule have deletionTimestamp set.
1388+
# There was a memory leak related to this path of code fixed in:
1389+
# https://github.com/kubernetes/kubernetes/pull/126962
1390+
# Main goal of this test case is to verify if InFlightEvents is empty after the test.
1391+
- name: SchedulingDeletedPodsWithFinalizers
1392+
featureGates:
1393+
SchedulerQueueingHints: true
1394+
defaultPodTemplatePath: config/templates/light-pod.yaml
1395+
workloadTemplate:
1396+
- opcode: createNodes
1397+
countParam: $initNodes
1398+
- opcode: createPods
1399+
# Create pods with finalizers and delete them before they are scheduled.
1400+
# DeletionTimestamp field should be populated then,
1401+
# but a few pods should still be chosen into the scheduling.
1402+
countParam: $deletingPods
1403+
podTemplatePath: config/templates/pod-with-finalizer.yaml
1404+
skipWaitToCompletion: true
1405+
deletePodsPerSecond: 100
1406+
- opcode: createPods
1407+
countParam: $measurePods
1408+
collectMetrics: true
1409+
workloads:
1410+
- name: 10Node_100DeletingPods
1411+
labels: [integration-test, fast]
1412+
params:
1413+
initNodes: 10
1414+
deletingPods: 100
1415+
measurePods: 10
1416+
- name: 1000Node_1000DeletingPods
1417+
labels: [performance, fast]
1418+
params:
1419+
initNodes: 1000
1420+
deletingPods: 1000
1421+
measurePods: 1000
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
apiVersion: v1
2+
kind: Pod
3+
metadata:
4+
generateName: pod-
5+
finalizers:
6+
- test.k8s.io/finalizer
7+
spec:
8+
containers:
9+
- image: registry.k8s.io/pause:3.10
10+
name: pause

0 commit comments

Comments
 (0)