-
Notifications
You must be signed in to change notification settings - Fork 8
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
Notifications at cost and perf levels #175
Conversation
@dinogun |
5862129
to
e13d11f
Compare
Fixed conflicts |
|
||
const [showSuccessAlert, setShowSuccessAlert] = useState(false); | ||
const [alertMessage, setAlertMessage] = useState(''); | ||
const [notificationType, setNotificationType] = useState<alertVarient>('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.
Is it alertVariant ?
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.
this useState<alertVarient>
is the same type alertVarient
on line 98 hence the same spelling. (I guess the spelling i can correct to 'variant' at both places)
setNotificationType('info'); | ||
} | ||
else if (notification.type == "error"){ | ||
setNotificationType('danger'); |
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.
Any reason on setting a different value for notification type ?
If notification.type is "error" , why to set as "danger" instead of "error" itself ?
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.
patternfly has "info" and "Danger" as the notification variants while from the backend we get "notice" and "error", so over here im just trying to match the notification type from backend to the patternfly notifications. reference https://www.patternfly.org/components/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.
As I don't see warning and critical related notifications, can you please add them as well.
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.
Added
As discussed, we should be able to view all the notifications related to one recommendation at a time. |
here is the updated view of the ui with before (in perf tab) and after (in cost tab) link |
@kusumachalasani can u re-review the pr please. |
@bhanvimenghani I'm unable to view the video. It says 'may have been deleted or archived by its creator.' |
https://www.loom.com/share/08fdf9c9ec094c56a1996c1a075411f4?sid=11d5c43e-429b-452c-911f-78aacb954a9f |
image for testing |
Couldn't test with the image because of 'Unable to Generate Recommendations' error in openshift. |
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.
Approving, as the changes required per the comments can be addressed in the another PR.
This change would be part of a different sprint, out of scope for this pr |
ed2c4fa
to
4b34bf1
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.
LGTM
This pr adds alerts for over and under resource utilization in the UI. This pr has been made as per the json structure shared here. A demo video reflecting the changes is attached here