[ovirt-devel] Re: PROBLEM: Unable to retrieve value for MTU when default is used

2019-09-26 Thread Jamie Holohan
Ok thanks
___
Devel mailing list -- devel@ovirt.org
To unsubscribe send an email to devel-le...@ovirt.org
Privacy Statement: https://www.ovirt.org/site/privacy-policy/
oVirt Code of Conduct: 
https://www.ovirt.org/community/about/community-guidelines/
List Archives: 
https://lists.ovirt.org/archives/list/devel@ovirt.org/message/6NRCUEY4HPQVNP2CY7IIF5G7LBR3LDPC/


[ovirt-devel] Re: PROBLEM: Unable to retrieve value for MTU when default is used

2019-09-26 Thread Jamie Holohan
The network object created can be seen in the debugger, the value for "mtu" is 
"0", when the default should be 1500. The web portal shows the default value is 
"1500". When I try to retrieve the default value, it returns 0. However, if the 
value is explicitly stated, then it can be retrieved:

net = {NetworkContainer@4322} 
 display = null
 dnsResolverConfiguration = null
 ip = null
 mtu = {BigInteger@4369} "0"
 profileRequired = null
 required = null
 status = null
 stp = {Boolean@4370} false
 usages = {ArrayList@4371}  size = 0
 vlan = {VlanContainer@4372} 
 cluster = null
 dataCenter = {DataCenterContainer@4373} 
 externalProvider = null
 externalProviderPhysicalNetwork = null
 networkLabels = {ArrayListWithHref@4374}  size = 0
 permissions = {ArrayListWithHref@4375}  size = 0
 qos = null
 vnicProfiles = {ArrayListWithHref@4376}  size = 0
 comment = "comment"
 description = "description"
 href = "/ovirt-engine/api/networks/cb3909d1-28e7-4ff1-aa97-858286e407a6"
 id = "cb3909d1-28e7-4ff1-aa97-858286e407a6"
 name = "network1"
___
Devel mailing list -- devel@ovirt.org
To unsubscribe send an email to devel-le...@ovirt.org
Privacy Statement: https://www.ovirt.org/site/privacy-policy/
oVirt Code of Conduct: 
https://www.ovirt.org/community/about/community-guidelines/
List Archives: 
https://lists.ovirt.org/archives/list/devel@ovirt.org/message/SZZZ5OQN35TX77VQC3ZQBP3X6FNQAVL4/


[ovirt-devel] Re: PROBLEM: Unable to retrieve value for MTU when default is used

2019-09-26 Thread Ales Musil
Hi,

default MTU is internally represented as 0 and thus the value you are
receiving is correct.

On Thu, Sep 26, 2019 at 10:17 AM  wrote:

> I'm trying to automate a test which checks that the default values are
> being set correctly when adding a network to a host. When I create a
> network without specifying a value for the MTU, I can see from the web UI
> that the default value (1500) is being used.
>
> When I try to retrieve this MTU value from the SDK to ensure it is set
> correctly, the value returned is '0'.
>
> The same issue is not occurring if I explicitly set the MTU value when
> creating the network. When the MTU value is assigned, instead of using the
> default value, it is possible to retrieve it from the SDK correctly.
>
> Is there any way I can retrieve the value for MTU from the SDK when the
> default is used?
> ___
> Devel mailing list -- devel@ovirt.org
> To unsubscribe send an email to devel-le...@ovirt.org
> Privacy Statement: https://www.ovirt.org/site/privacy-policy/
> oVirt Code of Conduct:
> https://www.ovirt.org/community/about/community-guidelines/
> List Archives:
> https://lists.ovirt.org/archives/list/devel@ovirt.org/message/BH72BEIAYKLEXQKRMCYPSH3D44FBY5BJ/
>


-- 

Ales Musil

Associate Software Engineer - RHV Network

Red Hat EMEA 

amu...@redhat.comIM: amusil

___
Devel mailing list -- devel@ovirt.org
To unsubscribe send an email to devel-le...@ovirt.org
Privacy Statement: https://www.ovirt.org/site/privacy-policy/
oVirt Code of Conduct: 
https://www.ovirt.org/community/about/community-guidelines/
List Archives: 
https://lists.ovirt.org/archives/list/devel@ovirt.org/message/OO4XW5ML6ESU4H5JOZCLNJ7KP6ZCRRPU/


[ovirt-devel] Re: PROBLEM: Unable to retrieve value for MTU when default is used

2019-09-26 Thread Jamie Holohan
Here is a sample of the code used in the network builder. Notice the double 
slashes (//) before the .mtu(), hence no value is being stated so that the 
default is used.

 //Configure initial network builder with empty name field
NetworkBuilder networkBuilder = new NetworkBuilder()
.name(EMPTY_NETWORK_NAME)
//.mtu()
.dataCenter(dataCenter()
.name(dcName))
.usages(netUsageList)
.ip(
ip()
.version(IpVersion.V4)
.netmask(netMask)
.gateway(netGateway))

.dnsResolverConfiguration(
dnsResolverConfiguration()
.nameServers(dnsName));
___
Devel mailing list -- devel@ovirt.org
To unsubscribe send an email to devel-le...@ovirt.org
Privacy Statement: https://www.ovirt.org/site/privacy-policy/
oVirt Code of Conduct: 
https://www.ovirt.org/community/about/community-guidelines/
List Archives: 
https://lists.ovirt.org/archives/list/devel@ovirt.org/message/VSIQUZZM62LKY3JX3OJQ54FQ3ZQYMRLK/