Skip to content

feat(scheduler): drive solver from generator portfolio#1745

Merged
enoodle merged 6 commits into
kai-scheduler:mainfrom
enoodle:erez/reclaim-generator-portfolio-06-portfolio-driver
Jun 24, 2026
Merged

feat(scheduler): drive solver from generator portfolio#1745
enoodle merged 6 commits into
kai-scheduler:mainfrom
enoodle:erez/reclaim-generator-portfolio-06-portfolio-driver

Conversation

@enoodle

@enoodle enoodle commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

Description

Stack slice 6 of 9 for the reclaim generator portfolio.

References:

This PR adds the portfolio driver:

  • Drives the solver from the registered scenario generator portfolio.
  • Preserves the per-generator lifecycle: one generator owns a full partial-gang search before fallback to the next generator.
  • Keeps benchmark-scale assertions out of this PR.

This slice turns the registered built-in generators into the active search portfolio.

Related Issues

Related to #1660.

Checklist

Note: Ensure your PR title follows the Conventional Commits format (e.g., feat(scheduler): add new feature)

  • Self-reviewed
  • Added/updated tests (if needed)
  • Updated documentation (if needed)

Breaking Changes

None.

Additional Notes

Stacking:

  • Base: erez/reclaim-generator-portfolio-05-built-in-generators
  • Next PR: erez/reclaim-generator-portfolio-07-metrics

Verification for the rebuilt stack:

  • GOCACHE=/tmp/kai-reclaim-generator-go-cache go test ./pkg/scheduler/plugins/scenariogenerators ./pkg/scheduler/conf_util ./pkg/operator/operands/scheduler ./pkg/scheduler/actions/common/solvers ./pkg/scheduler/actions/reclaim ./pkg/scheduler/actions/preempt ./pkg/scheduler/actions/consolidation ./pkg/scheduler/actions/integration_tests/reclaim ./pkg/scheduler/cache ./pkg/scheduler/cache/status_updater ./pkg/scheduler/metrics ./pkg/apis/scheduling/v2alpha2 -count=1
  • git diff --check
  • GOCACHE=/tmp/kai-reclaim-generator-go-cache make validate

@coderabbitai

coderabbitai Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5c98100f-9f05-49cd-9c14-6b4971fcca74

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from ad23803 to 696eb4a Compare June 22, 2026 14:01
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 1e5056c to 924e997 Compare June 22, 2026 14:04
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 696eb4a to 5e8640d Compare June 22, 2026 15:19
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch 2 times, most recently from 2eb6c36 to 6e28f51 Compare June 22, 2026 19:48
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 5e8640d to 024e6cb Compare June 22, 2026 19:55
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 6e28f51 to 7b0d4e6 Compare June 22, 2026 20:50
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 024e6cb to 0fd6a43 Compare June 22, 2026 20:51
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 7b0d4e6 to eb3e25c Compare June 23, 2026 08:59
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 0fd6a43 to 34a39b4 Compare June 23, 2026 09:00
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from eb3e25c to 23e3426 Compare June 23, 2026 09:33
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 34a39b4 to cd5bac1 Compare June 23, 2026 09:33
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 23e3426 to 7de278a Compare June 23, 2026 10:01
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from cd5bac1 to e20449e Compare June 23, 2026 10:01
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 7de278a to 21e43a3 Compare June 23, 2026 10:15
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from e20449e to d09aac7 Compare June 23, 2026 10:15
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 21e43a3 to 0585640 Compare June 23, 2026 10:46
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from d09aac7 to f359c40 Compare June 23, 2026 10:46
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 0585640 to 4d35dda Compare June 23, 2026 11:02
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from f359c40 to 4aa310d Compare June 23, 2026 11:02
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from 4d35dda to f74829e Compare June 23, 2026 11:53
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 4aa310d to 1fd706d Compare June 23, 2026 11:53
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch 2 times, most recently from 889360b to bb5b7d5 Compare June 23, 2026 14:52
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 1fd706d to 79a0fa4 Compare June 23, 2026 14:53
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-05-built-in-generators branch from bb5b7d5 to f36d5b0 Compare June 23, 2026 18:25
@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from af2b617 to 6a7cbdc Compare June 23, 2026 18:38
@enoodle enoodle changed the base branch from erez/reclaim-generator-portfolio-05-built-in-generators to erez/reclaim-generator-portfolio-04-05-wire-and-generators June 23, 2026 20:08
@enoodle enoodle closed this Jun 23, 2026
@enoodle enoodle reopened this Jun 23, 2026
davidLif
davidLif previously approved these changes Jun 23, 2026
enoodle added 6 commits June 23, 2026 23:36
Signed-off-by: Erez Freiberger <enoodle@gmail.com>
Signed-off-by: Erez Freiberger <enoodle@gmail.com>
Signed-off-by: Erez Freiberger <enoodle@gmail.com>
Signed-off-by: Erez Freiberger <enoodle@gmail.com>
Signed-off-by: Erez Freiberger <enoodle@gmail.com>
Signed-off-by: Erez Freiberger <enoodle@gmail.com>
@enoodle enoodle changed the base branch from erez/reclaim-generator-portfolio-04-05-wire-and-generators to main June 23, 2026 22:06
@enoodle enoodle dismissed davidLif’s stale review June 23, 2026 22:06

The base branch was changed.

@enoodle enoodle force-pushed the erez/reclaim-generator-portfolio-06-portfolio-driver branch from 27a0e44 to 435861c Compare June 23, 2026 22:07
@github-actions

Copy link
Copy Markdown

📊 Performance Benchmark Results

Comparing PR (erez/reclaim-generator-portfolio-06-portfolio-driver) vs main branch — click to expand
goos: linux
goarch: amd64
pkg: github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions
cpu: Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
                                    │ main-bench.txt │           pr-bench.txt            │
                                    │     sec/op     │   sec/op     vs base              │
AllocateAction_SmallCluster-4            109.5m ± 0%   109.3m ± 0%       ~ (p=0.240 n=6)
AllocateAction_MediumCluster-4           137.1m ± 1%   137.1m ± 1%       ~ (p=0.937 n=6)
AllocateAction_LargeCluster-4            208.2m ± 5%   209.6m ± 3%       ~ (p=0.818 n=6)
ReclaimAction_SmallCluster-4             103.5m ± 0%   103.6m ± 0%       ~ (p=0.818 n=6)
ReclaimAction_MediumCluster-4            106.6m ± 0%   107.0m ± 1%  +0.40% (p=0.041 n=6)
PreemptAction_SmallCluster-4             104.5m ± 0%   104.9m ± 0%  +0.45% (p=0.009 n=6)
PreemptAction_MediumCluster-4            112.4m ± 0%   116.1m ± 2%  +3.25% (p=0.002 n=6)
ConsolidationAction_SmallCluster-4       127.7m ± 1%   126.8m ± 0%  -0.73% (p=0.004 n=6)
ConsolidationAction_MediumCluster-4      301.2m ± 1%   299.5m ± 1%  -0.57% (p=0.002 n=6)
FullSchedulingCycle_SmallCluster-4       106.7m ± 0%   106.6m ± 0%       ~ (p=0.589 n=6)
FullSchedulingCycle_MediumCluster-4      120.9m ± 1%   120.9m ± 1%       ~ (p=0.240 n=6)
FullSchedulingCycle_LargeCluster-4       160.0m ± 2%   160.7m ± 1%       ~ (p=0.310 n=6)
ManyQueues_MediumCluster-4               141.3m ± 2%   141.4m ± 3%       ~ (p=0.699 n=6)
GangScheduling_MediumCluster-4           159.3m ± 2%   160.3m ± 1%       ~ (p=0.589 n=6)
geomean                                  135.8m        136.2m       +0.30%

                                    │ main-bench.txt │            pr-bench.txt             │
                                    │      B/op      │     B/op      vs base               │
