Package org.jclouds.compute.domain.internal

Examples of org.jclouds.compute.domain.internal.VolumeImpl


    */
   public static EC2HardwareBuilder i2_8xlarge() {
      return new EC2HardwareBuilder(InstanceType.I2_8XLARGE)
              .ram(244 * 1024)
              .processors(ImmutableList.of(new Processor(32.0, 3.25)))
              .volumes(ImmutableList.<Volume> of(new VolumeImpl(10.0f, "/dev/sda1", true, false),
                      new VolumeImpl(800.0f, "/dev/sdb", false, false),
                      new VolumeImpl(800.0f, "/dev/sdc", false, false),
                      new VolumeImpl(800.0f, "/dev/sdd", false, false),
                      new VolumeImpl(800.0f, "/dev/sde", false, false),
                      new VolumeImpl(800.0f, "/dev/sdf", false, false),
                      new VolumeImpl(800.0f, "/dev/sdg", false, false),
                      new VolumeImpl(800.0f, "/dev/sdh", false, false),
                      new VolumeImpl(800.0f, "/dev/sdi", false, false)))
              .virtualizationType(VirtualizationType.HVM);
   }
View Full Code Here


   public static EC2HardwareBuilder hi1_4xlarge() {
      return new EC2HardwareBuilder(InstanceType.HI1_4XLARGE)
            .ram(60 * 1024 + 512)
            .processors(ImmutableList.of(new Processor(16.0, 2.1875)))
            .volumes(ImmutableList.<Volume> of(new VolumeImpl(1024.0f, "/dev/sda1", true, false),
                  new VolumeImpl(1024.0f, "/dev/sdb", false, false)))
            .virtualizationType(VirtualizationType.HVM);
   }
View Full Code Here

   }
  
   public static EC2HardwareBuilder hs1_8xlarge() {
      float twoTB = 2048.0f * 1024.0f;
      Builder<Volume> all24Volumes = ImmutableList.<Volume>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())
View Full Code Here

                        hardwareToReturn.add(new HardwareBuilder()
                              .ids(String.format(
                                    "datacenter(%s)platform(%s)cpuCores(%d)memorySizeMB(%d)diskSizeGB(%d)", datacenter,
                                    platformToArgs.getKey(), cpuCores, memorySizeMB, diskSizeGB)).ram(memorySizeMB)
                              .processors(ImmutableList.of(new Processor(cpuCores, 1.0)))
                              .volumes(ImmutableList.<Volume> of(new VolumeImpl((float) diskSizeGB, true, true)))
                              .hypervisor(platformToArgs.getKey())
                              .location(find(locationsSet, LocationPredicates.idEquals(datacenter)))
                              .supportsImage(ImagePredicates.idIn(templatesSupported)).build());
                  }
View Full Code Here

      HardwareBuilder builder = new HardwareBuilder();
      builder.ids(from.id + "");
      builder.name(from.name);
      builder.processors(ImmutableList.of(new Processor(from.cores, 1.0)));
      builder.ram(from.ram);
      builder.volumes(ImmutableList.<Volume> of(new VolumeImpl(from.disk, true, false)));
      return builder.build();
   }
View Full Code Here

                              .is64Bit(false).description("Ubuntu 10.04 LTS 32-bit").build())
                  .publicAddresses(ImmutableSet.of("31.192.231.254"))
                  .hardware(
                        new HardwareBuilder().ids("vz1840356").ram(512)
                              .processors(ImmutableList.of(new Processor(1, 1.0)))
                              .volumes(ImmutableList.<Volume> of(new VolumeImpl(5f, true, true))).hypervisor("OpenVZ")
                              .build()).status(Status.RUNNING).build().toString());
   }
View Full Code Here

      builder.group(groupFromMapOrName(metadataMap, from.getHostname(), nodeNamingConvention));
      builder.imageId(from.getTemplateName() + "");
      builder.operatingSystem(parseOperatingSystem(from));
      builder.hardware(new HardwareBuilder().ids(from.getId() + "").ram(from.getMemorySizeMB())
            .processors(ImmutableList.of(new Processor(from.getCpuCores(), 1.0)))
            .volumes(ImmutableList.<Volume> of(new VolumeImpl((float) from.getDiskSizeGB(), true, true)))
            .hypervisor(from.getPlatform()).build());
      builder.status(serverStateToNodeStatus.get(from.getState()));
      Iterable<String> addresses = Iterables.filter(Iterables.transform(from.getIps(), new Function<Ip, String>() {

         @Override
View Full Code Here

   public Hardware apply(ServerSpec spec) {
      Location location = FluentIterable.from(locations.get()).firstMatch(idEquals(spec.getDatacenter())).orNull();
      assert location != null : String.format("no location matched ServerSpec %s", spec);
      return new HardwareBuilder().ids(spec.toString()).ram(spec.getMemorySizeMB()).processors(
               ImmutableList.of(new Processor(spec.getCpuCores(), 1.0))).volumes(
               ImmutableList.<Volume> of(new VolumeImpl((float) spec.getDiskSizeGB(), true, true))).hypervisor(
               spec.getPlatform()).location(location).supportsImage(
               ImagePredicates.idEquals(spec.getTemplateName())).build();
   }
View Full Code Here

      Location location = locationIndex.get().get(flavorInZone.getZone());
      checkState(location != null, "location %s not in locationIndex: %s", flavorInZone.getZone(), locationIndex.get());
      Flavor flavor = flavorInZone.getFlavor();
      return new HardwareBuilder().id(flavorInZone.slashEncode()).providerId(flavor.getId()).name(flavor.getName())
               .ram(flavor.getRam()).processor(new Processor(flavor.getVcpus(), 1.0)).volume(
                        new VolumeImpl(Float.valueOf(flavor.getDisk()), true, true)).location(location).build();
   }
View Full Code Here

                  Iterables.transform(filter(items, categoryCodeMatches(diskCategoryRegex)),
                        new Function<ProductItem, Volume>() {
                           @Override
                           public Volume apply(ProductItem item) {
                              float volumeSize = ProductItems.capacity().apply(item);
                              return new VolumeImpl(
                                       item.getId() + "",
                                       item.getDescription().indexOf(STORAGE_AREA_NETWORK) != -1 ? Volume.Type.SAN : Volume.Type.LOCAL,
                                       volumeSize, null, categoryCode(FIRST_GUEST_DISK).apply(item), false);
                           }
                        })).build();
View Full Code Here

TOP

Related Classes of org.jclouds.compute.domain.internal.VolumeImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.