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

mgr/dashboard: Hide maintenance option on expand cluster #46702

Merged
merged 1 commit into from Aug 22, 2022

Conversation

nizamial09
Copy link
Member

@nizamial09 nizamial09 commented Jun 15, 2022

Fixes: https://tracker.ceph.com/issues/56070
Signed-off-by: Nizamudeen A nia@redhat.com

Screenshot from 2022-06-16 00-20-54

Contribution Guidelines

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows

@nizamial09 nizamial09 requested a review from a team as a code owner June 15, 2022 18:54
@nizamial09 nizamial09 added this to In progress in Dashboard via automation Jun 15, 2022
@nizamial09 nizamial09 requested review from pereman2 and removed request for a team June 15, 2022 18:54
@nizamial09
Copy link
Member Author

jenkins retest this please

Comment on lines 83 to 84
<div class="form-group row"
*ngIf="pageURL === 'hosts'">
Copy link
Member

Choose a reason for hiding this comment

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

That's ok, but (personally) I think it's preferable that conditions express what's the underlying reason for doing something.

There are multiple ways:

  • For example, in the cluster expansion workflow, this component will be child/grandchild of the cluster expansion component, so if you inject that component in the constructor you'll be able to check that condition which really express why this is hidden (if parentIsClusterCreation then hide this).
  • Even better, you can extend the interface of the hosts page with a new argument: hideMaintenance or deploymentStage, etc...

IMHO all those checks (if parentIsClusterCreation, if hideMaintenance, if deploymentStage) better reflect the intention of this change.

Copy link
Contributor

Choose a reason for hiding this comment

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

I agree in this case.

Copy link
Member Author

Choose a reason for hiding this comment

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

done! can you guys please check it again @pereman2 @epuertat

Dashboard automation moved this from In progress to Reviewer approved Jun 16, 2022
@pereman2
Copy link
Contributor

jenkins test make check

Comment on lines 83 to 84
<div class="form-group row"
*ngIf="pageURL === 'hosts'">
Copy link
Contributor

Choose a reason for hiding this comment

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

I agree in this case.

@pereman2
Copy link
Contributor

jekins test dashboard cephadm

@pereman2
Copy link
Contributor

jenkins test make check

@nizamial09 nizamial09 force-pushed the expand-cluster-hide-maintenance branch from a662edd to d66bfe0 Compare August 10, 2022 08:25
Copy link
Contributor

@pereman2 pereman2 left a comment

Choose a reason for hiding this comment

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

works locally so lgtm

Copy link

@sunilangadi2 sunilangadi2 left a comment

Choose a reason for hiding this comment

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

changes LGTM.

@pereman2
Copy link
Contributor

jenkins test api

2 similar comments
@epuertat
Copy link
Member

jenkins test api

@nizamial09
Copy link
Member Author

jenkins test api

@pereman2 pereman2 merged commit cbe98b3 into ceph:main Aug 22, 2022
Dashboard automation moved this from Reviewer approved to Done Aug 22, 2022
@pereman2 pereman2 deleted the expand-cluster-hide-maintenance branch August 22, 2022 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Dashboard
  
Done
4 participants