kubewharf / katalyst-core

Katalyst aims to provide a universal solution to help improve resource utilization and optimize the overall costs in the cloud. This is the core components in Katalyst system, including multiple agents and centralized components
Apache License 2.0
388 stars 91 forks source link

feat(spd): support resource portrait plugin #589

Closed kapybar4 closed 3 weeks ago

kapybar4 commented 1 month ago

What type of PR is this?

Features

What this PR does / why we need it:

Resource portrait generates a workload profile based on the historical indicator data of the workload with the help of artificial intelligence analysis algorithms to guide upper-level applications or controllers to implement intelligent load adjustment and ensure that the workload uses reasonable resources and runs smoothly.

Special notes for your reviewer:

CLAassistant commented 1 month ago

CLA assistant check
All committers have signed the CLA.

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 50.08881% with 281 lines in your changes are missing coverage. Please review.

Project coverage is 56.25%. Comparing base (b8d41bd) to head (4963615). Report is 2 commits behind head on main.

Files Patch % Lines
...cator-plugin/resource_portrait_indicator_plugin.go 27.00% 226 Missing and 1 partial :warning:
...ce_portrait_indicator_plugin_algorithm_provider.go 75.00% 10 Missing and 10 partials :warning:
cmd/katalyst-controller/app/options/spd.go 51.51% 16 Missing :warning:
...n/resource_portrait_indicator_plugin_promclient.go 84.90% 5 Missing and 3 partials :warning:
pkg/controller/spd/indicator-plugin/manager.go 50.00% 3 Missing and 2 partials :warning:
...kg/util/datasource/prometheus/prometheus_client.go 16.66% 4 Missing and 1 partial :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #589 +/- ## ========================================== + Coverage 55.96% 56.25% +0.28% ========================================== Files 535 534 -1 Lines 49827 50238 +411 ========================================== + Hits 27887 28262 +375 - Misses 18384 18392 +8 - Partials 3556 3584 +28 ``` | [Flag](https://app.codecov.io/gh/kubewharf/katalyst-core/pull/589/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kubewharf) | Coverage Δ | | |---|---|---| | [unittest](https://app.codecov.io/gh/kubewharf/katalyst-core/pull/589/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kubewharf) | `56.25% <50.08%> (+0.28%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kubewharf#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov-commenter commented 1 month ago

Codecov Report

Attention: Patch coverage is 56.39445% with 283 lines in your changes missing coverage. Please review.

Project coverage is 56.49%. Comparing base (a8c57c1) to head (39df2d3).

Files Patch % Lines
...ugin/plugins/resource-portrait/indicator_plugin.go 15.38% 164 Missing and 1 partial :warning:
...indicator-plugin/plugins/resource-portrait/util.go 74.57% 27 Missing and 3 partials :warning:
cmd/katalyst-controller/app/options/spd.go 50.00% 21 Missing and 1 partial :warning:
...in/plugins/resource-portrait/algorithm_provider.go 74.41% 11 Missing and 11 partials :warning:
pkg/util/spd.go 69.04% 7 Missing and 6 partials :warning:
...or-plugin/plugins/resource-portrait/data_source.go 81.53% 7 Missing and 5 partials :warning:
pkg/controller/spd/indicator-plugin/manager.go 54.54% 3 Missing and 2 partials :warning:
...kg/util/datasource/prometheus/prometheus_client.go 16.66% 4 Missing and 1 partial :warning:
...plugin/plugins/resource-portrait/config_manager.go 89.47% 3 Missing and 1 partial :warning:
pkg/controller/spd/spd.go 57.14% 2 Missing and 1 partial :warning:
... and 1 more
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #589 +/- ## ========================================== + Coverage 56.20% 56.49% +0.28% ========================================== Files 543 544 +1 Lines 50403 50827 +424 ========================================== + Hits 28331 28716 +385 - Misses 18480 18492 +12 - Partials 3592 3619 +27 ``` | [Flag](https://app.codecov.io/gh/kubewharf/katalyst-core/pull/589/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kubewharf) | Coverage Δ | | |---|---|---| | [unittest](https://app.codecov.io/gh/kubewharf/katalyst-core/pull/589/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kubewharf) | `56.49% <56.39%> (+0.28%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=kubewharf#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.