[ 
https://issues.apache.org/jira/browse/JCLOUDS-1068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15130212#comment-15130212
 ] 

Andrea Turli commented on JCLOUDS-1068:
---------------------------------------

I cannot reproduce the error.

[~ch...@bvhllc.com], could you please use 
https://github.com/jclouds/jclouds-examples/blob/master/compute-basics/src/main/java/org/jclouds/examples/compute/basics/MainApp.java
 and add something like

Image image = compute.getImage("UBUNTU_14_64");

at line 140. I'm able to get the image correctly with 1.9.2.

> Softlayer context.getComputeService().getImage() does not work in 1.9.2 like 
> it did in 1.9.1
> --------------------------------------------------------------------------------------------
>
>                 Key: JCLOUDS-1068
>                 URL: https://issues.apache.org/jira/browse/JCLOUDS-1068
>             Project: jclouds
>          Issue Type: Bug
>          Components: jclouds-compute
>    Affects Versions: 1.9.2
>            Reporter: Chava Jurado
>            Priority: Minor
>              Labels: softlayer
>
> In 1.9.1 the following code can retrieve a private image by global id, but in 
> 1.9.2 it returns UBUNTU_14_64.
> {code:title=Softlayer Example|borderStyle=solid}
> import java.util.Properties;
> import org.jclouds.ContextBuilder;
> import org.jclouds.compute.ComputeServiceContext;
> import org.jclouds.compute.domain.Image;
> import org.jclouds.logging.slf4j.config.SLF4JLoggingModule;
> import com.google.common.collect.ImmutableSet;
> import com.google.inject.Module;
> public class SoftlayerExample {
>       public static void main(String[] args) {
>               String identity = "SLxxxxxx"; //accountName
>               String identityCredential = ""; //apiKey
>               String imageId = ""; //globalIdentifier
>               Properties overrides = new Properties();
>               ImmutableSet<Module> modules = ImmutableSet
>                               .<Module> of(new SLF4JLoggingModule());
>               ComputeServiceContext context = 
> ContextBuilder.newBuilder("softlayer")
>                               .credentials(identity, 
> identityCredential).overrides(overrides)
>                               
> .modules(modules).buildView(ComputeServiceContext.class);
>               Image image = context.getComputeService().getImage(imageId);
>               System.out.println(image.getId());
>               if (!image.getId().matches(imageId)) {
>                       System.out.println("No workie in 1.9.2 :(");
>               }
>       }
> }
> {code}
> Looking at the API calls returned by Softlayer in 1.9.1 and 1.9.2, they are 
> identical.  Both are able to get the information from softlayer, but for some 
> reason the object returned in 1.9.2 is a base ubuntu image.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to