-
Notifications
You must be signed in to change notification settings - Fork 304
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
NAS-131326 / 25.04 / Simplify HA upgrade logic + NAS-131325: system.reboot.info
and failover.reboot.info
methods and events
#10744
base: master
Are you sure you want to change the base?
Conversation
system.reboot.info
and failover.reboot.info
methods and eventssystem.reboot.info
and failover.reboot.info
methods and events
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #10744 +/- ##
==========================================
+ Coverage 80.27% 81.09% +0.81%
==========================================
Files 1571 1574 +3
Lines 51704 52180 +476
Branches 5838 5815 -23
==========================================
+ Hits 41507 42315 +808
+ Misses 10197 9865 -332
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks OK. I am getting the notification but a few points should be addressed
- I expected the dialog to be centered and follow the styles of webui's typical dialogs. However, it was stuck to the top right corner and looks weird.
- I expected there to be a "Reboot" button on the dialog itself that I can click and reboot right away. There's no action buttons on the notification dialog.
- The title can say "Reboot required" instead of "Reboot Info"
@@ -39,8 +39,19 @@ | |||
|
|||
<ix-truecommand-button></ix-truecommand-button> | |||
|
|||
@if (hasRebootRequiredReasons) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can make hasRebootRequiredReasons
a signal.
export const rebootInfoLoaded = createAction( | ||
'[Reboot Info API] Reboot Info Loaded', | ||
props<{ | ||
thisNodeInfo: SystemRebootInfo | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These keys should have reboot
keyword in there somewhere. They are not node-info. They are specifically node-reboot-info. So, just calling them thisNodeInfo
and otherNodeInfo
can cause confusion in the future.
(state) => state, | ||
); | ||
|
||
export const selectThisNodeInfo = createSelector( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here as well. Let's add reboot
keyword in the variable name so it's clear it's only the node specific reboot info.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The notification doesn't come up at all. See attached video.
Changes:
This PR contains changes for 2 tickets
NAS-131325:
system.reboot.info
andfailover.reboot.info
methods and eventshere's what's implemented for this ticket:
system.reboot.info
andfailover.reboot.info
based on whether system is HA licensed,(if there are items in the
reboot_required_reasons
field, the following dialog should appear)NAS-131326: Simplify HA upgrade logic
here's what's implemented for this ticket:
failover.upgrade_pending
andfailover.upgrade_finish
methods and events were removed, they are not necessary anymorefailover.upgrade
method and waits for middleware to upgrade both local and remote controllers, then reboots the remote controller and wait it to come online, then webUI will display a reboot reason (see pt "1" in the description of this PR)failover.become_passive
when the user is ready to reboot the local controller, and thus the upgrade will be finished.Testing:
NAS-131325:
system.reboot.info
andfailover.reboot.info
methods and eventsTo test the
system.reboot.info
andfailover.reboot.info
methods and events, follow these steps:Login into the HA-enabled server, for example at M40 (10.220.16.82)
Expected result: When logging into the HA system, a call to
failover.reboot.info
must be made, and then a subscription tofailover.reboot.info
. For non-HA - the same thing, onlysystem.reboot.info
.If the call response or subscription contains items in
reboot_required_reasons
, a dialog is shown with a proposal to restart the corresponding node.However, if the
failover.disabled.reasons
response contains reasons other thanMISMATCH_VERSIONS
,LOC_FIPS_REBOOT_REQ
orREM_FIPS_REBOOT_REQ
, the dialog is not shown.NAS-131326: Simplify HA upgrade logic
To test the
failover.upgrade
job, follow these steps:Now you can see the Reboot Info notification, shown in pt "1" of the description of this PR.
Downstream