Question

We must support a number of different target clouds for our migration service (from AWS to Openstack to vCloud and more) so I thought I'd use jclouds at least for the part where we retrieve account attributes (such as regions, organizations, catalogs, etc.)

However, it would appear that jclouds support for the 'generic' vCloud API is stuck at 1.0 - and as we ran internally 1.5 (and 5.1) this makes jcloud pretty useless, at least as far as vcloud goes (I think 1.5 was "deprecated" by VMWare back last September?).

Has anyone any idea whether I'm missing something obvious here, or is there a plan to upgrade support?

Obviously, we'll use vmware's SDK, but it would have been good to abstract all the clouds via jclouds.

This is the error I receive:

version 1.0 not present in: {1.5=https://10.10.122.13/api/sessions, 5.1=https://10.10.122.13/api/sessions}

The code I'm using is pretty much straight out of the (extremely sparse) 'user guide':

private VCloudApi getVcloudContext() throws IOException {
    Credentials creds = getVcloudCredentials();
    Properties overrides = new Properties();
    overrides.setProperty(VCLOUD_ENDPOINT, creds.url);
    overrides.setProperty(Constants.PROPERTY_TRUST_ALL_CERTS, "true");

    return ContextBuilder.newBuilder(VCLOUD_PROVIDER)
            .overrides(overrides)
            .credentials(creds.username, creds.username)
            .modules(ImmutableSet.<Module> of(new Log4JLoggingModule(),
                    new SshjSshClientModule()))
            .buildApi(VCloudApi.class);
}

// in my main():
VCloudApi api = app.getVcloudContext();
HttpsURLConnection.setDefaultHostnameVerifier(new HostnameVerifier() {
    public boolean verify(String string, SSLSession ssls) {
        return true;
    }
});
Map<String, ?> orgsList = api.getOrgApi().listOrgs();

Any help, suggestion, pointers to better documentation would be greatly appreciated: thanks!

Was it helpful?

Solution

jclouds has always been slow to add and maintain support for the vCloud API. There was a brief period where VMware supported the project but I suspect today the intersection of folks that use jclouds and also use vCloud is probably small enough that the vCloud support is effectively dead. Due to the inherent cost of vCD or vCHS it would likely require an enterprise vCD/vCHS customer to develop and donate the updated code for vCloud API 5.5+ support.

If you don't particularly like that answer (I don't), I would complain to your VMware rep about the sad state of 3rd party libraries like jclouds or fog. It's in VMware's best interest to build up vCloud support in those libraries as it could help them win customers and get them to try migrating from a competing offering.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top