Change in ovirt-engine[ovirt-engine-3.4]: restapi: Assure network existence when adding a vnic profile

iheim at redhat.com iheim at redhat.com
Tue Feb 11 14:24:34 UTC 2014


Itamar Heim has submitted this change and it was merged.

Change subject: restapi: Assure network existence when adding a vnic profile
......................................................................


restapi: Assure network existence when adding a vnic profile

In order to create a vnic profile, the user must provide
the network id to which he wishes to add the profile.
If a network cannot be obtained by the id, the parameters
should consider invalid and a proper message should be
returned.

The backend has logic for this scenario, however when performing
this action with a user that its permissions should be verified,
there is a generic "User is not authorized to perform this action"
even though the message refers to a non-existing network entity.

Change-Id: Ib517cc0fd04c4f0e12fd6bdbdca8c6277600e325
Bug-Url: https://bugzilla.redhat.com/1031369
Signed-off-by: Moti Asayag <masayag at redhat.com>
---
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendVnicProfilesResource.java
M backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/AbstractBackendVnicProfilesResourceTest.java
M backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendVnicProfilesResourceTest.java
3 files changed, 23 insertions(+), 0 deletions(-)

Approvals:
  Juan Hernandez: Looks good to me, approved
  Moti Asayag: Verified



-- 
To view, visit http://gerrit.ovirt.org/24327
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib517cc0fd04c4f0e12fd6bdbdca8c6277600e325
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.4
Gerrit-Owner: Moti Asayag <masayag at redhat.com>
Gerrit-Reviewer: Itamar Heim <iheim at redhat.com>
Gerrit-Reviewer: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Moti Asayag <masayag at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server



More information about the Engine-commits mailing list