Skip to content

Commit f2e1cee

Browse files
actions-userRonShvarz
authored andcommitted
Incorrect resources allocation (#2224)
* refactored names and added jsdoc * fixed bug where workers stats under node were not calculated correctly * fixed bug - bad calculation, as long free is negative it causes reserved to always be negative. * added new method to get default value for resources, via limitrange * added stub data for test * fixed bug - should apply workerResourceRequests only if settings.applyResources is true, plus fixed merged method to not include fields that are empty or null, since null will fail k8s job and empty will just be odd in the job spec, better of without it. * refactor a bit, and changed behavior to take max out of requests and limits if useResouceLimits is on (some pods have no limit, which can cause limits to be lower than requests, which is impossible). * jsdoc was added and small refactor * now taking worker resources in account when calculating resources per algortihm * extracted default container resources out of the reconcile, and now in data preparation * fix all graph calculations errors * Now takes maximum between request and limit in case useResourceLimits flag is true, in case many pods have no limit and causes limit to be lower than request (which is impossible) * Passing default resources, so when calculating a worker without any special definition of resource, it will take its default resource instead to be more concise in calculation of requirements * Now sending actual request to other always, while keeping the requests for calculations dependant on the requests or limits & requests (for missing limit) * fixed free&other calculation after changes in task-executor * . * added unit tests to test the method after it changes. * update k8s client version .... bump version [skip ci]
1 parent 3772cfd commit f2e1cee

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "hkube",
3-
"version": "2.9.33",
3+
"version": "2.9.34",
44
"description": "",
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)