[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Hari Prasanth Loganathan
okay, Thanks all for your help. On Thu, Jun 21, 2018 at 5:14 PM, Ondra Machacek wrote: > Well, if they may use 4.0, you should write code which support 4.0 and > don't use any 4.2 features, as it won't work anyway on 4.2. > > If you want to support features from 4.2, and use it against 4.0

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Ondra Machacek
Well, if they may use 4.0, you should write code which support 4.0 and don't use any 4.2 features, as it won't work anyway on 4.2. If you want to support features from 4.2, and use it against 4.0 where it will be igonored and use it also agains 4.2 where it will be supported, it's quite simple

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Greg Sheremeta
On Thu, Jun 21, 2018 at 7:05 AM Hari Prasanth Loganathan < hariprasant...@msystechnologies.com> wrote: > the problem is, I can't write different client codes for the different > version. > Well, you *can* with an if {} else {} It just sounds like you are choosing not too :) > Consider my case,

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Hari Prasanth Loganathan
the problem is, I can't write different client codes for the different version. Consider my case, I developed my script considering the oVirt version 4.2, If my client is using 4.1 then he needs the same script to be supported. What If the client is using further older version say 4.0, So do you

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Ondra Machacek
Well, I don't know what are you using to generate the JSON, but you just need to check if engine is v4.1 and then send the JSON without the field and if version is v4.2 and higher you can use that field. If you share you script maybe I can advice, or if you are using any SDK. It would be even

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Hari Prasanth Loganathan
Thanks, Ondra for confirming. You need to handle this situation client side. So you are saying there is a work-around in client side, I didn't get this point, Could you explain, please. On Thu, Jun 21, 2018 at 4:20 PM, Ondra Machacek wrote: > We do not support this. > > For xml we use event

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Ondra Machacek
We do not support this. For xml we use event handler, which takes unknown fields as error: https://github.com/oVirt/ovirt-engine/blob/68753f46f09419ddcdbb632453501273697d1a20/backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/xml/JAXBProvider.java#L182 For json

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-21 Thread Hari Prasanth Loganathan
Could somebody explain this please? On Thu, Jun 21, 2018 at 7:41 AM, Hari Prasanth Loganathan < hariprasant...@msystechnologies.com> wrote: > *Hi Ondra / Ori,* > > https://github.com/oVirt/ovirt-engine/search?q=FAIL_ON_ > UNKNOWN_PROPERTIES%2C+false%29%3B_q=FAIL_ON_ >

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-20 Thread Hari Prasanth Loganathan
*Hi Ondra / Ori,* https://github.com/oVirt/ovirt-engine/search?q=FAIL_ON_UNKNOWN_PROPERTIES%2C+false%29%3B_q=FAIL_ON_UNKNOWN_PROPERTIES%2C+false%29%3B Check the above link, As per the code it is always set as false, So is there a way in payload / headers in client API / server configuration in

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-20 Thread Greg Sheremeta
+Ondra and Ori On Wed, Jun 20, 2018 at 1:07 PM Hari Prasanth Loganathan < hariprasant...@msystechnologies.com> wrote: > Guys any update on this? if you have any clarification let me know please. > > Thanks > > On Wed, 20 Jun 2018 at 5:41 PM, Hari Prasanth Loganathan < >

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-20 Thread Hari Prasanth Loganathan
Guys any update on this? if you have any clarification let me know please. Thanks On Wed, 20 Jun 2018 at 5:41 PM, Hari Prasanth Loganathan < hariprasant...@msystechnologies.com> wrote: > Hi Team, > > I got one clue, using the code base : >

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-20 Thread Hari Prasanth Loganathan
Hi Team, I got one clue, using the code base : https://github.com/oVirt/ovirt-engine/blob/e2aad594a55c7272b513736616cb4b9841c2c43d/backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/serialization/json/JsonObjectDeserializer.java

[ovirt-users] Re: Ignore extra parameters in oVirt API

2018-06-20 Thread Hari Prasanth Loganathan
Hi all, To clarify my payload is like below, *Expected :* { "alias": "testdisk", "shareable": false, "storage_type": "cinder", "openstack_volume_type": { "name": "ceph" }, "description": "", "storage_domains": { "storage_domain": [{ "name":