jclouds-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Carlos Garcia Ibañez <Carlos.Gar...@EMEA.NEC.COM>
Subject RE: [jclouds-labs/abiquo] - Access to a Virtual Machine from the Volume entity
Date Thu, 24 Oct 2013 14:32:12 GMT
Sure it helps!
As soon as I have this implemented I'll create the pull request. Should I open an issue in
Jira for this?

From: Ignasi [mailto:ignasi.barrera@gmail.com]
Sent: jueves, 24 de octubre de 2013 16:14
To: Carlos Garcia Ibañez
Cc: <user@jclouds.incubator.apache.org>; dev@jclouds.incubator.apache.org
Subject: Re: [jclouds-labs/abiquo] - Access to a Virtual Machine from the Volume entity

Hi Carlos,

There is no such method in the Volume domain class. However, the AbiquoApi has a generic way
to retrieve arbitrary links links [1].
You could add the missing method to the Volume entity using that api in a similar way it is
done in the VirtualMachine object to get its parent Virtual Appliance [2].



[1] https://github.com/jclouds/jclouds-labs/blob/master/abiquo/src/main/java/org/jclouds/abiquo/AbiquoApi.java#L112-L122
[2] https://github.com/jclouds/jclouds-labs/blob/master/abiquo/src/main/java/org/jclouds/abiquo/domain/cloud/VirtualMachine.java#L249-L259

On 24 October 2013 16:06, Carlos Garcia Ibañez <Carlos.Garcia@emea.nec.com<mailto:Carlos.Garcia@emea.nec.com>>
Hi all.
I'm trying to retrieve the Virtual Machine a volume entity is attached to from the volume
object itself, but I cannot find any getVirtualMachine() method in this class. Nevertheless,
I've noticed that the Abiquo REST representation for an attached volume contains a link "virtualmachine"
that points to the corresponding virtual machine:

    <link href="http://x.x.x.x/api/cloud/virtualdatacenters/323/volumes/79737" rel="edit"
    <link href="http://x.x.x.x/api/cloud/virtualdatacenters/323/volumes/79737/action/initiatormappings"
rel="initiator mappings" type="application/vnd.abiquo.initiatormappings+xml"/>
    <link href="http://x.x.x.x/api/cloud/virtualdatacenters/323/tiers/1" rel="tier" title="Storage
SATA RAID 5" type="application/vnd.abiquo.tier+xml"/>
    <link href="http://x.x.x.x/api/cloud/virtualdatacenters/323/virtualappliances/286"
rel="virtualappliance" title="Virtual Appliance: 1" type="application/vnd.abiquo.virtualappliance+xml"/>
    <link href="http://x.x.x.x/api/cloud/virtualdatacenters/323" rel="virtualdatacenter"
title="andres.cuesta###NECMKPId###" type="application/vnd.abiquo.virtualdatacenter+xml"/>
    <link href="http://x.x.x.x/api/cloud/virtualdatacenters/323/virtualappliances/286/virtualmachines/426"
rel="virtualmachine" title="ABQ_54666a35-aa07-4303-9bc7-b6064d6875d0" type="application/vnd.abiquo.virtualmachine+xml"/>

I'd like to know if there is a standard way to access this information through the jclouds
framework. If not, I'd be glad to implement this functionality, as long as you give me some
hints about how to do it :)

Thanks a lot and kind regards.


Click here<https://www.mailcontrol.com/sr/AYox6Dh45YDGX2PQPOmvUmGqEHcKtgpyQ96plo2pgjeIQsKAoYoN8!FsZSp5MXJKMEPvcLww7UsX!sYT9IPN0A==>
to report this email as spam.

View raw message