Change in ovirt-engine[master]: core: Fix JSON serialization for diskMap at VmTemplate
rgolan at redhat.com
rgolan at redhat.com
Tue Aug 13 09:41:49 UTC 2013
Roy Golan has submitted this change and it was merged.
Change subject: core: Fix JSON serialization for diskMap at VmTemplate
......................................................................
core: Fix JSON serialization for diskMap at VmTemplate
JSON de-serialization of java class with a member of an interface type
is loosing its concrete type due to erasure so
class A {
private Map x
}
is serialized to
A {
x {} <- x is considered an arbitraty object
}
and couldn't deserialized back to Map, throwing an error
while it should have been
private HashMap x
and then
A {
x: [ "java.util.HashMap" , { ... } ]
}
See Also - http://wiki.fasterxml.com/JacksonPolymorphicDeserialization
Change-Id: Ie56dca3f2cae063c28515e904d644a0f1f39feeb
Signed-off-by: Roy Golan <rgolan at redhat.com>
Bug-Url: https://bugzilla.redhat.com/996005
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ImportVmTemplateCommand.java
M backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/AddVmCommandTest.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmTemplate.java
3 files changed, 5 insertions(+), 6 deletions(-)
Approvals:
Roy Golan: Verified; Looks good to me, approved
--
To view, visit http://gerrit.ovirt.org/18001
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ie56dca3f2cae063c28515e904d644a0f1f39feeb
Gerrit-PatchSet: 4
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Roy Golan <rgolan at redhat.com>
Gerrit-Reviewer: Omer Frenkel <ofrenkel at redhat.com>
Gerrit-Reviewer: Roy Golan <rgolan at redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzaslavs at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
More information about the Engine-commits
mailing list