Alissa Bonas has uploaded a new change for review. Change subject: restapi: Fix not able to update non guid ids ......................................................................
restapi: Fix not able to update non guid ids Fixed the REST infrastructure to be able to accept non guid ids in "update" action of entities - use generic T instead of Guid. This change aligns the "update" behavior with the "add" action that already works this way and allows non guid ids. Change-Id: I4dbdca3fc820e7480d0bcffcec35568ee96b887d Signed-off-by: Alissa Bonas <[email protected]> --- M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractBackendSubResource.java 1 file changed, 4 insertions(+), 4 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/37/16837/1 diff --git a/backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractBackendSubResource.java b/backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractBackendSubResource.java index 55c54a0..cbedaf4 100644 --- a/backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractBackendSubResource.java +++ b/backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractBackendSubResource.java @@ -44,10 +44,10 @@ } } - protected final R performUpdate(R incoming, + protected final <T> R performUpdate(R incoming, Q entity, R model, - EntityIdResolver<Guid> entityResolver, + EntityIdResolver<T> entityResolver, VdcActionType update, ParametersProvider<R, Q> updateProvider) { @@ -71,8 +71,8 @@ return entity; } - protected R performUpdate(R incoming, - EntityIdResolver<Guid> entityResolver, + protected <T> R performUpdate(R incoming, + EntityIdResolver<T> entityResolver, VdcActionType update, ParametersProvider<R, Q> updateProvider) { Q entity = getEntity(entityResolver, true); -- To view, visit http://gerrit.ovirt.org/16837 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I4dbdca3fc820e7480d0bcffcec35568ee96b887d Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Alissa Bonas <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