AllocateAction_SmallCluster-4           2.312Mi ± 1%   2.311Mi ± 0%        ~ (p=0.394 n=6)
AllocateAction_MediumCluster-4          11.96Mi ± 0%   11.95Mi ± 0%        ~ (p=0.093 n=6)
AllocateAction_LargeCluster-4           40.03Mi ± 0%   40.04Mi ± 0%        ~ (p=0.485 n=6)
ReclaimAction_SmallCluster-4            953.0Ki ± 1%   952.8Ki ± 0%        ~ (p=0.937 n=6)
ReclaimAction_MediumCluster-4           3.093Mi ± 0%   3.096Mi ± 0%        ~ (p=0.589 n=6)
PreemptAction_SmallCluster-4            1.181Mi ± 1%   1.344Mi ± 0%  +13.83% (p=0.002 n=6)
PreemptAction_MediumCluster-4           4.749Mi ± 0%   5.922Mi ± 0%  +24.70% (p=0.002 n=6)
ConsolidationAction_SmallCluster-4      10.38Mi ± 0%   10.02Mi ± 0%   -3.52% (p=0.002 n=6)
ConsolidationAction_MediumCluster-4     88.88Mi ± 0%   88.76Mi ± 0%   -0.13% (p=0.002 n=6)
FullSchedulingCycle_SmallCluster-4      1.483Mi ± 0%   1.482Mi ± 0%        ~ (p=0.485 n=6)
FullSchedulingCycle_MediumCluster-4     7.021Mi ± 0%   7.020Mi ± 0%        ~ (p=0.485 n=6)
FullSchedulingCycle_LargeCluster-4      22.38Mi ± 0%   22.38Mi ± 0%   +0.01% (p=0.026 n=6)
ManyQueues_MediumCluster-4              16.44Mi ± 0%   16.44Mi ± 0%        ~ (p=0.394 n=6)
GangScheduling_MediumCluster-4          17.21Mi ± 0%   17.21Mi ± 0%   +0.02% (p=0.026 n=6)
geomean                                 7.240Mi        7.403Mi        +2.26%

                                    │ main-bench.txt │            pr-bench.txt            │
                                    │   allocs/op    │  allocs/op   vs base               │
AllocateAction_SmallCluster-4            36.03k ± 0%   36.02k ± 0%   -0.02% (p=0.030 n=6)
AllocateAction_MediumCluster-4           302.8k ± 0%   302.8k ± 0%        ~ (p=0.729 n=6)
AllocateAction_LargeCluster-4            1.266M ± 0%   1.266M ± 0%        ~ (p=0.093 n=6)
ReclaimAction_SmallCluster-4             8.917k ± 0%   8.914k ± 0%   -0.04% (p=0.002 n=6)
ReclaimAction_MediumCluster-4            28.06k ± 0%   28.06k ± 0%   -0.01% (p=0.002 n=6)
PreemptAction_SmallCluster-4             12.88k ± 0%   15.13k ± 0%  +17.44% (p=0.002 n=6)
PreemptAction_MediumCluster-4            44.95k ± 0%   54.75k ± 0%  +21.80% (p=0.002 n=6)
ConsolidationAction_SmallCluster-4       134.6k ± 0%   130.0k ± 0%   -3.43% (p=0.002 n=6)
ConsolidationAction_MediumCluster-4      1.283M ± 0%   1.282M ± 0%   -0.09% (p=0.002 n=6)
FullSchedulingCycle_SmallCluster-4       21.56k ± 0%   21.56k ± 0%        ~ (p=0.145 n=6)
FullSchedulingCycle_MediumCluster-4      164.7k ± 0%   164.7k ± 0%        ~ (p=0.589 n=6)
FullSchedulingCycle_LargeCluster-4       666.2k ± 0%   666.2k ± 0%        ~ (p=0.310 n=6)
ManyQueues_MediumCluster-4               341.3k ± 0%   341.3k ± 0%        ~ (p=0.329 n=6)
GangScheduling_MediumCluster-4           551.4k ± 0%   551.4k ± 0%        ~ (p=0.310 n=6)
geomean                                  121.6k        124.4k        +2.32%

pkg: github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/integration_tests/reclaim
                            │ main-bench.txt │             pr-bench.txt             │
                            │     sec/op     │    sec/op     vs base                │
ReclaimLargeJobs_10Node-4        106.3m ± 1%    106.3m ± 1%         ~ (p=0.818 n=6)
ReclaimLargeJobs_50Node-4        141.8m ± 2%    281.2m ± 2%   +98.27% (p=0.002 n=6)
ReclaimLargeJobs_100Node-4       211.2m ± 2%    508.9m ± 4%  +140.94% (p=0.002 n=6)
ReclaimLargeJobs_200Node-4       424.3m ± 4%   1080.9m ± 1%  +154.78% (p=0.002 n=6)
ReclaimLargeJobs_500Node-4        1.600 ± 4%     3.816 ± 2%  +138.42% (p=0.002 n=6)
ReclaimLargeJobs_1000Node-4       6.278 ± 1%    12.920 ± 1%  +105.81% (p=0.002 n=6)
geomean                          488.4m         965.6m        +97.70%

                            │ main-bench.txt │             pr-bench.txt              │
                            │      B/op      │     B/op       vs base                │
