-
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
HPCC-30612 Warn user when Platform is too old #18031
HPCC-30612 Warn user when Platform is too old #18031
Conversation
https://track.hpccsystems.com/browse/HPCC-30612 |
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.
@GordonSmith Saw a couple of spots that I wasn't sure if the Dates might be invalid, if stuff was undefined?
esp/src/src-react/hooks/platform.ts
Outdated
setPoint(response?.BuildVersionPoint); | ||
setVersion(response?.BuildVersion); | ||
setMaturity(response?.BuildMaturity); | ||
setTimestamp(new Date(response?.BuildTagTimestamp)); |
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.
I think this could be an invalid date if BuildTagTimestamp were undefined
|
||
const DAY = 1000 * 60 * 60 * 24; | ||
platformModule.fetchCheckFeatures().then(function (features) { | ||
const age = Math.floor((Date.now() - new Date(features.BuildTagTimestamp).getTime()) / DAY); |
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.
If features didn't come back for some reason, might have an invalid date here also, and a NaN for age.
769732b
to
d810695
Compare
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.
@GordonSmith Looks good. A couple of comments on the message, and one on colouring (can ignore that one).
const message = nlsHPCC.PlatformIsNNNDaysOld.replace("NNN", `${age}`); | ||
let severity = "Info"; | ||
if (age > 90) { | ||
severity = "Alert"; |
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 colouring of alerts in the old eclwatch looks less important than errors,
esp/src/src/nls/hpcc.ts
Outdated
@@ -639,6 +641,7 @@ export = { | |||
PlaceholderFirstName: "John", | |||
PlaceholderLastName: "Smith", | |||
Platform: "Platform", | |||
PlatformIsNNNDaysOld: "Platform is NNN days old", |
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.
Suggest reword to
"Platform build is NNN days old."
Once it is reported as a warning it should be
"Platform build is NNN days old. Please upgrade to a later point release."
to make it clear that it isn't the version we are complaining about, and how to resolve it.
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.
Possibly add "(See About/Latest Releases for details.)"
Update warning messages Switch to Alert from Critical in v9 ECL Watch
@ghalliday - updated with (most) of the suggestions. |
9d9c3d9
into
hpcc-systems:candidate-8.12.x
Type of change:
Checklist:
Smoketest:
Testing: