I am using jcloud 1.9.2. We have set up our own swift repository with s3 api. 
We can access the repository using boto python script

I am using the code in the following post

http://stackoverflow.com/questions/9389840/use-jclouds-to-talk-to-non-aws-cloud-with-s3-api

but I got error.:

public static void main(String args[]) {



    String username = "test:tester";



    String password = "testing";

    Properties overrides = new Properties();

    overrides.setProperty(PROPERTY_S3_VIRTUAL_HOST_BUCKETS, "false");



    BlobStoreContext context = ContextBuilder.newBuilder(new S3ApiMetadata())

            .endpoint("http://myserver:8080";)

            .credentials(username, password)

            .overrides(overrides)

            .buildView(BlobStoreContext.class);

    BlobStore blobStore = context.getBlobStore();

    String bucket="public";

    blobStore.containerExists(bucket);



    System.out.println("bucket exist "+ bucket);

}

Exception in thread "main" org.jclouds.http.HttpResponseException: request: 
HEADhttp://myserver:8080/public HTTP/1.1 failed with response: HTTP/1.1 500 
Internal Server Error at 
org.jclouds.aws.handlers.ParseAWSErrorFromXmlContent.handleError(ParseAWSErrorFromXmlContent.java:63)

....

It throw exception on the line:

blobStore.containerExists(bucket);

Thanks

Reply via email to