ReclaimLargeJobs_10Node-4       2.100Mi ± 3%    2.069Mi ± 3%    -1.49% (p=0.041 n=6)
ReclaimLargeJobs_50Node-4       16.37Mi ± 0%    80.18Mi ± 0%  +389.65% (p=0.002 n=6)
ReclaimLargeJobs_100Node-4      37.23Mi ± 0%   165.13Mi ± 0%  +343.54% (p=0.002 n=6)
ReclaimLargeJobs_200Node-4      86.49Mi ± 0%   344.77Mi ± 0%  +298.62% (p=0.002 n=6)
ReclaimLargeJobs_500Node-4      262.7Mi ± 0%    924.3Mi ± 0%  +251.90% (p=0.002 n=6)
ReclaimLargeJobs_1000Node-4     674.9Mi ± 0%   2055.0Mi ± 0%  +204.48% (p=0.002 n=6)
geomean                         51.94Mi         161.8Mi       +211.51%

                            │ main-bench.txt │             pr-bench.txt             │
                            │   allocs/op    │  allocs/op    vs base                │
ReclaimLargeJobs_10Node-4        23.53k ± 2%    23.20k ± 2%    -1.41% (p=0.032 n=6)
ReclaimLargeJobs_50Node-4        212.2k ± 0%   1071.1k ± 0%  +404.86% (p=0.002 n=6)
ReclaimLargeJobs_100Node-4       511.2k ± 0%   2223.4k ± 0%  +334.91% (p=0.002 n=6)
ReclaimLargeJobs_200Node-4       1.274M ± 0%    4.691M ± 0%  +268.32% (p=0.002 n=6)
ReclaimLargeJobs_500Node-4       4.319M ± 0%   12.875M ± 0%  +198.10% (p=0.002 n=6)
ReclaimLargeJobs_1000Node-4      12.54M ± 0%    29.74M ± 0%  +137.15% (p=0.002 n=6)
geomean                          748.7k         2.152M       +187.41%

pkg: github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/reclaim
                                             │ main-bench.txt │            pr-bench.txt            │
                                             │     sec/op     │   sec/op     vs base               │
ReclaimUnschedulableDistributedJob_10Node-4      138.2m ±  1%   153.1m ± 1%  +10.81% (p=0.002 n=6)
ReclaimUnschedulableDistributedJob_50Node-4       10.62 ±  2%    10.66 ± 2%        ~ (p=0.240 n=6)
ReclaimUnschedulableDistributedJob_100Node-4      53.56 ±  2%    54.85 ± 1%   +2.41% (p=0.004 n=6)
ReclaimWithMissingPVCJobs-4                      2.567m ± 35%   2.439m ± 5%   -5.01% (p=0.015 n=6)
geomean                                          670.2m         683.6m        +2.01%

                                             │ main-bench.txt │            pr-bench.txt             │
                                             │      B/op      │     B/op      vs base               │
ReclaimUnschedulableDistributedJob_10Node-4      13.96Mi ± 5%   21.24Mi ± 3%  +52.15% (p=0.002 n=6)
ReclaimUnschedulableDistributedJob_50Node-4      3.439Gi ± 0%   3.498Gi ± 0%   +1.72% (p=0.002 n=6)
ReclaimUnschedulableDistributedJob_100Node-4     18.06Gi ± 0%   18.19Gi ± 0%   +0.69% (p=0.002 n=6)
ReclaimWithMissingPVCJobs-4                      8.711Ki ± 5%   8.539Ki ± 1%        ~ (p=0.123 n=6)
geomean                                          52.74Mi        58.63Mi       +11.18%

                                             │ main-bench.txt │            pr-bench.txt            │
                                             │   allocs/op    │  allocs/op   vs base               │
ReclaimUnschedulableDistributedJob_10Node-4       217.6k ± 4%   318.8k ± 3%  +46.50% (p=0.002 n=6)
ReclaimUnschedulableDistributedJob_50Node-4       98.88M ± 0%   99.69M ± 0%   +0.82% (p=0.002 n=6)
ReclaimUnschedulableDistributedJob_100Node-4      615.4M ± 0%   617.1M ± 0%   +0.28% (p=0.002 n=6)
ReclaimWithMissingPVCJobs-4                        159.5 ± 3%    158.5 ± 0%        ~ (p=0.130 n=6)
geomean                                           1.206M        1.328M       +10.15%

