Juan Hernandez has posted comments on this change.
Change subject: restapi: Add support for JAXB annotions in JSON
......................................................................
Patch Set 1:
Yes, the nulls can be avoided with that property, this is how it looks like:
{
"cluster" : [ {
"data_center" : {
"href" : "/api/datacenters/5849b030-626e-47cb-ad90-3ce782d831b3",
"id" : "5849b030-626e-47cb-ad90-3ce782d831b3"
},
"memory_policy" : {
"overcommit" : {
"percent" : 100
},
"transparent_hugepages" : {
"enabled" : true
}
},
"scheduling_policy" : {
"policy" : "none"
},
"version" : {
"major" : 3,
"minor" : 3
},
"error_handling" : {
"on_error" : "migrate"
},
"virt_service" : true,
"gluster_service" : false,
"threads_as_cores" : false,
"tunnel_migration" : false,
"trusted_service" : false,
"ballooning_enabled" : false,
"name" : "Default",
"description" : "The default server cluster",
"href" : "/api/clusters/99408929-82cf-4dc7-a532-9d998063fa95",
"id" : "99408929-82cf-4dc7-a532-9d998063fa95",
"link" : [ {
"href" : "/api/clusters/99408929-82cf-4dc7-a532-9d998063fa95/networks",
"rel" : "networks"
}, {
"href" :
"/api/clusters/99408929-82cf-4dc7-a532-9d998063fa95/permissions",
"rel" : "permissions"
}, {
"href" :
"/api/clusters/99408929-82cf-4dc7-a532-9d998063fa95/glustervolumes",
"rel" : "glustervolumes"
}, {
"href" :
"/api/clusters/99408929-82cf-4dc7-a532-9d998063fa95/glusterhooks",
"rel" : "glusterhooks"
} ]
} ]
}
However my question was if we actually want to do it. I will update a new patch
set with that behavior.
I didn't test yet to deserialize.
--
To view, visit http://gerrit.ovirt.org/20093
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ica39bbedd427dbf2f298b1292fe9a14f3825d6e5
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Juan Hernandez <[email protected]>
Gerrit-Reviewer: Juan Hernandez <[email protected]>
Gerrit-Reviewer: Michael Pasternak <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches