Change in ovirt-engine[master]: core: evict event from cache when manually removed

mperina at redhat.com mperina at redhat.com
Tue Jul 12 06:52:26 UTC 2016


Martin Peřina has submitted this change and it was merged.

Change subject: core: evict event from cache when manually removed
......................................................................


core: evict event from cache when manually removed

When a event or alert is removed manually from the display in UI, we
should also evict the corresponding cache entry for events that have 6he
flood mechanism.
This patch evict the corresponding event from the cache when it is
manually deleted by the user.
This solves the following problem :

Event E1 with flood time of T1 is raised by the system
The issue is fixed by the application administrator
Event E1 is raised again within the T1 period

The bug was that the second event was suppressed by the flooding
mechanism since the cache still holds the first event.

In order to solve this BZ there was a need to add code to the
RemoveAuditLogByIdCommand to evict the event from the cache, this is
done by composing the cache key from the command using the information
from the event which is the candidate for the delete operation and
generating a this key with the sysadmin user.

Change-Id: I0e302aa0bb218f7986cac57b13a90f689d956e19
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1219147
Signed-off-by: emesika <emesika at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RemoveAuditLogByIdCommand.java
M backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dal/dbbroker/auditloghandling/AuditLogDirector.java
M backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dal/dbbroker/auditloghandling/TimeoutBase.java
3 files changed, 59 insertions(+), 9 deletions(-)

Approvals:
  Martin Peřina: Looks good to me, but someone else must approve
  Eli Mesika: Verified
  Jenkins CI: Passed CI tests
  Moti Asayag: Looks good to me, approved



-- 
To view, visit https://gerrit.ovirt.org/59979
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I0e302aa0bb218f7986cac57b13a90f689d956e19
Gerrit-PatchSet: 5
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Eli Mesika <emesika at redhat.com>
Gerrit-Reviewer: Eli Mesika <emesika at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Martin Peřina <mperina at redhat.com>
Gerrit-Reviewer: Moti Asayag <masayag at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>



More information about the Engine-commits mailing list