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

Use k8s.io/component-base/cli to run cmd #2049

Merged
merged 1 commit into from
Jun 23, 2022

Conversation

wuyingjun-lucky
Copy link
Member

Signed-off-by: wuyingjun wuyingjun_yewu@cmss.chinamobile.com

What type of PR is this?
/kind cleanup

What this PR does / why we need it:
refer to kubernetes api server
kubernetes replace all commands with k8s.io/component-base/cli to run
Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

@karmada-bot karmada-bot added the kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. label Jun 22, 2022
@karmada-bot karmada-bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jun 22, 2022
@wuyingjun-lucky
Copy link
Member Author

/assign @RainbowMango
/assign @XiShanYongYe-Chang
/assign @lonelyCZ

@Garrybest
Copy link
Member

Nice job, I like this clean up!

/lgtm

@karmada-bot karmada-bot added the lgtm Indicates that a PR is ready to be merged. label Jun 22, 2022
Copy link
Member

@XiShanYongYe-Chang XiShanYongYe-Chang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wuyingjun-lucky Thanks~

Just a question: is the log format changed before and after the modification?

@@ -15,25 +15,15 @@ import (
_ "sigs.k8s.io/controller-runtime/pkg/metrics"

apiserver "k8s.io/apiserver/pkg/server"
"k8s.io/component-base/logs"
"k8s.io/component-base/cli"
_ "k8s.io/component-base/logs/json/register"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any comment for this import? Just like:

// for JSON log format registration

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wuyingjun-lucky Thanks~

Just a question: is the log format changed before and after the modification?

It seems no cli.RUN does not change the format
after:
image
before:
Uploading image.png…

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any comment for this import? Just like:

// for JSON log format registration

DONE

Signed-off-by: wuyingjun <wuyingjun_yewu@cmss.chinamobile.com>
@karmada-bot karmada-bot removed the lgtm Indicates that a PR is ready to be merged. label Jun 23, 2022
@lonelyCZ
Copy link
Member

Looks great. Thanks @wuyingjun-lucky

/lgtm

@karmada-bot karmada-bot added the lgtm Indicates that a PR is ready to be merged. label Jun 23, 2022
@RainbowMango
Copy link
Member

/approve

@karmada-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: RainbowMango

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm Indicates that a PR is ready to be merged. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants