Getting Started
Quick Start Guides
- Amazon Web Services
- Elastic Block Store Models
- Azure Storage Service
- BlueLock vCloud
- Cloud Sigma
- Eucalyptus
- File System
- Go Grid
- HP Cloud Services
- IBM Developer Cloud
- OpenStack
- Rackspace
- RimuHosting
- Terremark eCloud
- Terremark vCloud Express
Release Notes
- 1.5.0-alpha.6
- 1.5.0-alpha.5
- 1.5.0-alpha.4
- 1.5.0-alpha.3
- 1.5.0-alpha.2
- 1.5.0-alpha.1
- 1.4.0
- 1.4.0-rc.3
- 1.4.0-rc.2
- 1.4.0-rc.1
- 1.3.1
- 1.3.0
- 1.3.0-rc-2
- 1.3.0-rc-1
- 1.2.2
- 1.2.1
- 1.2.0
- 1.1.1
- 1.1.0
Maven Sites and Javadocs
- HEAD (Javadoc)
- latest release (Javadoc) permalink
- 1.5.0-alpha.6 (Javadoc)
- 1.5.0-alpha.5 (Javadoc)
- 1.5.0-alpha.4 (Javadoc)
- 1.5.0-alpha.3 (Javadoc)
- 1.5.0-alpha.2 (Javadoc)
- 1.5.0-alpha.1 (Javadoc)
- 1.4.0 (Javadoc)
- 1.4.0-rc.3 (Javadoc)
- 1.4.0-rc.2 (Javadoc)
- 1.4.0-rc.1 (Javadoc)
- 1.3.1 (Javadoc)
- 1.3.0 (Javadoc)
- 1.3.0-rc-2 (Javadoc)
- 1.3.0-rc-1 (Javadoc)
- 1.2.2 (Javadoc)
- 1.2.1 (Javadoc)
- 1.2.0 (Javadoc)
- 1.1.1 (Javadoc)
- 1.1.0 (Javadoc)
User Guides
- Using Blob Store API
- Using Compute API and Tools
- Google App Engine
- VMWare vCloud
- Terremark
- File System Provider
- Init Builder
- Using jclouds with Apache Karaf
- Using EC2
- Using Maven
Samples & Examples
FAQs
Reference
- jclouds Rationale and Design
- Location Metadata Design
- Compute API Design
- Columnar Data Design
- jclouds API
- jclouds OAuth Integration
- Using jclouds with Apache Felix OSGi Container
- Pool Design
- Load Balancer Design
- Logging in jclouds
- VMWare Integration Approach & Design
- Supported Providers
- Apps that use jclouds
- Using Provider Metadata
Developer Resources
- Contributing to jclouds
- Provider Testing
- Contributing to Documentation
- Using Eclipse
- jclouds Continuous Integration
- Provider Metadata
Old versions
Release Notes
- 1.0.0
- 1.0 Beta 8
- 1.0 Beta 7
Maven Sites and Javadocs
Quick Start: Rackspace Cloud
- Sign up for Rackspace Cloud by going to this page
- Login to the portal and get your username and key from the management portal
- Ensure you are using a recent JDK 6
- Setup your project to include cloudfiles-us,-uk or cloudservers-us,-uk
get the dependency
org.jclouds.provider/cloudfiles-us,org.jclouds.provider/cloudfiles-uk,org.jclouds.provider/cloudservers-us, ororg.jclouds.provider/cloudservers-ukusing jclouds Installation. - Start coding
Cloud Files
// get a context with rackspace that offers the portable BlobStore api
BlobStoreContext context = new BlobStoreContextFactory().createContext("cloudfiles-us", user, apikey);
// create a container in the default location
context.getBlobStore().createContainerInLocation(null, container);
// use the map interface for easy access to put/get things, keySet, etc.
context.createInputStreamMap(container).put("blob.txt", inputStream);
// when you need access to rackspace-specific features, use the provider-specific context
CloudFilesClient rackspaceClient = CloudFilesClient.class.cast(context.getProviderSpecificContext()
.getApi());
// get a cdn uri for the container
URI cdnURI = rackspaceClient.enableCDN(container);
context.close();
Cloud Servers
import static org.jclouds.cloudservers.options.CreateServerOptions.Builder.withFile;
import static org.jclouds.cloudservers.options.ListOptions.Builder.*;
// get a context with rackspace that offers the portable ComputeService api
ComputeServiceContext context = new ComputeServiceContextFactory().createContext("cloudservers-us", user, apikey,
ImmutableSet.<Module> of(new SshjSshClientModule()));
// here's an example of the portable api
// run a couple nodes accessible via group
Set<? extends NodeMetadata> nodes = context.getComputeService().createNodesInGroup("webserver", 2);
// when you need access to rackspace-specific features, use the provider-specific context
CloudServersClient rackspaceClient = CloudServersClient.class.cast(context.getProviderSpecificContext()
.getApi());
// create a server with a new file called /etc/jclouds.txt and some metadata
Map<String, String> metadata = ImmutableMap.of("jclouds", "rackspace");
int imageId = 2;
int flavorId = 1;
Server server = rackspaceClient.createServer("myservername", imageId, flavorId,
withFile("/etc/jclouds.txt", "rackspace".getBytes()).withMetadata(metadata));
// list all of my servers including details such as metadata
Set<Server> servers = rackspaceClient.listServers(withDetails());
// list the id and name of my servers that were modified since yesterday
servers = rackspaceClient.listServers(changesSince(yesterday));
// list the id and name of images I have access to, starting at index 200 limited to 100 results.
Set<Image> images = rackspaceClient.listImages(startAt(200).maxResults(100));
context.close();