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

add PlacementConditionMisconfigured #72

Merged

Conversation

haoqing0110
Copy link
Member

@haoqing0110 haoqing0110 commented Apr 28, 2022

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 31, 2022

@haoqing0110: PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.


if err != nil {
return nil, err
if status.Code() == framework.Error || status.Code() == framework.Misconfigured {
Copy link
Member

Choose a reason for hiding this comment

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

better to use switch

Type: clusterapiv1beta1.PlacementConditionMisconfigured,
Status: metav1.ConditionTrue,
Reason: "Misconfigured",
Message: "Placement configurations check failed",
Copy link
Member

Choose a reason for hiding this comment

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

message should add the plugin name


if err != nil {
return nil, err
if status.Code() == framework.Error || status.Code() == framework.Misconfigured {
Copy link
Member

Choose a reason for hiding this comment

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

switch

if status.Code() == framework.Error || status.Code() == framework.Misconfigured {
return nil, status
} else if status.Code() == framework.Warning {
finalStatus = status
Copy link
Member

Choose a reason for hiding this comment

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

add a warning log or a event for placement.

Signed-off-by: haoqing0110 <qhao@redhat.com>
Signed-off-by: haoqing0110 <qhao@redhat.com>
@haoqing0110 haoqing0110 changed the title [WIP] add PlacementConditionMisconfigured add PlacementConditionMisconfigured Sep 20, 2022
@qiujian16
Copy link
Member

/approve
It looks good to me. pass to @elgnay for review.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 21, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: haoqing0110, qiujian16

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

@elgnay
Copy link
Collaborator

elgnay commented Sep 21, 2022

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Sep 21, 2022
@openshift-merge-robot openshift-merge-robot merged commit 6b2c9ef into open-cluster-management-io:main Sep 21, 2022
@haoqing0110 haoqing0110 deleted the br_misconfig branch September 21, 2022 10:10
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.

None yet

4 participants