diff --git a/apis/ec2/src/main/java/org/jclouds/ec2/compute/domain/EC2HardwareBuilder.java b/apis/ec2/src/main/java/org/jclouds/ec2/compute/domain/EC2HardwareBuilder.java index bb8fc675aa..367a4f49d4 100644 --- a/apis/ec2/src/main/java/org/jclouds/ec2/compute/domain/EC2HardwareBuilder.java +++ b/apis/ec2/src/main/java/org/jclouds/ec2/compute/domain/EC2HardwareBuilder.java @@ -238,6 +238,33 @@ public class EC2HardwareBuilder extends HardwareBuilder { .processors(ImmutableList.of(new Processor(1.0, 1.0))).rootDeviceType(RootDeviceType.EBS); } + /** + * @see InstanceType#T2_MICRO + */ + public static EC2HardwareBuilder t2_micro() { + return new EC2HardwareBuilder(InstanceType.T2_MICRO) + .ram(1024) + .processors(ImmutableList.of(new Processor(1.0, 0.1))).rootDeviceType(RootDeviceType.EBS); + } + + /** + * @see InstanceType#T2_SMALL + */ + public static EC2HardwareBuilder t2_small() { + return new EC2HardwareBuilder(InstanceType.T2_SMALL) + .ram(2048) + .processors(ImmutableList.of(new Processor(1.0, 0.2))).rootDeviceType(RootDeviceType.EBS); + } + + /** + * @see InstanceType#T2_MEDIUM + */ + public static EC2HardwareBuilder t2_medium() { + return new EC2HardwareBuilder(InstanceType.T2_MEDIUM) + .ram(4096) + .processors(ImmutableList.of(new Processor(1.0, 0.4))).rootDeviceType(RootDeviceType.EBS); + } + /** * @see InstanceType#M1_LARGE */ @@ -589,7 +616,68 @@ public class EC2HardwareBuilder extends HardwareBuilder { .volumes(all24Volumes.build()) .virtualizationType(VirtualizationType.HVM); } - + + /** + * @see InstanceType#R3_LARGE + */ + public static EC2HardwareBuilder r3_large() { + return new EC2HardwareBuilder(InstanceType.R3_LARGE) + .ram(15616) + .processors(ImmutableList.of(new Processor(2.0, 2.5))) + .volumes(ImmutableList. of( + new VolumeBuilder().type(LOCAL).size(10.0f).device("/dev/sda1").bootDevice(true).durable(false).build(), + new VolumeBuilder().type(LOCAL).size(32.0f).device("/dev/sdb").bootDevice(false).durable(false).build())); + } + + /** + * @see InstanceType#R3_XLARGE + */ + public static EC2HardwareBuilder r3_xlarge() { + return new EC2HardwareBuilder(InstanceType.R3_XLARGE) + .ram(31232) + .processors(ImmutableList.of(new Processor(4.0, 2.5))) + .volumes(ImmutableList. of( + new VolumeBuilder().type(LOCAL).size(10.0f).device("/dev/sda1").bootDevice(true).durable(false).build(), + new VolumeBuilder().type(LOCAL).size(80.0f).device("/dev/sdb").bootDevice(false).durable(false).build())); + } + + /** + * @see InstanceType#R3_2XLARGE + */ + public static EC2HardwareBuilder r3_2xlarge() { + return new EC2HardwareBuilder(InstanceType.R3_2XLARGE) + .ram(62464) + .processors(ImmutableList.of(new Processor(8.0, 2.5))) + .volumes(ImmutableList. of( + new VolumeBuilder().type(LOCAL).size(10.0f).device("/dev/sda1").bootDevice(true).durable(false).build(), + new VolumeBuilder().type(LOCAL).size(160.0f).device("/dev/sdb").bootDevice(false).durable(false).build())); + } + + /** + * @see InstanceType#R3_4XLARGE + */ + public static EC2HardwareBuilder r3_4xlarge() { + return new EC2HardwareBuilder(InstanceType.R3_4XLARGE) + .ram(124928) + .processors(ImmutableList.of(new Processor(16.0, 2.5))) + .volumes(ImmutableList. of( + new VolumeBuilder().type(LOCAL).size(10.0f).device("/dev/sda1").bootDevice(true).durable(false).build(), + new VolumeBuilder().type(LOCAL).size(320.0f).device("/dev/sdb").bootDevice(false).durable(false).build())); + } + + /** + * @see InstanceType#R3_8XLARGE + */ + public static EC2HardwareBuilder r3_8xlarge() { + return new EC2HardwareBuilder(InstanceType.R3_8XLARGE) + .ram(249856) + .processors(ImmutableList.of(new Processor(32.0, 2.5))) + .volumes(ImmutableList. of( + new VolumeBuilder().type(LOCAL).size(10.0f).device("/dev/sda1").bootDevice(true).durable(false).build(), + new VolumeBuilder().type(LOCAL).size(320.0f).device("/dev/sdb").bootDevice(false).durable(false).build(), + new VolumeBuilder().type(LOCAL).size(320.0f).device("/dev/sdc").bootDevice(false).durable(false).build())); + } + @SuppressWarnings("unchecked") @Override public Hardware build() { diff --git a/apis/ec2/src/main/java/org/jclouds/ec2/domain/InstanceType.java b/apis/ec2/src/main/java/org/jclouds/ec2/domain/InstanceType.java index b57811c16d..b650063a1a 100644 --- a/apis/ec2/src/main/java/org/jclouds/ec2/domain/InstanceType.java +++ b/apis/ec2/src/main/java/org/jclouds/ec2/domain/InstanceType.java @@ -40,6 +40,39 @@ public class InstanceType { public static final String T1_MICRO = "t1.micro"; /** + * Micro Burstable Performance Instance + *
    + *
  • 1 GB memory
  • + *
  • 1 vCPU / 10% baseline performance
  • + *
  • No instance storage (EBS storage only)
  • + *
  • 64-bit platform
  • + *
+ */ + public static final String T2_MICRO = "t2.micro"; + + /** + * Micro Burstable Performance Instance + *
    + *
  • 2 GB memory
  • + *
  • 1 vCPU / 20% baseline performance
  • + *
  • No instance storage (EBS storage only)
  • + *
  • 64-bit platform
  • + *
+ */ + public static final String T2_SMALL = "t2.small"; + + /** + * Micro Burstable Performance Instance + *
    + *
  • 4 GB memory
  • + *
  • 2 vCPU / 40% baseline performance
  • + *
  • No instance storage (EBS storage only)
  • + *
  • 64-bit platform
  • + *
+ */ + public static final String T2_MEDIUM = "t2.medium"; + + /** * Small Instance *
    *
  • 1.7 GB memory
  • @@ -385,4 +418,63 @@ public class InstanceType { *
*/ public static final String I2_8XLARGE = "i2.8xlarge"; + + + /** + * R3 Large Memory Optimized + *
    + *
  • 15.25 GB memory
  • + *
  • 2 vCPU
  • + *
  • 1 SSD-based volume with 32 GiB of instance storage
  • + *
  • 64-bit platform
  • + *
+ */ + public static final String R3_LARGE = "r3.large"; + + /** + * R3 Extra Large Memory Optimized + *
    + *
  • 30.5 GB memory
  • + *
  • 4 vCPU
  • + *
  • 1 SSD-based volume with 80 GiB of instance storage
  • + *
  • 64-bit platform
  • + *
+ */ + public static final String R3_XLARGE = "r3.xlarge"; + + /** + * R3 Double Extra Large Memory Optimized + *
    + *
  • 61 GB memory
  • + *
  • 8 vCPU
  • + *
  • 1 SSD-based volume with 160 GiB of instance storage
  • + *
  • 64-bit platform
  • + *
  • Network Performance: High
  • + *
+ */ + public static final String R3_2XLARGE = "r3.2xlarge"; + + /** + * R3 Quadruple Extra Large Memory Optimized + *
    + *
  • 122 GB memory
  • + *
  • 16 vCPU
  • + *
  • 1 SSD-based volume with 320 GiB of instance storage
  • + *
  • 64-bit platform
  • + *
  • Network Performance: High
  • + *
+ */ + public static final String R3_4XLARGE = "r3.4xlarge"; + + /** + * R3 Octuple Extra Large Memory Optimized + *
    + *
  • 244 GB memory
  • + *
  • 32 vCPU
  • + *
  • 2 SSD-based volumes with 320 GiB of instance storage
  • + *
  • 64-bit platform
  • + *
  • Network Performance: 10 Gigabit
  • + *
+ */ + public static final String R3_8XLARGE = "r3.8xlarge"; } diff --git a/providers/aws-ec2/src/main/java/org/jclouds/aws/ec2/compute/suppliers/AWSEC2HardwareSupplier.java b/providers/aws-ec2/src/main/java/org/jclouds/aws/ec2/compute/suppliers/AWSEC2HardwareSupplier.java index d0b68263fc..6723b27910 100644 --- a/providers/aws-ec2/src/main/java/org/jclouds/aws/ec2/compute/suppliers/AWSEC2HardwareSupplier.java +++ b/providers/aws-ec2/src/main/java/org/jclouds/aws/ec2/compute/suppliers/AWSEC2HardwareSupplier.java @@ -45,6 +45,14 @@ import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m3_large; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m3_medium; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m3_xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.t1_micro; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.t2_micro; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.t2_small; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.t2_medium; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.r3_large; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.r3_xlarge; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.r3_2xlarge; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.r3_4xlarge; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.r3_8xlarge; import java.util.Set; @@ -83,6 +91,9 @@ public class AWSEC2HardwareSupplier extends EC2HardwareSupplier { sizes.add(g2_2xlarge().supportsImageIds(ccAmis).build()); sizes.add(t1_micro().build()); + sizes.add(t2_micro().build()); + sizes.add(t2_small().build()); + sizes.add(t2_medium().build()); sizes.add(c1_medium().build()); sizes.add(c1_xlarge().build()); sizes.add(c3_large().build()); @@ -105,6 +116,11 @@ public class AWSEC2HardwareSupplier extends EC2HardwareSupplier { sizes.add(m3_large().build()); sizes.add(m3_xlarge().build()); sizes.add(m3_2xlarge().build()); + sizes.add(r3_large().build()); + sizes.add(r3_xlarge().build()); + sizes.add(r3_2xlarge().build()); + sizes.add(r3_4xlarge().build()); + sizes.add(r3_8xlarge().build()); return sizes.build(); }