Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(main): using new runtime interface #3691

Merged
merged 4 commits into from
Aug 22, 2023

Conversation

cuisongliu
Copy link
Collaborator

@cuisongliu cuisongliu commented Aug 16, 2023

🤖 Generated by Copilot at bd2b914

Summary

🔧🚀🧪

Refactored the pkg/apply/processor and pkg/runtime packages to simplify and unify the interface and logic of cluster operations. Renamed and replaced some methods to make them more generic and consistent. Updated the test cases to reflect the changes.

Sing, O Muse, of the valiant deeds of the code warriors
Who refactored the runtime package with skill and wisdom
And made the interface of cluster operations more consistent
Like Hephaestus, who forged the weapons of the gods with artistry

Walkthrough

  • Refactor the runtime interface to use more generic and consistent methods (link, link, link, link, link, link, link, link, link, link)
  • Replace GetKubeadmConfig with GetConfig in pkg/apply/gen.go, pkg/apply/processor/install.go, and pkg/client-go/kubernetes/expansion_test.go (link, link, link, link)
  • Replace JoinNodes, DeleteNodes, JoinMasters, and DeleteMasters with ScaleNodes and ScaleMasters in pkg/apply/processor/create.go, pkg/apply/processor/scale.go, and pkg/runtime/runtime.go (link, link, link, link, link)
  • Replace UpgradeCluster with Upgrade in pkg/apply/processor/install.go and pkg/runtime/runtime.go (link, link)
  • Update the test cases to reflect the changes in the runtime interface (link)

@sealos-ci-robot
Copy link
Member

sealos-ci-robot commented Aug 16, 2023

🤖 Generated by lychee action

Summary

Status Count
🔍 Total 909
✅ Successful 372
⏳ Timeouts 0
🔀 Redirected 0
👻 Excluded 536
❓ Unknown 0
🚫 Errors 0

Full action output

Full Github Actions output

@codecov
Copy link

codecov bot commented Aug 16, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (cf4242d) 66.46% compared to head (6bcf552) 66.46%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3691   +/-   ##
=======================================
  Coverage   66.46%   66.46%           
=======================================
  Files           8        8           
  Lines         656      656           
=======================================
  Hits          436      436           
  Misses        173      173           
  Partials       47       47           
Files Changed Coverage Δ
pkg/apply/gen.go 48.78% <0.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@cuisongliu cuisongliu marked this pull request as ready for review August 21, 2023 07:58
@cuisongliu cuisongliu requested a review from fengxsong August 21, 2023 07:58
@cuisongliu cuisongliu added this to the v4.3 milestone Aug 21, 2023
@cuisongliu cuisongliu added the need-e2e-apply-test need-e2e-apply-test label Aug 21, 2023
pkg/runtime/runtime.go Outdated Show resolved Hide resolved
pkg/apply/processor/scale.go Outdated Show resolved Hide resolved
pkg/apply/processor/scale.go Outdated Show resolved Hide resolved
@sealos-ci-robot
Copy link
Member

🤖 says: E2E Apply Test Result: Success 🎉🎉!
See: https://github.com/labring/sealos/actions/runs/5923654670

@cuisongliu cuisongliu added need-e2e-apply-test need-e2e-apply-test and removed need-e2e-apply-test need-e2e-apply-test labels Aug 21, 2023
Signed-off-by: cuisongliu <cuisongliu@qq.com>
Signed-off-by: cuisongliu <cuisongliu@qq.com>
Signed-off-by: cuisongliu <cuisongliu@qq.com>
Signed-off-by: cuisongliu <cuisongliu@qq.com>
@cuisongliu cuisongliu added need-e2e-apply-test need-e2e-apply-test and removed need-e2e-apply-test need-e2e-apply-test labels Aug 22, 2023
@labring labring deleted a comment from sealos-ci-robot Aug 22, 2023
@sealos-ci-robot
Copy link
Member

🤖 says: E2E ARM64 Apply Test Result: ‼️ Failure , E2E AMD64 Apply Test Result: ‼️ Failure
See: https://github.com/labring/sealos/actions/runs/5934538850

@cuisongliu cuisongliu merged commit 1828322 into labring:main Aug 22, 2023
@cuisongliu cuisongliu deleted the runtime-interface branch August 22, 2023 05:51
@sealos-ci-robot
Copy link
Member

/cherry-pick release-v4.3

@sealos-ci-robot
Copy link
Member

🤖 says: cherry pick action finished successfully 🎉!
See: https://github.com/labring/sealos/actions/runs/5934979414

sealos-ci-robot pushed a commit that referenced this pull request Aug 22, 2023
* refactor(main): using new runtime interface

Signed-off-by: cuisongliu <cuisongliu@qq.com>

* feature(main): using up and down interface

Signed-off-by: cuisongliu <cuisongliu@qq.com>

* feature(main): using up and down interface

Signed-off-by: cuisongliu <cuisongliu@qq.com>

* feature(main): using up and down interface

Signed-off-by: cuisongliu <cuisongliu@qq.com>

---------

Signed-off-by: cuisongliu <cuisongliu@qq.com>
cuisongliu added a commit that referenced this pull request Aug 22, 2023
* refactor(main): using new runtime interface



* feature(main): using up and down interface



* feature(main): using up and down interface



* feature(main): using up and down interface



---------

Signed-off-by: cuisongliu <cuisongliu@qq.com>
Co-authored-by: cuisongliu <cuisongliu@qq.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants