jclouds-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ignasi Barrera <n...@apache.org>
Subject Re: DiskCreationOptions is now abstract
Date Tue, 10 Mar 2015 07:45:55 GMT
You have to change the options creation to:
new DiskCreationOptions.Builder().sizeGb(...).build();

We are using Google Auto [1] for the domain model classes. The "Auto_"
class you see there is just an auto generated one.

HTH!

I.

[1] https://github.com/google/auto/tree/master/value
El 10/03/2015 05:24, "Ruben Rubio Rey" <tk421.1@gmail.com> escribió:

> Hi,
>
> Code changed a few days ago and this code does not work any more (GCE)
>
> DiskApi diskApi = gce.disksInZone(ZONE);
> URI diskType = new URI(baseZoneUri + "diskTypes/pd-" + volume.getType());
> diskApi.create(ATTACH_DISK_NAME, new DiskCreationOptions().sizeGb(Math.round(volume.getSize())).type(diskType));
>
> DiskCreationOptions is now abstract and cannot be instantiated. There is a
> new class
>
> final class AutoValue_DiskCreationOptions extends DiskCreationOptions {
>
> which is not public and cannot be used. I can't find this code in github
> to suggest a patch.
>
> Any ideas how to use now DiskCreationOptions ?
>
> Regards,
> Ruben
>
>
>

Mime
View raw message