From 9b5bc074957e715a77e3c7e07279af2e401f072b Mon Sep 17 00:00:00 2001 From: Vadas Gintautas Date: Wed, 13 Feb 2013 15:00:57 -0500 Subject: [PATCH] update hardware specs update hardware specs fix hardware ccami support update hardware specs update hardware specs fix hardware ccami support --- .../compute/domain/EC2HardwareBuilder.java | 40 +++++++++++++++++-- .../org/jclouds/ec2/domain/InstanceType.java | 36 ++++++++++++++++- .../suppliers/AWSEC2HardwareSupplier.java | 7 +++- 3 files changed, 77 insertions(+), 6 deletions(-) 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 a26f555e5e..35df073e2c 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 @@ -43,6 +43,8 @@ import org.jclouds.ec2.domain.VirtualizationType; import com.google.common.base.Predicate; import com.google.common.base.Predicates; import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableList.Builder; +import com.google.common.collect.ImmutableSet; /** * @@ -294,7 +296,23 @@ public class EC2HardwareBuilder extends HardwareBuilder { ImmutableList. of(new VolumeImpl(10.0f, "/dev/sda1", true, false), new VolumeImpl(840.0f, "/dev/sdb", false, false), new VolumeImpl(840.0f, "/dev/sdc", false, false))).is64Bit(true); } + + /** + * @see InstanceType#M3_XLARGE + */ + public static EC2HardwareBuilder m3_xlarge() { + return new EC2HardwareBuilder(InstanceType.M3_XLARGE).ram(15360) + .processors(ImmutableList.of(new Processor(4.0, 3.25))).rootDeviceType(RootDeviceType.EBS).is64Bit(true); + } + /** + * @see InstanceType#M3_2XLARGE + */ + public static EC2HardwareBuilder m3_2xlarge() { + return new EC2HardwareBuilder(InstanceType.M3_2XLARGE).ram(30720) + .processors(ImmutableList.of(new Processor(8.0, 3.25))).rootDeviceType(RootDeviceType.EBS).is64Bit(true); + } + /** * @see InstanceType#C1_MEDIUM */ @@ -355,11 +373,27 @@ public class EC2HardwareBuilder extends HardwareBuilder { public static EC2HardwareBuilder hi1_4xlarge() { return new EC2HardwareBuilder(InstanceType.HI1_4XLARGE) .ram(60 * 1024 + 512) - .processors(ImmutableList.of(new Processor(8.0, 5.5), new Processor(8.0, 5.5))) + .processors(ImmutableList.of(new Processor(16.0, 2.1875))) .volumes(ImmutableList. of(new VolumeImpl(1024.0f, "/dev/sda1", true, false), - new VolumeImpl(1024.0f, "/dev/sdb", false, false))); + new VolumeImpl(1024.0f, "/dev/sdb", false, false))) + .virtualizationType(VirtualizationType.HVM); } - + + public static EC2HardwareBuilder hs1_8xlarge() { + float twoTB = 2048.0f * 1024.0f; + Builder all24Volumes = ImmutableList.builder(); + all24Volumes.add(new VolumeImpl(twoTB, "/dev/sda1", true, false)); + for (char letter : ImmutableSet.of('b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', + 'q', 'r', 's', 't', 'u', 'v', 'w', 'x')) { + all24Volumes.add(new VolumeImpl(twoTB, "/dev/sd" + letter, false, false)); + } + return new EC2HardwareBuilder(InstanceType.HS1_8XLARGE) + .ram(117 * 1024) + .processors(ImmutableList.of(new Processor(16.0, 2.1875))) + .volumes(all24Volumes.build()) + .virtualizationType(VirtualizationType.HVM); + } + @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 bb7dec550b..acac242d1b 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 @@ -18,8 +18,6 @@ */ package org.jclouds.ec2.domain; -import org.jclouds.ec2.EC2AsyncClient; - /** * * The type of the instance. Description accurate as of 8-15-2009 release. @@ -121,6 +119,28 @@ public class InstanceType { * */ public static final String M2_4XLARGE = "m2.4xlarge"; + /** + * M3 Extra Large Instance + *
    + *
  • 15 GiB memory
  • + *
  • 13 EC2 Compute Units (4 virtual cores with 3.25 EC2 Compute Units each)
  • + *
  • EBS storage only
  • + *
  • 64-bit platform
  • + *
  • I/O Performance: Moderate
  • + *
+ */ + public static final String M3_XLARGE = "m3.xlarge"; + /** + * M3 Double Extra Large Instance + *
    + *
  • 30 GiB memory
  • + *
  • 26 EC2 Compute Units (8 virtual cores with 3.25 EC2 Compute Units each)
  • + *
  • EBS storage only
  • + *
  • 64-bit platform
  • + *
  • I/O Performance: High
  • + *
+ */ + public static final String M3_2XLARGE = "m3.2xlarge"; /** * High-CPU Medium Instance *
    @@ -199,4 +219,16 @@ public class InstanceType { */ public static final String HI1_4XLARGE = "hi1.4xlarge"; + /** + * High Storage Eight Extra Large + *
      + *
    • 117 GiB of memory
    • + *
    • 35 EC2 Compute Units (16 virtual cores*)
    • + *
    • 24 hard disk drives each with 2 TB of instance storage
    • + *
    • 64-bit platform
    • + *
    • I/O Performance: Very High (10 Gigabit Ethernet)
    • + *
    • Storage I/O Performance: Very High**
    • + *
    + */ + public static final String HS1_8XLARGE = "hs1.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 a20f3d32ab..5e5d23136e 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 @@ -24,6 +24,7 @@ import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.cc1_4xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.cc2_8xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.cg1_4xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.hi1_4xlarge; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.hs1_8xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_large; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_medium; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_small; @@ -31,6 +32,8 @@ import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m2_2xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m2_4xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m2_xlarge; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m3_xlarge; +import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m3_2xlarge; import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.t1_micro; import java.util.Set; @@ -65,9 +68,11 @@ public class AWSEC2HardwareSupplier extends EC2HardwareSupplier { sizes.add(cc1_4xlarge().supportsImageIds(ccAmis).build()); sizes.add(cg1_4xlarge().supportsImageIds(ccAmis).build()); sizes.add(cc2_8xlarge().supportsImageIds(ccAmis).build()); + sizes.add(hi1_4xlarge().supportsImageIds(ccAmis).build()); + sizes.add(hs1_8xlarge().supportsImageIds(ccAmis).build()); sizes.addAll(ImmutableSet. of(t1_micro().build(), c1_medium().build(), c1_xlarge().build(), m1_large() .build(), m1_small().build(), m1_medium().build(), m1_xlarge().build(), m2_xlarge().build(), - m2_2xlarge().build(), m2_4xlarge().build(), hi1_4xlarge().build())); + m2_2xlarge().build(), m2_4xlarge().build(), m3_xlarge().build(), m3_2xlarge().build())); return sizes.build(); } }