Bug 1687845 - Multiple notification for one time host activation
Summary: Multiple notification for one time host activation
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 4.2.8-3
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ovirt-4.5.0
: 4.5.0
Assignee: rszwajko
QA Contact: Ivana Saranova
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-03-12 13:30 UTC by Shivraj
Modified: 2022-05-26 16:22 UTC (History)
10 users (show)

Fixed In Version: ovirt-engine-4.5.0
Doc Type: Bug Fix
Doc Text:
Previously, displaying notifications for hosts activated from maintenance mode was done when the actual job activation "end time" was after the last displayed notification. But if there was a time difference between server and the browser, the job "end time" could be in the future. In this release, notifications rely only on the server time, and the job's "end time" is no longer compared to local browser time. As a result, only one "Finish activating host" notification appears.
Clone Of:
Environment:
Last Closed: 2022-05-26 16:22:26 UTC
oVirt Team: UX
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2022:4711 0 None None None 2022-05-26 16:22:59 UTC
oVirt gerrit 116758 0 master MERGED webadmin: prevent multiple notificatons 2021-10-26 12:45:44 UTC

Description Shivraj 2019-03-12 13:30:55 UTC
Description of problem:

When customer activates the host in the maintenance mode, it causes multiple notification pop-ups in RHV admin portal.

Though pop-ups are cosmetic but those extra pop-ups are annoying while working in admin portal.


Version-Release number of selected component (if applicable):

RHEL 7.6
rhvm-4.2.8.3-0.1.el7ev.noarch
The client OS - Windows 2008 R2
Browser version - Firefox 64.0.2

(For this user it was happening since RHV4.1, but they raised the concerns now)

How reproducible:


Steps to Reproduce:

1. Put the host in maintenance mode.
2. Activate the host in maintenance mode.


Actual results:
Multiple pop-ups appear for single event.

Expected results:

There should be a single pop-up for single event.


Additional info:

1. Restarting ovirt-engine service does not help.
2. Temporary workaround is to stop this notifications pop-up by using "Do Not Disturb" button above the notifications.
But customer interested in permanent solution.
3. These pop-ups are not infinite, they stop after 20 or so of them appear and they disappear by themselves except one.

Comment 3 Martin Perina 2019-03-12 16:27:47 UTC
I'm almost sure we are not created mutliple audit log events for signle activation, so it seems to me like UI code issue.

Comment 7 Daniel Gur 2019-08-28 13:14:30 UTC
sync2jira

Comment 8 Daniel Gur 2019-08-28 13:19:32 UTC
sync2jira

Comment 11 Dana 2021-05-25 09:07:28 UTC
I have set https://github.com/oVirt/ovirt-engine/blob/7002b8bf78c44e7b5ea60896306905812e47430d/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java#L1664 to true so that messages will be logged in the db even when the host's status is unassigned (https://github.com/oVirt/ovirt-engine/blob/e84e4831d7dc679e1e7969fbffa559715a43524b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/InitVdsOnUpCommand.java#L414)
The last message in the db related to host deploy is-
log_type_name       | VDS_DETECTED
message             | Status of host node01 was set to Up.
and it appears once, so it looks like this can be an issue with multiple queries of the job in the UI part

Comment 12 Martin Perina 2021-05-26 09:28:35 UTC
As mentioned above we were not able to reproduce the issue, where single event is store multiple times in audit_log table. Also the raised multiple notification about "Finished Activating Host" is not part of audit_log, but it's a result of quering status of a job. So the problem is somewhere in GWT code which is quering jobs and displaying those notifications. Those notification popups were introduced by UX team, so Sharon could you please take over the bug?

Comment 15 rszwajko 2021-09-16 13:16:56 UTC
This seems a regression after BZ [1]. The fix provided there added explicitly an exception for activating host from maintenance mode. To prevent displaying multiple notifications a timestamp was used. However it seems that in some cases the time resolution is too low - check my comment [2] for details. The general rule seems to work well for all other types of notifications.

[1] https://bugzilla.redhat.com/show_bug.cgi?id=1471082
[2] https://gerrit.ovirt.org/c/ovirt-engine/+/82714/5/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/presenter/overlay/TasksPresenterWidget.java#74

Comment 16 rszwajko 2021-09-21 08:01:59 UTC
Problem is triggered by time difference between client and server.

Steps to re-create:
1. adjust clock on the client - move it back to be 2 min earlier then server clock
2. move host to maintenance
3. activate the host
Result: notifications are being displayed for ca 2 min

Comment 20 Ivana Saranova 2022-04-20 13:07:44 UTC
Steps 1:

1. Put the host in maintenance mode.
2. Activate the host in maintenance mode.


Steps 2:
1. adjust clock on the client - move it back to be 2 min earlier then server clock
2. move host to maintenance
3. activate the host

Results:
I was not able to reproduce the issue with either duplicate events or prolonged notifications.

Verified in:
ovirt-engine-4.5.0.2-0.7.el8ev.noarch

Comment 25 errata-xmlrpc 2022-05-26 16:22:26 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: RHV Manager (ovirt-engine) [ovirt-4.5.0] security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2022:4711


Note You need to log in before you can comment on or make changes to this bug.