Examples of imageId()


Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

      NodeMetadataBuilder builder = new NodeMetadataBuilder();
      builder.ids(from.getUuid() + "");
      builder.name(from.getAlias());
      builder.location(from(locations.get()).firstMatch(LocationPredicates.idEquals(from.getUuid() + "")).orNull());
      builder.group(nodeNamingConvention.groupInUniqueNameOrNull(from.getType()));
      builder.imageId(from.getType() + "");
      Image image = from(images.get()).firstMatch(ImagePredicates.idEquals(from.getUuid() + "")).orNull();
      if (image != null)
         builder.operatingSystem(image.getOperatingSystem());
      builder.hardware(from(hardware.get()).firstMatch(HardwarePredicates.idEquals(from.getUuid() + "")).orNull());
      builder.status(serverStatusToNodeStatus.get(from.getState()));
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

      });
      addMetadataAndParseTagsFromCommaDelimitedValue(builder, metadataMap);

      builder.group(groupFromMapOrName(metadataMap, from.getName(), nodeNamingConvention));

      builder.imageId(DatacenterAndName.fromDatacenterAndName(machineInDatacenter.getDatacenter(), from.getDatasetURN())
            .slashEncode());
      builder.operatingSystem(findOperatingSystemForMachineOrNull(machineInDatacenter));
      builder.hardware(findHardwareForMachineOrNull(machineInDatacenter));
      builder.status(toPortableNodeStatus.get(from.getState()));
      builder.publicAddresses(filter(from.getIps(), not(InetAddresses2.IsPrivateIPAddress.INSTANCE)));
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

               LocationPredicates.idEquals(from.getDatacenter().getId() + "")).orNull());
      builder.group(nodeNamingConvention.groupInUniqueNameOrNull(from.getHostname()));

      Image image = images.getImage(from);
      if (image != null) {
         builder.imageId(image.getId());
         builder.operatingSystem(image.getOperatingSystem());
         builder.hardware(hardware.getHardware(from));
      }
      builder.status(serverStateToNodeStatus.get(from.getPowerState().getKeyName()));
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

      builder.publicAddresses(filter(addresses, not(IsPrivateIPAddress.INSTANCE)));
      builder.privateAddresses(filter(addresses, IsPrivateIPAddress.INSTANCE));
      builder.hardware(parseHardware(instance));
      Location location = getLocationForAvailabilityZoneOrRegion(instance);
      builder.location(location);
      builder.imageId(instance.getRegion() + "/" + instance.getImageId());

      // extract the operating system from the image
      RegionAndName regionAndName = new RegionAndName(instance.getRegion(), instance.getImageId());
      try {
         Image image = imageMap.get().getUnchecked(regionAndName);
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

      NodeMetadataBuilder builder = new NodeMetadataBuilder();
      builder.ids(from.id + "");
      builder.name(from.name);
      builder.location(from(locations.get()).firstMatch(LocationPredicates.idEquals(from.datacenter)).orNull());
      builder.group(nodeNamingConvention.groupInUniqueNameOrNull(from.name));
      builder.imageId(from.imageId + "");
      Image image = from(images.get()).firstMatch(ImagePredicates.idEquals(from.imageId + "")).orNull();
      if (image != null)
         builder.operatingSystem(image.getOperatingSystem());
      builder.hardware(from(hardware.get()).firstMatch(HardwarePredicates.idEquals(from.hardwareId + "")).orNull());
      builder.status(serverStatusToNodeStatus.get(from.status));
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

         addMetadataAndParseTagsFromCommaDelimitedValue(builder, metadataMap);
      } else {
         metadataMap = ImmutableMap.of();
      }
      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());
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

            // either location free image (location is null) or in the same zone as the VM
                  && (input.getLocation() == null || input.getId().equals(from.getZoneId() + ""));
         }
      }).orNull();
      if (image != null) {
         builder.imageId(image.getId());
         builder.operatingSystem(image.getOperatingSystem());
      }

      builder.hardware(new HardwareBuilder()
        .ids(from.getServiceOfferingId() + "")
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

      builder.name(from.getName());
      Location location = Iterables.find(locations.get(), LocationPredicates.idEquals(from.getDatacenter().getId() + ""));
      builder.location(location);
      builder.group(nodeNamingConvention.groupInUniqueNameOrNull(from.getName()));
      builder.hardware(parseHardware(from));
      builder.imageId(from.getImage().getId() + "");

      Image image = parseImage(from);
      if (image != null)
         builder.operatingSystem(image.getOperatingSystem());
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

      builder.hostname(from.getName());
      builder.location(from.getHostId() != null ? new LocationBuilder().scope(LocationScope.HOST).id(from.getHostId())
            .description(from.getHostId()).parent(zone).build() : zone);
      builder.group(groupFromMapOrName(from.getMetadata(), from.getName(), nodeNamingConvention));
      addMetadataAndParseTagsFromCommaDelimitedValue(builder, from.getMetadata());
      builder.imageId(ZoneAndId.fromZoneAndId(serverInZone.getZone(), from.getImage().getId()).slashEncode());
      builder.operatingSystem(findOperatingSystemForServerOrNull(serverInZone));
      builder.hardware(findHardwareForServerOrNull(serverInZone));
      builder.status(toPortableNodeStatus.get(from.getStatus()));

      Set<Address> addresses = newHashSet(from.getAddresses().values());
View Full Code Here

Examples of org.jclouds.compute.domain.NodeMetadataBuilder.imageId()

               LocationPredicates.idEquals(from.getDatacenter().getId() + "")).orNull());
      builder.group(nodeNamingConvention.groupInUniqueNameOrNull(from.getHostname()));

      Image image = images.getImage(from);
      if (image != null) {
         builder.imageId(image.getId());
         builder.operatingSystem(image.getOperatingSystem());
      }

      builder.hardware(hardware.getHardware(from));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.