Change in ovirt-engine[master]: restapi: Use "fromValue" in V3 adapters
juan.hernandez at redhat.com
juan.hernandez at redhat.com
Thu Mar 24 19:31:53 UTC 2016
Juan Hernandez has submitted this change and it was merged.
Change subject: restapi: Use "fromValue" in V3 adapters
......................................................................
restapi: Use "fromValue" in V3 adapters
The recent introduction of type safe enums in version 4 of the API
introduced a regression in the V3 adapters. These adapters convert the
strings used in V3 to the enums used in V4, but some of them do so using
the "valueOf" method of the enum types, wich expects strings exactly
equal to the enum values, and these values are all upper case. The API,
both V3 and V4, should ignore case of the strings, which is achieved
using the "fromValue" method. This changes all the V3 adapters to use
the "fromValue" method.
Change-Id: I0637285b60dc7030dcbfa65d97927978e05e839d
Bug-Url: https://bugzilla.redhat.com/1320964
Signed-off-by: Juan Hernandez <juan.hernandez at redhat.com>
---
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3AgentConfigurationInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3CPUInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3ConfigurationInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3DataCenterInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3DiskInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3DiskSnapshotInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3DisplayInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3EventInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3GlusterHookInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3GlusterServerHookInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3GlusterVolumeInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3GraphicsConsoleInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3GuestNicConfigurationInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3HardwareInformationInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3HostInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3HostNICInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3InstanceTypeInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3LogicalUnitInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3MethodInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3MigrationOptionsInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3NICInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3OpenStackNetworkProviderInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3OpenstackVolumeAuthenticationKeyInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3QoSInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3ReportedDeviceInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3SchedulingPolicyUnitInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3SnapshotInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3StepInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3StorageConnectionInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3StorageDomainInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3StorageInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3VMInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3VmPoolInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3VnicPassThroughInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3WatchDogInAdapter.java
35 files changed, 55 insertions(+), 55 deletions(-)
Approvals:
Juan Hernandez: Verified; Looks good to me, approved
Jenkins CI: Passed CI tests
--
To view, visit https://gerrit.ovirt.org/55230
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I0637285b60dc7030dcbfa65d97927978e05e839d
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Ori Liel <oliel at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>
More information about the Engine-commits
mailing list