Add a generic "search by example" method for retrieving events to the AuditStore

Description

The AuditStore interface as developed for provides methods for accessing events by user or by entity.

Add a new method:

1 2 @Nonnull List<AuditEvent> getEvents(@Nullable AuditEvent eventTemplate, @Nullable Calendar fromTime, @Nullable Calendar toTime, long start, long count);

and implement it in HibernateAuditStore.

The event template can have non-null fields which are to be used as filters when retrieving matching events. If all fields are null or the template itself is null, all events match and should be returned. Parameters fromTime and toTime define an interval for the time stamp. If parameter fromTime is null, matching events from the beginning will be retrieved. If parameter toTime is null, matching events until the present moment will be retrieved.

Environment

None

Status

Assignee

Veronika Koltunova

Reporter

Marta Girdea

Labels

None

External issue ID

None

External issue ID

None

Fix versions

Priority

Medium
Configure