From Juan Hernandez <juan.hernandez(a)redhat.com>:
Juan Hernandez has submitted this change and it was merged.
Change subject: restapi: Use ids to calculate intersections
......................................................................
restapi: Use ids to calculate intersections
Currently when the user uses together the 'filter' and 'search'
mechanisms, the server performs two queries: one with filter only, and
one with search only. Then the it calculates and returns the
intersection. But this intersection is calculated assuming that the
objects returned by both queries can be reliably compared using the
'equals' methods. This isn't true, in general. The net result is that
many times the intersection is empty, when it should't. To avoid that
issue this patch changes the server so that it compares the objects by
id, instead of using the 'equals' method.
Change-Id: Id6fd395ca3d3aea7ab2dcdcdf2438e4c487cfc1f
Bug-Url:
https://bugzilla.redhat.com/1402799
Signed-off-by: Juan Hernandez <juan.hernandez(a)redhat.com>
---
M
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractBackendCollectionResource.java
1 file changed, 49 insertions(+), 2 deletions(-)
Approvals:
Juan Hernandez: Verified; Looks good to me, approved; Passed CI tests
--
To view, visit
https://gerrit.ovirt.org/67526
To unsubscribe, visit
https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Id6fd395ca3d3aea7ab2dcdcdf2438e4c487cfc1f
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Juan Hernandez <juan.hernandez(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Juan Hernandez <juan.hernandez(a)redhat.com>
Gerrit-Reviewer: Ori Liel <oliel(a)redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>