Legend

  • 📉 Negative delta = Performance improvement (faster)
  • 📈 Positive delta = Performance regression (slower)
  • p-value < 0.05 indicates statistically significant change
Raw benchmark data

PR branch:

goos: linux
goarch: amd64
pkg: github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions
cpu: Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
BenchmarkAllocateAction_SmallCluster-4         	      10	 109370832 ns/op	 2434376 B/op	   36031 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109260758 ns/op	 2422094 B/op	   36023 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109289825 ns/op	 2422897 B/op	   36022 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 108726514 ns/op	 2429828 B/op	   36028 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109248609 ns/op	 2423738 B/op	   36024 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109232513 ns/op	 2421953 B/op	   36025 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 136954460 ns/op	12535583 B/op	  302792 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 135914068 ns/op	12535438 B/op	  302774 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 138059859 ns/op	12534287 B/op	  302699 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 137157418 ns/op	12533182 B/op	  302742 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 137732675 ns/op	12535286 B/op	  302768 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 136910995 ns/op	12533236 B/op	  302723 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 209133751 ns/op	41998265 B/op	 1266214 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 208181887 ns/op	41981876 B/op	 1266140 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 209109694 ns/op	41979032 B/op	 1266186 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 216556227 ns/op	41972502 B/op	 1266163 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 210062395 ns/op	41984788 B/op	 1266218 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 210209656 ns/op	41977752 B/op	 1266157 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103662882 ns/op	  970999 B/op	    8912 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103540299 ns/op	  975551 B/op	    8914 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103459698 ns/op	  975359 B/op	    8913 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103584036 ns/op	  976159 B/op	    8914 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103617919 ns/op	  976133 B/op	    8911 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103418004 ns/op	  975684 B/op	    8915 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 107431264 ns/op	 3257128 B/op	   28057 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 107107320 ns/op	 3238643 B/op	   28053 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 107332330 ns/op	 3246076 B/op	   28057 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106906623 ns/op	 3246116 B/op	   28057 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106443144 ns/op	 3245842 B/op	   28055 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106785318 ns/op	 3246245 B/op	   28055 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104619761 ns/op	 1405469 B/op	   15128 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104967640 ns/op	 1409672 B/op	   15131 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104700600 ns/op	 1409533 B/op	   15131 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104952736 ns/op	 1415780 B/op	   15130 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 105012508 ns/op	 1409501 B/op	   15131 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104919184 ns/op	 1409074 B/op	   15130 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 117531912 ns/op	 6199591 B/op	   54746 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 115759915 ns/op	 6212234 B/op	   54748 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 116169993 ns/op	 6207541 B/op	   54745 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 115745292 ns/op	 6202641 B/op	   54740 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 115941164 ns/op	 6212160 B/op	   54748 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 118017800 ns/op	 6211434 B/op	   54745 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 126721603 ns/op	10505383 B/op	  130010 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 126816243 ns/op	10505752 B/op	  130015 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 126896724 ns/op	10504751 B/op	  130006 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 126743401 ns/op	10515384 B/op	  130011 allocs/op

Main branch:

