[ 
https://issues.apache.org/jira/browse/LIBCLOUD-372?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tomaz Muraus updated LIBCLOUD-372:
----------------------------------

    Component/s: Compute
    
> Issues with _get_network_href in VCloud driver
> ----------------------------------------------
>
>                 Key: LIBCLOUD-372
>                 URL: https://issues.apache.org/jira/browse/LIBCLOUD-372
>             Project: Libcloud
>          Issue Type: Bug
>          Components: Compute
>            Reporter: Tomaz Muraus
>
> (creating this ticket based on the IRC discussion from yesterday)
> Basically, in some cases driver checks for 
> "application/vnd.vmware.vcloud.orgNetwork+xml" type and in other for 
> "application/vnd.vmware.vcloud.Network+xml" (without .org suffix).
> Error: 
> https://gist.github.com/brianmingus/122f0665e51fc5998196/raw/a52114101e6f0046a61c579d12975505d70ffbbe/gistfile1.txt
> IRC log:
> {quote}
> [19:02] <   cortexman> | i think i found a bug in vcloud organization network 
> name setting: 
> https://gist.github.com/brianmingus/122f0665e51fc5998196/raw/a52114101e6f0046a61c579d12975505d70ffbbe/gistfile1.txt
> [19:02] <   cortexman> | the name is there in the xml output of debug mode, 
> but when I pass it, 
>           it fails to detect it
> [19:03] <@      Kami_> | the type attribute seems to be different
> [19:03] <@      Kami_> | if  l.attrib['type'] == 
> 'application/vnd.vmware.vcloud.orgNetwork+xml'\
> [19:03] <   cortexman> | yeah… hrm
> [19:04] <@      Kami_> | this seems wrong
> [19:04] <@      Kami_> | the type check
> [19:04] <@      Kami_> | since it's not consistent with other ones
> [19:04] <@      Kami_> | other ones don't have .org
> [19:04] <@      Kami_> | actually, some of them do
> [19:08] <@      Kami_> | cortexman: if you open a ticket, i'll ping michal 
> and sengor there
> [19:08] <@      Kami_> | cortexman: they both worked on the driver
> [19:09] <@      Kami_> | cortexman: i personally don't have a lot of 
> experience with vcloud so 
>           i'd rather not touch it too much :P
> [19:09] <@      Kami_> | cortexman: one thing we could do is check for both, 
> type with .org 
>           suffix and without it, but i'd rather do the right thing
> [19:09] <   cortexman> | well i think we can infer that it must be 
> inconsistent
> [19:09] <   cortexman> | so it should check for both
> [19:09] <@      Kami_> | i have no idea why some types have .org suffix and 
> some don't, could 
>           be a typo, could be a different version, different installation 
> dunno
> [19:14] <   cortexman> | blah
> [19:14] <   cortexman> | i have to bbl, but this random file I found encodes 
> them separately 
> http://andy.eduservlab.net/vcloud/php-sdk/docs/__filesource/fsource_VMware_VCloud_SDK__Constants.php.html
> [19:16] <@      Kami_> | cortexman: it seems like it also uses 
>           application/vnd.vmware.vcloud.orgNetwork+xml
> [19:17] <@      Kami_> | cortexman: but your response doesn't have .org 
> suffix so to me it 
>           seems like an issue with an installation
> [19:18] <@      Kami_> | in any case i find the xpath in libcloud weird
> [19:18] <@      Kami_> | instead of finding all the link elements, it should 
> just look for all 
>           Availablenetworks/Network elements
> [19:18] <@      Kami_> | then it doesn't need to do nasty / unecessary href 
> checking
> {quote}
> I don't have enough VCloud experience so I rather didn't touch the code. 
> I would love someone with more VCloud experience to chime in - I'm especially 
> interested why the driver is checking for the type XML attribute instead of 
> using a better xpath expression which would be less fragile and also allow us 
> to avoid this problem.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to