kubebb / core

A declarative component lifecycle management platform
https://kubebb.github.io/website
Apache License 2.0
8 stars 9 forks source link

feat: use workpool to reduce operator memory usage #366

Closed 0xff-dev closed 12 months ago

0xff-dev commented 1 year ago

What type of PR is this?

/kind bug

What this PR does / why we need it

feat: use workpool to reduce operator memory usage

Which issue(s) this PR fixes

Fixes #

Special notes for your reviewer

bjwswang commented 1 year ago

@0xff-dev Revert the default manager memory, then run the tests.

codecov[bot] commented 1 year ago

Codecov Report

Merging #366 (c9e97a3) into main (a1cbc9d) will decrease coverage by 0.47%. The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main     #366      +/-   ##
==========================================
- Coverage   25.72%   25.25%   -0.47%     
==========================================
  Files          41       42       +1     
  Lines        4637     4723      +86     
==========================================
  Hits         1193     1193              
- Misses       3342     3428      +86     
  Partials      102      102              
Files Coverage Δ
api/v1alpha1/component.go 94.28% <ø> (ø)
controllers/component_controller.go 0.00% <0.00%> (ø)
pkg/helm/helm_chart_workpool.go 0.00% <0.00%> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

0xff-dev commented 1 year ago
image

According to local tests, limiting memory growth by workpool, the maximum memory used is 1.4G. so adjust the deployment's memory limit value to 1.5G.

bjwswang commented 12 months ago
image

According to local tests, limiting memory growth by workpool, the maximum memory used is 1.4G. so adjust the deployment's memory limit value to 1.5G.

Can you pls show your test details? From my point of view, 1.5G still too much...

bjwswang commented 12 months ago

@0xff-dev We can use this for v0.2.0. And do further optimizations at v0.2.x maybe