goos: linux
goarch: amd64
pkg: github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions
cpu: Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
BenchmarkAllocateAction_SmallCluster-4         	      10	 109534563 ns/op	 2440199 B/op	   36037 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109564729 ns/op	 2434144 B/op	   36035 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109598679 ns/op	 2423884 B/op	   36026 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109420904 ns/op	 2422399 B/op	   36028 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109172941 ns/op	 2423068 B/op	   36030 allocs/op
BenchmarkAllocateAction_SmallCluster-4         	      10	 109108276 ns/op	 2424612 B/op	   36033 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 136716080 ns/op	12535790 B/op	  302768 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 137280310 ns/op	12534125 B/op	  302747 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 136985439 ns/op	12537536 B/op	  302773 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 136263303 ns/op	12536409 B/op	  302780 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 137563624 ns/op	12536992 B/op	  302734 allocs/op
BenchmarkAllocateAction_MediumCluster-4        	       8	 137488260 ns/op	12534316 B/op	  302759 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 211277583 ns/op	41981356 B/op	 1266240 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 205797675 ns/op	41976480 B/op	 1266232 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 205728779 ns/op	41980468 B/op	 1266196 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 210642640 ns/op	41977672 B/op	 1266229 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 217965488 ns/op	41969344 B/op	 1266143 allocs/op
BenchmarkAllocateAction_LargeCluster-4         	       5	 205350937 ns/op	41993678 B/op	 1266245 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103757685 ns/op	  971716 B/op	    8916 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103468645 ns/op	  968320 B/op	    8916 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103666319 ns/op	  975895 B/op	    8917 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103262025 ns/op	  976037 B/op	    8919 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103526929 ns/op	  975925 B/op	    8917 allocs/op
BenchmarkReclaimAction_SmallCluster-4          	      10	 103301632 ns/op	  977168 B/op	    8917 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106749315 ns/op	 3242406 B/op	   28058 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106699534 ns/op	 3246327 B/op	   28060 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106593818 ns/op	 3242879 B/op	   28058 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106365630 ns/op	 3246663 B/op	   28059 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106563742 ns/op	 3242660 B/op	   28059 allocs/op
BenchmarkReclaimAction_MediumCluster-4         	      10	 106504396 ns/op	 3238727 B/op	   28058 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104364538 ns/op	 1236109 B/op	   12881 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104456650 ns/op	 1240965 B/op	   12885 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104467315 ns/op	 1232268 B/op	   12880 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104716678 ns/op	 1232636 B/op	   12882 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104241450 ns/op	 1247013 B/op	   12885 allocs/op
BenchmarkPreemptAction_SmallCluster-4          	      10	 104472963 ns/op	 1240429 B/op	   12885 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 112773557 ns/op	 4979716 B/op	   44946 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 112679785 ns/op	 4984235 B/op	   44949 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 112371362 ns/op	 4979949 B/op	   44948 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 112375580 ns/op	 4975537 B/op	   44946 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 112396593 ns/op	 4979527 B/op	   44946 allocs/op
BenchmarkPreemptAction_MediumCluster-4         	       9	 112399925 ns/op	 4979536 B/op	   44946 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 127940888 ns/op	10891327 B/op	  134640 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 127909293 ns/op	10886209 B/op	  134614 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 127536910 ns/op	10888484 B/op	  134631 allocs/op
BenchmarkConsolidationAction_SmallCluster-4    	       9	 127864016 ns/op	10888357 B/op	  134628 allocs/op

@github-actions

Copy link
Copy Markdown

Total coverage: 51.6% -> 52.1% (delta 0.50%)

Merging this branch changes the coverage (1 decrease, 1 increase)

Impacted Packages Coverage Δ 🤖
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/common/solvers 80.68% (+16.81%) 🎉
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/consolidation 80.00% (ø)
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/reclaim 83.61% (ø)
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/framework 39.96% (-0.19%) 👎
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/plugins/multinodegang 42.11% (ø)
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/plugins/nodelocalgreedy 90.24% (ø)

Coverage by file

Changed files (no unit tests)

Changed File Coverage Δ Total Covered Missed 🤖
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/common/solvers/job_solver.go 77.65% (+23.66%) 170 (+7) 132 (+44) 38 (-37) 🌟
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/common/solvers/scenario_generator.go 78.43% (+78.43%) 51 (+46) 40 (+40) 11 (+6) 🌟
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/framework/session.go 19.60% (ø) 250 49 201
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/framework/session_plugins.go 21.26% (-1.33%) 174 (-3) 37 (-3) 137 👎
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/plugins/multinodegang/multinodegang.go 71.43% (ø) 7 5 2
github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/plugins/nodelocalgreedy/nodelocalgreedy.go 71.43% (ø) 7 5 2

Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code.

Changed unit test files

  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/common/solvers/generator_test_helpers_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/common/solvers/job_solver_result_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/common/solvers/scenario_portfolio_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/consolidation/consolidation_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/actions/reclaim/reclaim_budget_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/framework/session_plugins_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/plugins/multinodegang/multinodegang_test.go
  • github.com/kai-scheduler/KAI-scheduler/pkg/scheduler/plugins/nodelocalgreedy/nodelocalgreedy_test.go

@enoodle enoodle marked this pull request as ready for review June 24, 2026 07:12
@enoodle enoodle added this pull request to the merge queue Jun 24, 2026
Merged via the queue into kai-scheduler:main with commit a0c8601 Jun 24, 2026
13 of 14 checks passed
@enoodle enoodle deleted the erez/reclaim-generator-portfolio-06-portfolio-driver branch June 24, 2026 07:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants