diff --git a/allcompute/pom.xml b/allcompute/pom.xml
index c89196929c..80ed52c40f 100644
--- a/allcompute/pom.xml
+++ b/allcompute/pom.xml
@@ -35,11 +35,6 @@
greenhousedata-element-vcloud${project.version}
-
- org.jclouds.api
- deltacloud
- ${project.version}
- org.jclouds.provideraws-ec2
diff --git a/apis/deltacloud/README.txt b/apis/deltacloud/README.txt
deleted file mode 100644
index 4798829a9b..0000000000
--- a/apis/deltacloud/README.txt
+++ /dev/null
@@ -1,84 +0,0 @@
-====
- Licensed to jclouds, Inc. (jclouds) under one or more
- contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. jclouds licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
-====
-
-jclouds binding to deltacloud requires a minimum server version of 0.1.0.
-
-The identity and credential specified in jclouds will pass through deltacloud to
-the backend, such as gogrid.
-
-To install deltacloud, do the following:
- * OS/X and jruby
- # use homebrew or equiv to install jruby
- * brew install jruby
- * note testing took place w/ 1.6.0
- # install and configure openssl to avoid "certificate verify failed" errors
- # install and link openssl
- * brew install openssl
- * brew link openssl
- # install jruby ssl
- * jruby -S gem install jruby-openssl
- # setup cert directory
- * mkdir $HOME/certs
- * curl -o $HOME/certs/cacert.pem http://curl.haxx.se/ca/cacert.pem
- # rehash cert directory
- * export SSL_CERT_DIR=$HOME/certs
- * export SSL_CERT_FILE=$HOME/certs/cacert.pem
- * c_rehash
- # test
- * jruby -ropen-uri -e 'p open("https://encrypted.google.com")'
- * should see something like #
- # install specific version of rack that doesn't conflict with deltacloud
- * jruby -S gem install rack --version 1.1.0
- # install net-ssh
- * jruby -S gem install net-ssh
- # install deltacloud core
- * jruby -S gem install deltacloud-core
-
-To run a local deltacloud server, do the following:
- * jruby
- # export SSL_CERT_DIR=$HOME/certs
- # export SSL_CERT_FILE=$HOME/certs/cacert.pem
- # jruby -S deltacloudd -i mock
- * or if you are running from a src tree: jruby -S ./server/bin/deltacloudd -i
-
-Here are some notes about specific cloud providers
- * terremark
- # install fog gem
- * jruby -S gem install fog
- * rackspace
- # install cloudfiles, cloudservers gem
- * jruby -S gem install cloudservers
- * jruby -S gem install cloudfiles
- * ec2
- * using jruby --1.8, 'gem install aws' will fail with ArrayIndexOutOfBoundsException per http://jira.codehaus.org/browse/JRUBY-5581
- * using jruby --1.9, 'gem install aws' works, but running './server/bin/deltacloudd -i ec2' fails per http://jira.codehaus.org/browse/JRUBY-5529
- # install i18n, aws gem
- * jruby -S gem install i18n
- * jruby -S gem install aws
-
-Local Development of Delta
- * jruby -S gem install rack-test cucumber
-
- * What tests are available
- * jruby -S rake -T
- * server/tests/drivers
- * specific tests to a particular driver
- * Running tests
- * jruby -S rake test
-
diff --git a/apis/deltacloud/pom.xml b/apis/deltacloud/pom.xml
deleted file mode 100644
index 9470789a81..0000000000
--- a/apis/deltacloud/pom.xml
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
- 4.0.0
-
- org.jclouds
- jclouds-project
- 1.6.0-SNAPSHOT
- ../../project/pom.xml
-
- org.jclouds.api
- deltacloud
- jclouds deltacloud core
- jclouds components to access deltacloud
- bundle
-
-
-
-
- sonatype-nexus-snapshots
- https://oss.sonatype.org/content/repositories/snapshots
-
- false
-
-
- true
-
-
-
-
-
- http://localhost:3001/api
- 0.3.0
-
- mockuser
- mockpassword
-
- org.jclouds.deltacloud*;version="${project.version}"
-
- org.jclouds.compute.internal;version="${project.version}",
- org.jclouds.rest.internal;version="${project.version}",
- org.jclouds*;version="${project.version}",
- *
-
-
-
-
- org.jclouds
- jclouds-compute
- ${project.version}
-
-
- org.jclouds
- jclouds-core
- ${project.version}
- test-jar
- test
-
-
- org.jclouds
- jclouds-compute
- ${project.version}
- test-jar
- test
-
-
- org.jclouds.driver
- jclouds-sshj
- ${project.version}
- test
-
-
- org.jclouds.driver
- jclouds-log4j
- ${project.version}
- test
-
-
-
-
- live
-
-
-
- org.apache.maven.plugins
- maven-surefire-plugin
-
-
- integration
- integration-test
-
- test
-
-
-
- ${test.deltacloud.endpoint}
- ${test.deltacloud.api-version}
- ${test.deltacloud.build-version}
- ${test.deltacloud.identity}
- ${test.deltacloud.credential}
- ${test.deltacloud.template}
-
-
-
-
-
-
-
-
-
-
-
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudApiMetadata.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudApiMetadata.java
deleted file mode 100644
index df9ca77bc3..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudApiMetadata.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud;
-
-import java.net.URI;
-import java.util.Properties;
-
-import org.jclouds.apis.ApiMetadata;
-import org.jclouds.compute.ComputeServiceContext;
-import org.jclouds.deltacloud.compute.config.DeltacloudComputeServiceContextModule;
-import org.jclouds.deltacloud.config.DeltacloudRestClientModule;
-import org.jclouds.rest.RestContext;
-import org.jclouds.rest.internal.BaseRestApiMetadata;
-
-import com.google.common.collect.ImmutableSet;
-import com.google.common.reflect.TypeToken;
-import com.google.inject.Module;
-
-/**
- * Implementation of {@link ApiMetadata} for Apache Deltacloud API
- *
- * @author Adrian Cole
- */
-public class DeltacloudApiMetadata extends BaseRestApiMetadata {
-
- public static final TypeToken> CONTEXT_TOKEN = new TypeToken>() {
- };
-
- @Override
- public Builder toBuilder() {
- return new Builder().fromApiMetadata(this);
- }
-
- public DeltacloudApiMetadata() {
- this(new Builder());
- }
-
- protected DeltacloudApiMetadata(Builder builder) {
- super(builder);
- }
-
- public static Properties defaultProperties() {
- return BaseRestApiMetadata.defaultProperties();
- }
-
- public static class Builder extends BaseRestApiMetadata.Builder {
-
- protected Builder() {
- super(DeltacloudClient.class, DeltacloudAsyncClient.class);
- id("deltacloud")
- .name("Apache Deltacloud API")
- .identityName("Username")
- .credentialName("Password")
- .documentation(URI.create("http://deltacloud.apache.org/api.html"))
- .version("0.3.0")
- .defaultEndpoint("http://localhost:3001/api")
- .defaultProperties(DeltacloudApiMetadata.defaultProperties())
- .view(TypeToken.of(ComputeServiceContext.class))
- .defaultModules(ImmutableSet.>of(DeltacloudRestClientModule.class, DeltacloudComputeServiceContextModule.class));
- }
-
- @Override
- public DeltacloudApiMetadata build() {
- return new DeltacloudApiMetadata(this);
- }
-
- @Override
- public Builder fromApiMetadata(ApiMetadata in) {
- super.fromApiMetadata(in);
- return this;
- }
-
- }
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudAsyncClient.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudAsyncClient.java
deleted file mode 100644
index f1b188e10f..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudAsyncClient.java
+++ /dev/null
@@ -1,179 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud;
-
-import java.net.URI;
-import java.util.Set;
-
-import javax.ws.rs.Consumes;
-import javax.ws.rs.FormParam;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.Fallbacks.EmptyMultimapOnNotFoundOr404;
-import org.jclouds.Fallbacks.EmptySetOnNotFoundOr404;
-import org.jclouds.Fallbacks.NullOnNotFoundOr404;
-import org.jclouds.deltacloud.DeltacloudFallbacks.VoidOnRedirectedDelete;
-import org.jclouds.deltacloud.collections.HardwareProfiles;
-import org.jclouds.deltacloud.collections.Images;
-import org.jclouds.deltacloud.collections.InstanceStates;
-import org.jclouds.deltacloud.collections.Instances;
-import org.jclouds.deltacloud.collections.Realms;
-import org.jclouds.deltacloud.domain.DeltacloudCollection;
-import org.jclouds.deltacloud.domain.HardwareProfile;
-import org.jclouds.deltacloud.domain.Image;
-import org.jclouds.deltacloud.domain.Instance;
-import org.jclouds.deltacloud.domain.Instance.State;
-import org.jclouds.deltacloud.domain.Realm;
-import org.jclouds.deltacloud.domain.Transition;
-import org.jclouds.deltacloud.options.CreateInstanceOptions;
-import org.jclouds.deltacloud.xml.DeltacloudCollectionsHandler;
-import org.jclouds.deltacloud.xml.HardwareProfileHandler;
-import org.jclouds.deltacloud.xml.HardwareProfilesHandler;
-import org.jclouds.deltacloud.xml.ImageHandler;
-import org.jclouds.deltacloud.xml.ImagesHandler;
-import org.jclouds.deltacloud.xml.InstanceHandler;
-import org.jclouds.deltacloud.xml.InstanceStatesHandler;
-import org.jclouds.deltacloud.xml.InstancesHandler;
-import org.jclouds.deltacloud.xml.RealmHandler;
-import org.jclouds.deltacloud.xml.RealmsHandler;
-import org.jclouds.http.HttpRequest;
-import org.jclouds.http.filters.BasicAuthentication;
-import org.jclouds.rest.annotations.Endpoint;
-import org.jclouds.rest.annotations.EndpointParam;
-import org.jclouds.rest.annotations.Fallback;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.XMLResponseParser;
-
-import com.google.common.collect.Multimap;
-import com.google.common.util.concurrent.ListenableFuture;
-
-/**
- * Provides asynchronous access to deltacloud via their REST API.
- *
- *
- * @see DeltacloudClient
- * @see
- * @author Adrian Cole
- */
-@RequestFilters(BasicAuthentication.class)
-@Consumes(MediaType.APPLICATION_XML)
-public interface DeltacloudAsyncClient {
-
- /**
- * @see DeltacloudClient#getCollections
- */
- @GET
- @Fallback(EmptySetOnNotFoundOr404.class)
- @XMLResponseParser(DeltacloudCollectionsHandler.class)
- ListenableFuture> getCollections();
-
- /**
- * @see DeltacloudClient#getInstanceStates
- */
- @GET
- @Endpoint(InstanceStates.class)
- @Fallback(EmptyMultimapOnNotFoundOr404.class)
- @XMLResponseParser(InstanceStatesHandler.class)
- ListenableFuture> getInstanceStates();
-
- /**
- * @see DeltacloudClient#listRealms
- */
- @GET
- @Endpoint(Realms.class)
- @Fallback(EmptySetOnNotFoundOr404.class)
- @XMLResponseParser(RealmsHandler.class)
- ListenableFuture> listRealms();
-
- /**
- * @see DeltacloudClient#getRealm
- */
- @GET
- @Fallback(NullOnNotFoundOr404.class)
- @XMLResponseParser(RealmHandler.class)
- ListenableFuture getRealm(@EndpointParam URI realmHref);
-
- /**
- * @see DeltacloudClient#listImages
- */
- @GET
- @Endpoint(Images.class)
- @Fallback(EmptySetOnNotFoundOr404.class)
- @XMLResponseParser(ImagesHandler.class)
- ListenableFuture> listImages();
-
- /**
- * @see DeltacloudClient#getImage
- */
- @GET
- @Fallback(NullOnNotFoundOr404.class)
- @XMLResponseParser(ImageHandler.class)
- ListenableFuture getImage(@EndpointParam URI imageHref);
-
- /**
- * @see DeltacloudClient#listHardwareProfiles
- */
- @GET
- @Endpoint(HardwareProfiles.class)
- @Fallback(EmptySetOnNotFoundOr404.class)
- @XMLResponseParser(HardwareProfilesHandler.class)
- ListenableFuture> listHardwareProfiles();
-
- /**
- * @see DeltacloudClient#getHardwareProfile
- */
- @GET
- @Fallback(NullOnNotFoundOr404.class)
- @XMLResponseParser(HardwareProfileHandler.class)
- ListenableFuture getHardwareProfile(@EndpointParam URI profileHref);
-
- /**
- * @see DeltacloudClient#listInstances
- */
- @GET
- @Endpoint(Instances.class)
- @Fallback(EmptySetOnNotFoundOr404.class)
- @XMLResponseParser(InstancesHandler.class)
- ListenableFuture> listInstances();
-
- /**
- * @see DeltacloudClient#getInstance
- */
- @GET
- @Fallback(NullOnNotFoundOr404.class)
- @XMLResponseParser(InstanceHandler.class)
- ListenableFuture getInstance(@EndpointParam URI instanceHref);
-
- /**
- * @see DeltacloudClient#createInstance
- */
- @POST
- @Endpoint(Instances.class)
- @XMLResponseParser(InstanceHandler.class)
- ListenableFuture createInstance(@FormParam("image_id") String imageId, CreateInstanceOptions... options);
-
- /**
- * @see DeltacloudClient#performInstanceAction
- */
- @Fallback(VoidOnRedirectedDelete.class)
- ListenableFuture performAction(HttpRequest action);
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudClient.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudClient.java
deleted file mode 100644
index 39f4da8db7..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudClient.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud;
-
-import java.net.URI;
-import java.util.Set;
-import java.util.concurrent.TimeUnit;
-
-import org.jclouds.concurrent.Timeout;
-import org.jclouds.deltacloud.domain.DeltacloudCollection;
-import org.jclouds.deltacloud.domain.HardwareProfile;
-import org.jclouds.deltacloud.domain.Image;
-import org.jclouds.deltacloud.domain.Instance;
-import org.jclouds.deltacloud.domain.Realm;
-import org.jclouds.deltacloud.domain.Transition;
-import org.jclouds.deltacloud.domain.Instance.State;
-import org.jclouds.deltacloud.options.CreateInstanceOptions;
-import org.jclouds.http.HttpRequest;
-
-import com.google.common.collect.Multimap;
-
-/**
- * Provides synchronous access to deltacloud.
- *
- *
- * @see DeltacloudAsyncClient
- * @see
- * @author Adrian Cole
- */
-@Timeout(duration = 60, timeUnit = TimeUnit.SECONDS)
-public interface DeltacloudClient {
- /**
- * The result of this entry-point is a set of entry-points into other collections, such as
- * images, instances, hardware profiles and realms, among others.
- *
- * @return named links to available collections, or empty set, if no collections are found
- */
- Set getCollections();
-
- /**
- *
- * @return The possible states of an instance, and how to traverse between them
- */
- Multimap getInstanceStates();
-
- /**
- * The realms collection will return a set of all realms available to the current user.
- *
- * @return realms viewable to the user or empty set
- */
- Set listRealms();
-
- /**
- *
- * @param realmHref
- * @return realm or null, if not found
- */
- Realm getRealm(URI realmHref);
-
- /**
- * The images collection will return a set of all images available to the current user.
- *
- * @return images viewable to the user or empty set
- */
- Set listImages();
-
- /**
- *
- * @param imageHref
- * @return image or null, if not found
- */
- Image getImage(URI imageHref);
-
- /**
- * The hardware profiles collection will return a set of all hardware profiles available to the
- * current user.
- *
- * @return hardware profiles viewable to the user or empty set
- */
- Set listHardwareProfiles();
-
- /**
- *
- * @param profileHref
- * @return hardware profile or null, if not found
- */
- HardwareProfile getHardwareProfile(URI profileHref);
-
- /**
- * The instances collection will return a set of all instances available to the current user.
- *
- * @return instances viewable to the user or empty set
- */
- Set listInstances();
-
- /**
- *
- * @param instanceHref
- * @return instance or null, if not found
- */
- Instance getInstance(URI instanceHref);
-
- /**
- * Create a new Instance
- *
- *
Note
- *
- * If options realmId or hardwareProfileName are not specified, the provider must select
- * reasonable defaults. The architecture of the selected hardware profile must match the
- * architecture of the specified image.
- *
- * @param imageId
- * The identifier (not URL) of the image from which to base the instance
- * @param options
- * includes realm, hardware profile, etc.
- * @return newly-created instance including a URL to retrieve the instance in the future.
- */
- Instance createInstance(String imageId, CreateInstanceOptions... options);
-
- /**
- * perform a specific action.
- *
- * @param action
- * reference from {@link Instance#getActions()}
- */
- void performAction(HttpRequest action);
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudFallbacks.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudFallbacks.java
deleted file mode 100644
index 8e75fcb6ff..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/DeltacloudFallbacks.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud;
-
-import static com.google.common.base.Throwables.propagate;
-import static com.google.common.util.concurrent.Futures.immediateFuture;
-import static org.jclouds.util.Throwables2.getFirstThrowableOfType;
-
-import javax.ws.rs.HttpMethod;
-
-import org.jclouds.http.HttpResponseException;
-
-import com.google.common.util.concurrent.FutureFallback;
-import com.google.common.util.concurrent.ListenableFuture;
-
-public final class DeltacloudFallbacks {
- private DeltacloudFallbacks() {
- }
-
- /**
- * When a delete operation is performed, Deltacloud returns 302.
- *
- * @author Adrian Cole
- */
- public static final class VoidOnRedirectedDelete implements FutureFallback {
- @Override
- public ListenableFuture create(final Throwable t) {
- HttpResponseException exception = getFirstThrowableOfType(t, HttpResponseException.class);
- if (exception != null && exception.getCommand().getCurrentRequest().getMethod().equals(HttpMethod.DELETE)
- && exception.getResponse().getStatusCode() == 302) {
- return immediateFuture(null);
- }
- throw propagate(t);
- }
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/HardwareProfiles.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/HardwareProfiles.java
deleted file mode 100644
index 7ed996d0f3..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/HardwareProfiles.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.collections;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-import javax.inject.Qualifier;
-
-/**
- * The images collection will return a set of all hardware profiles available to the current user.
- *
- * @author Adrian Cole
- *
- */
-@Retention(value = RetentionPolicy.RUNTIME)
-@Target(value = { ElementType.TYPE, ElementType.FIELD, ElementType.PARAMETER, ElementType.METHOD })
-@Qualifier
-public @interface HardwareProfiles {
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Images.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Images.java
deleted file mode 100644
index fd16dbb386..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Images.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.collections;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-import javax.inject.Qualifier;
-
-/**
- * The images collection will return a set of all images available to the current user.
- *
- * @author Adrian Cole
- *
- */
-@Retention(value = RetentionPolicy.RUNTIME)
-@Target(value = { ElementType.TYPE, ElementType.FIELD, ElementType.PARAMETER, ElementType.METHOD })
-@Qualifier
-public @interface Images {
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/InstanceStates.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/InstanceStates.java
deleted file mode 100644
index b387de8ac9..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/InstanceStates.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.collections;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-import javax.inject.Qualifier;
-
-/**
- * The realms collection will return a set of all instance states available to the current user.
- *
- * @author Adrian Cole
- *
- */
-@Retention(value = RetentionPolicy.RUNTIME)
-@Target(value = { ElementType.TYPE, ElementType.FIELD, ElementType.PARAMETER, ElementType.METHOD })
-@Qualifier
-public @interface InstanceStates {
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Instances.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Instances.java
deleted file mode 100644
index 937f33bf4d..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Instances.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.collections;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-import javax.inject.Qualifier;
-
-/**
- * The instances collection will return a set of all instances available to the current user.
- *
- * @author Adrian Cole
- *
- */
-@Retention(value = RetentionPolicy.RUNTIME)
-@Target(value = { ElementType.TYPE, ElementType.FIELD, ElementType.PARAMETER, ElementType.METHOD })
-@Qualifier
-public @interface Instances {
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Realms.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Realms.java
deleted file mode 100644
index 706d293dbd..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/collections/Realms.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.collections;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-import javax.inject.Qualifier;
-
-/**
- * The realms collection will return a set of all realms available to the current user.
- *
- * @author Adrian Cole
- *
- */
-@Retention(value = RetentionPolicy.RUNTIME)
-@Target(value = { ElementType.TYPE, ElementType.FIELD, ElementType.PARAMETER, ElementType.METHOD })
-@Qualifier
-public @interface Realms {
-
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/config/DeltacloudComputeServiceContextModule.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/config/DeltacloudComputeServiceContextModule.java
deleted file mode 100644
index 34d21cb1af..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/config/DeltacloudComputeServiceContextModule.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.config;
-
-import org.jclouds.compute.ComputeServiceAdapter;
-import org.jclouds.compute.config.ComputeServiceAdapterContextModule;
-import org.jclouds.compute.domain.NodeMetadata;
-import org.jclouds.deltacloud.compute.functions.DeltacloudImageToImage;
-import org.jclouds.deltacloud.compute.functions.HardwareProfileToHardware;
-import org.jclouds.deltacloud.compute.functions.InstanceToNodeMetadata;
-import org.jclouds.deltacloud.compute.functions.RealmToLocation;
-import org.jclouds.deltacloud.compute.strategy.DeltacloudComputeServiceAdapter;
-import org.jclouds.deltacloud.domain.HardwareProfile;
-import org.jclouds.deltacloud.domain.Instance;
-import org.jclouds.deltacloud.domain.Realm;
-import org.jclouds.domain.Location;
-
-import com.google.common.base.Function;
-import com.google.inject.TypeLiteral;
-
-/**
- *
- * @author Adrian Cole
- */
-public class DeltacloudComputeServiceContextModule extends
- ComputeServiceAdapterContextModule {
-
- @Override
- protected void configure() {
- super.configure();
- bind(
- new TypeLiteral>() {
- }).to(DeltacloudComputeServiceAdapter.class);
- bind(new TypeLiteral>() {
- }).to(InstanceToNodeMetadata.class);
- bind(new TypeLiteral>() {
- }).to(DeltacloudImageToImage.class);
- bind(new TypeLiteral>() {
- }).to(HardwareProfileToHardware.class);
- bind(new TypeLiteral>() {
- }).to(RealmToLocation.class);
- // to have the compute service adapter override default locations
- install(new LocationsFromComputeServiceAdapterModule(){});
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/DeltacloudImageToImage.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/DeltacloudImageToImage.java
deleted file mode 100644
index b8ad9edd0a..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/DeltacloudImageToImage.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.functions;
-
-import javax.inject.Inject;
-import javax.inject.Singleton;
-
-import org.jclouds.compute.domain.Image;
-import org.jclouds.compute.domain.ImageBuilder;
-import org.jclouds.compute.domain.Image.Status;
-
-import com.google.common.base.Function;
-
-/**
- * @author Adrian Cole
- */
-@Singleton
-public class DeltacloudImageToImage implements Function {
- private final DeltacloudImageToOperatingSystem imageToOperatingSystem;
-
- @Inject
- public DeltacloudImageToImage(DeltacloudImageToOperatingSystem imageToOperatingSystem) {
- this.imageToOperatingSystem = imageToOperatingSystem;
- }
-
- @Override
- public Image apply(org.jclouds.deltacloud.domain.Image from) {
- ImageBuilder builder = new ImageBuilder();
- builder.id(from.getHref().toASCIIString());
- builder.providerId(from.getId());
- builder.uri(from.getHref());
- builder.name(from.getName());
- builder.description(from.getDescription());
- builder.operatingSystem(imageToOperatingSystem.apply(from));
- builder.status(Status.AVAILABLE);
- return builder.build();
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/DeltacloudImageToOperatingSystem.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/DeltacloudImageToOperatingSystem.java
deleted file mode 100644
index f55e71e4e9..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/DeltacloudImageToOperatingSystem.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.functions;
-
-import java.util.Map;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import javax.annotation.Resource;
-import javax.inject.Inject;
-import javax.inject.Named;
-import javax.inject.Singleton;
-
-import org.jclouds.compute.domain.OperatingSystem;
-import org.jclouds.compute.domain.OsFamily;
-import org.jclouds.compute.reference.ComputeServiceConstants;
-import org.jclouds.compute.util.ComputeServiceUtils;
-import org.jclouds.logging.Logger;
-
-import com.google.common.base.Function;
-
-/**
- * @author Adrian Cole
- */
-@Singleton
-public class DeltacloudImageToOperatingSystem implements Function {
- public static final Pattern DEFAULT_PATTERN = Pattern.compile("(([^ ]*) ([0-9.]+) ?.*)");
- // Windows Server 2008 R2 x64
- public static final Pattern WINDOWS_PATTERN = Pattern.compile("Windows (.*) (x[86][64])");
-
- @Resource
- @Named(ComputeServiceConstants.COMPUTE_LOGGER)
- protected Logger logger = Logger.NULL;
-
- private final Map> osVersionMap;
-
- @Inject
- public DeltacloudImageToOperatingSystem(Map> osVersionMap) {
- this.osVersionMap = osVersionMap;
- }
-
- public OperatingSystem apply(org.jclouds.deltacloud.domain.Image from) {
- OsFamily osFamily = null;
- String osName = null;
- String osArch = null;
- String osVersion = null;
- String osDescription = from.getName();
- boolean is64Bit = true;
- if (from.getName().indexOf("Red Hat EL") != -1) {
- osFamily = OsFamily.RHEL;
- } else if (from.getName().indexOf("Oracle EL") != -1) {
- osFamily = OsFamily.OEL;
- } else if (from.getName().indexOf("Windows") != -1) {
- osFamily = OsFamily.WINDOWS;
- Matcher matcher = WINDOWS_PATTERN.matcher(from.getName());
- if (matcher.find()) {
- osVersion = ComputeServiceUtils.parseVersionOrReturnEmptyString(osFamily, matcher.group(1), osVersionMap);
- is64Bit = matcher.group(2).equals("x64");
- }
- } else {
- Matcher matcher = DEFAULT_PATTERN.matcher(from.getName());
- if (matcher.find()) {
- try {
- osFamily = OsFamily.fromValue(matcher.group(2).toLowerCase());
- } catch (IllegalArgumentException e) {
- logger.debug("<< didn't match os(%s)", matcher.group(2));
- }
- osVersion = ComputeServiceUtils.parseVersionOrReturnEmptyString(osFamily, matcher.group(3), osVersionMap);
- }
- }
- return new OperatingSystem(osFamily, osName, osVersion, osArch, osDescription, is64Bit);
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/HardwareProfileToHardware.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/HardwareProfileToHardware.java
deleted file mode 100644
index 28b643299c..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/HardwareProfileToHardware.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.functions;
-
-import javax.inject.Singleton;
-
-import org.jclouds.compute.domain.Hardware;
-import org.jclouds.compute.domain.HardwareBuilder;
-import org.jclouds.compute.domain.Processor;
-import org.jclouds.compute.domain.Volume;
-import org.jclouds.compute.domain.VolumeBuilder;
-import org.jclouds.deltacloud.domain.HardwareProfile;
-import org.jclouds.deltacloud.domain.HardwareProperty;
-
-import com.google.common.base.Function;
-import com.google.common.collect.ImmutableList;
-
-/**
- * @author Adrian Cole
- */
-@Singleton
-public class HardwareProfileToHardware implements Function {
-
- @Override
- public Hardware apply(HardwareProfile from) {
- HardwareBuilder builder = new HardwareBuilder();
- builder.ids(from.getId());
- builder.name(from.getName());
- builder.uri(from.getHref());
-
- for (HardwareProperty property : from.getProperties()) {
- if (property.getName().equals("memory")) {
- builder.ram(Integer.parseInt(property.getValue().toString()));
- } else if (property.getName().equals("storage")) {
- Float gigs = new Float(property.getValue().toString());
- builder.processors(ImmutableList.of(new Processor(gigs / 10.0, 1.0)));
- builder.volume(new VolumeBuilder().type(Volume.Type.LOCAL).device("/").size(gigs).bootDevice(true).durable(
- true).build());
- }
- }
-
- return builder.build();
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/InstanceToNodeMetadata.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/InstanceToNodeMetadata.java
deleted file mode 100644
index 188ce1d2a2..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/InstanceToNodeMetadata.java
+++ /dev/null
@@ -1,163 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.functions;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.util.Map;
-import java.util.NoSuchElementException;
-import java.util.Set;
-
-import javax.annotation.Resource;
-import javax.inject.Inject;
-import javax.inject.Named;
-import javax.inject.Singleton;
-
-import org.jclouds.collect.Memoized;
-import org.jclouds.compute.domain.Hardware;
-import org.jclouds.compute.domain.Image;
-import org.jclouds.compute.domain.NodeMetadata;
-import org.jclouds.compute.domain.NodeMetadataBuilder;
-import org.jclouds.compute.domain.OperatingSystem;
-import org.jclouds.compute.domain.NodeMetadata.Status;
-import org.jclouds.compute.functions.GroupNamingConvention;
-import org.jclouds.compute.reference.ComputeServiceConstants;
-import org.jclouds.deltacloud.domain.Instance;
-import org.jclouds.domain.Location;
-import org.jclouds.logging.Logger;
-
-import com.google.common.base.Function;
-import com.google.common.base.Predicate;
-import com.google.common.base.Supplier;
-import com.google.common.collect.ImmutableMap;
-import com.google.common.collect.Iterables;
-
-/**
- * @author Adrian Cole
- */
-@Singleton
-public class InstanceToNodeMetadata implements Function {
-
- public static final Map instanceToNodeStatus = ImmutableMap
- . builder().put(Instance.State.STOPPED, Status.SUSPENDED)
- .put(Instance.State.RUNNING, Status.RUNNING).put(Instance.State.PENDING, Status.PENDING)
- .put(Instance.State.UNRECOGNIZED, Status.UNRECOGNIZED).put(Instance.State.SHUTTING_DOWN, Status.PENDING)
- .put(Instance.State.START, Status.PENDING).build();
-
- @Resource
- @Named(ComputeServiceConstants.COMPUTE_LOGGER)
- protected Logger logger = Logger.NULL;
-
- protected final Supplier> locations;
- protected final Supplier> images;
- protected final Supplier> hardwares;
- protected final GroupNamingConvention nodeNamingConvention;
-
- private static class FindImageForInstance implements Predicate {
- private final Instance instance;
-
- private FindImageForInstance(Instance instance) {
- this.instance = instance;
- }
-
- @Override
- public boolean apply(Image input) {
- return input.getUri().equals(instance.getImage());
- }
- }
-
- private static class FindHardwareForInstance implements Predicate {
- private final Instance instance;
-
- private FindHardwareForInstance(Instance instance) {
- this.instance = instance;
- }
-
- @Override
- public boolean apply(Hardware input) {
- return input.getUri().equals(instance.getHardwareProfile());
- }
- }
-
- protected Hardware parseHardware(Instance from) {
- try {
- return Iterables.find(hardwares.get(), new FindHardwareForInstance(from));
- } catch (NoSuchElementException e) {
- logger.debug("could not find a matching hardware for instance %s", from);
- }
- return null;
- }
-
- protected OperatingSystem parseOperatingSystem(Instance from) {
- try {
- return Iterables.find(images.get(), new FindImageForInstance(from)).getOperatingSystem();
- } catch (NoSuchElementException e) {
- logger.debug("could not find a matching image for instance %s", from);
- }
- return null;
- }
-
- private static class FindLocationForInstance implements Predicate {
- private final Instance instance;
-
- private FindLocationForInstance(Instance instance) {
- this.instance = instance;
- }
-
- @Override
- public boolean apply(Location input) {
- return input.getId().equals(instance.getRealm().toASCIIString());
- }
- }
-
- protected Location parseLocation(Instance from) {
- try {
- return Iterables.find(locations.get(), new FindLocationForInstance(from));
- } catch (NoSuchElementException e) {
- logger.debug("could not find a matching realm for instance %s", from);
- }
- return null;
- }
-
- @Inject
- InstanceToNodeMetadata(@Memoized Supplier> locations,
- @Memoized Supplier> images, @Memoized Supplier> hardwares,
- GroupNamingConvention.Factory namingConvention) {
- this.nodeNamingConvention = checkNotNull(namingConvention, "namingConvention").createWithoutPrefix();
- this.images = checkNotNull(images, "images");
- this.locations = checkNotNull(locations, "locations");
- this.hardwares = checkNotNull(hardwares, "hardwares");
- }
-
- @Override
- public NodeMetadata apply(org.jclouds.deltacloud.domain.Instance from) {
- NodeMetadataBuilder builder = new NodeMetadataBuilder();
- builder.ids(from.getHref().toASCIIString());
- builder.name(from.getName());
- builder.location(parseLocation(from));
- builder.group(nodeNamingConvention.groupInUniqueNameOrNull(from.getName()));
- builder.imageId(from.getImage().toASCIIString());
- builder.operatingSystem(parseOperatingSystem(from));
- builder.hardware(parseHardware(from));
- builder.status(instanceToNodeStatus.get(from.getState()));
- builder.publicAddresses(from.getPublicAddresses());
- builder.privateAddresses(from.getPrivateAddresses());
- return builder.build();
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/RealmToLocation.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/RealmToLocation.java
deleted file mode 100644
index 1c0ce6a36d..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/functions/RealmToLocation.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.functions;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.net.URI;
-import java.util.Set;
-
-import javax.inject.Inject;
-import javax.inject.Singleton;
-
-import org.jclouds.deltacloud.domain.Realm;
-import org.jclouds.domain.Location;
-import org.jclouds.domain.LocationBuilder;
-import org.jclouds.domain.LocationScope;
-import org.jclouds.location.Iso3166;
-import org.jclouds.location.Provider;
-
-import com.google.common.base.Function;
-import com.google.common.base.Supplier;
-
-/**
- * @author Adrian Cole
- */
-@Singleton
-public class RealmToLocation implements Function {
-
- private final String providerName;
- private final Supplier endpoint;
- private final Set isoCodes;
-
- @Inject
- public RealmToLocation(@Iso3166 Set isoCodes, @Provider String providerName, @Provider Supplier endpoint) {
- this.providerName = checkNotNull(providerName, "providerName");
- this.endpoint = checkNotNull(endpoint, "endpoint");
- this.isoCodes = checkNotNull(isoCodes, "isoCodes");
- }
-
- @Override
- public Location apply(Realm from) {
- return new LocationBuilder().scope(LocationScope.ZONE).id(from.getHref().toASCIIString()).description(from.getName()).parent(
- new LocationBuilder().scope(LocationScope.PROVIDER).iso3166Codes(isoCodes).id(providerName).description(
- endpoint.get().toASCIIString()).parent(null).build()).build();
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/strategy/DeltacloudComputeServiceAdapter.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/strategy/DeltacloudComputeServiceAdapter.java
deleted file mode 100644
index ba00cae38a..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/compute/strategy/DeltacloudComputeServiceAdapter.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.compute.strategy;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.net.URI;
-import java.util.concurrent.TimeUnit;
-
-import javax.annotation.Resource;
-import javax.inject.Inject;
-import javax.inject.Named;
-import javax.inject.Singleton;
-
-import org.jclouds.compute.ComputeServiceAdapter;
-import org.jclouds.compute.domain.Template;
-import org.jclouds.compute.reference.ComputeServiceConstants;
-import org.jclouds.deltacloud.DeltacloudClient;
-import org.jclouds.deltacloud.domain.HardwareProfile;
-import org.jclouds.deltacloud.domain.Instance;
-import org.jclouds.deltacloud.domain.PasswordAuthentication;
-import org.jclouds.deltacloud.domain.Realm;
-import org.jclouds.deltacloud.domain.Transition;
-import org.jclouds.deltacloud.domain.TransitionOnAction;
-import org.jclouds.deltacloud.domain.Instance.State;
-import org.jclouds.deltacloud.options.CreateInstanceOptions;
-import org.jclouds.deltacloud.predicates.InstanceFinished;
-import org.jclouds.deltacloud.predicates.InstanceRunning;
-import org.jclouds.domain.LoginCredentials;
-import org.jclouds.http.HttpRequest;
-import org.jclouds.logging.Logger;
-import org.jclouds.predicates.RetryablePredicate;
-
-import com.google.common.base.Predicate;
-import com.google.common.collect.ImmutableMap;
-import com.google.common.collect.ImmutableSet;
-import com.google.common.collect.Iterables;
-import com.google.common.collect.Multimap;
-
-/**
- * defines the connection between the {@link DeltacloudClient} implementation
- * and the jclouds {@link ComputeService}
- *
- */
-@Singleton
-public class DeltacloudComputeServiceAdapter implements
- ComputeServiceAdapter {
- @Resource
- @Named(ComputeServiceConstants.COMPUTE_LOGGER)
- protected Logger logger = Logger.NULL;
-
- private final org.jclouds.deltacloud.DeltacloudClient client;
- private final ImmutableMap> stateChanges;
-
- @Inject
- public DeltacloudComputeServiceAdapter(DeltacloudClient client) {
- this.client = checkNotNull(client, "client");
- // TODO: parameterize
- stateChanges = ImmutableMap.> of(//
- Instance.State.RUNNING, new RetryablePredicate(new InstanceRunning(client), 600, 1,
- TimeUnit.SECONDS),//
- Instance.State.FINISH, new RetryablePredicate(new InstanceFinished(client), 30, 1,
- TimeUnit.SECONDS)//
- );
- }
-
- @Override
- public NodeAndInitialCredentials createNodeWithGroupEncodedIntoName(String tag, String name,
- Template template) {
- Instance instance = client.createInstance(template.getImage().getProviderId(), CreateInstanceOptions.Builder
- .named(name).hardwareProfile(template.getHardware().getId()).realm(template.getLocation().getId()));
- LoginCredentials creds = null;
- if (instance.getAuthentication() != null && instance.getAuthentication() instanceof PasswordAuthentication) {
- creds = PasswordAuthentication.class.cast(instance.getAuthentication()).getLoginCredentials();
- }
- return new NodeAndInitialCredentials(instance, instance.getId(), creds);
- }
-
- @Override
- public Iterable listHardwareProfiles() {
- return client.listHardwareProfiles();
- }
-
- @Override
- public Iterable listImages() {
- return client.listImages();
- }
-
- @Override
- public Iterable listNodes() {
- return client.listInstances();
- }
-
- @Override
- public Iterable listLocations() {
- return client.listRealms();
- }
-
- @Override
- public org.jclouds.deltacloud.domain.Instance getNode(String id) {
- return client.getInstance(URI.create(checkNotNull(id, "id")));
- }
-
- @Override
- public org.jclouds.deltacloud.domain.Image getImage(String id) {
- return client.getImage(URI.create(checkNotNull(id, "id")));
- }
-
- @Override
- public void destroyNode(String id) {
- Instance instance = getNode(id);
- for (Transition transition : findChainTo(Instance.State.FINISH, instance.getState(), client.getInstanceStates())) {
- instance = getNode(id);
- if (instance == null)
- break;
- if (transition instanceof TransitionOnAction) {
- client.performAction(instance.getActions().get(TransitionOnAction.class.cast(transition).getAction()));
- }
- Predicate stateTester = stateChanges.get(transition.getTo());
- if (stateTester != null)
- stateTester.apply(instance);
- else
- logger.debug(String.format("no state tester for: %s", transition));
- }
- }
-
- Iterable findChainTo(Instance.State desired, Instance.State currentState,
- Multimap states) {
- for (Transition transition : states.get(currentState)) {
- if (currentState.ordinal() >= transition.getTo().ordinal())
- continue;
- if (transition.getTo() == desired)
- return ImmutableSet. of(transition);
- Iterable transitions = findChainTo(desired, transition.getTo(), states);
- if (Iterables.size(transitions) > 0)
- return Iterables.concat(ImmutableSet.of(transition), transitions);
- }
- return ImmutableSet. of();
- }
-
- @Override
- public void rebootNode(String id) {
- HttpRequest rebootUri = getNode(id).getActions().get(Instance.Action.REBOOT);
- if (rebootUri != null) {
- client.performAction(rebootUri);
- } else {
- throw new UnsupportedOperationException();
- }
- }
-
- @Override
- public void resumeNode(String id) {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public void suspendNode(String id) {
- throw new UnsupportedOperationException();
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/config/DeltacloudRestClientModule.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/config/DeltacloudRestClientModule.java
deleted file mode 100644
index fbc2fc9083..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/config/DeltacloudRestClientModule.java
+++ /dev/null
@@ -1,158 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.config;
-
-import static org.jclouds.Constants.PROPERTY_SESSION_INTERVAL;
-
-import java.net.URI;
-import java.util.NoSuchElementException;
-import java.util.Set;
-import java.util.concurrent.TimeUnit;
-import java.util.concurrent.atomic.AtomicReference;
-
-import javax.inject.Named;
-import javax.inject.Singleton;
-
-import org.jclouds.deltacloud.DeltacloudAsyncClient;
-import org.jclouds.deltacloud.DeltacloudClient;
-import org.jclouds.deltacloud.collections.HardwareProfiles;
-import org.jclouds.deltacloud.collections.Images;
-import org.jclouds.deltacloud.collections.InstanceStates;
-import org.jclouds.deltacloud.collections.Instances;
-import org.jclouds.deltacloud.collections.Realms;
-import org.jclouds.deltacloud.domain.DeltacloudCollection;
-import org.jclouds.deltacloud.handlers.DeltacloudErrorHandler;
-import org.jclouds.deltacloud.handlers.DeltacloudRedirectionRetryHandler;
-import org.jclouds.http.HttpErrorHandler;
-import org.jclouds.http.HttpRetryHandler;
-import org.jclouds.http.annotation.ClientError;
-import org.jclouds.http.annotation.Redirection;
-import org.jclouds.http.annotation.ServerError;
-import org.jclouds.rest.AuthorizationException;
-import org.jclouds.rest.ConfiguresRestClient;
-import org.jclouds.rest.config.RestClientModule;
-import org.jclouds.rest.suppliers.MemoizedRetryOnTimeOutButNotOnAuthorizationExceptionSupplier;
-import org.jclouds.util.Suppliers2;
-
-import com.google.common.base.Function;
-import com.google.common.base.Objects;
-import com.google.common.base.Predicate;
-import com.google.common.base.Supplier;
-import com.google.common.collect.Iterables;
-import com.google.common.util.concurrent.Atomics;
-import com.google.inject.Provides;
-
-/**
- * Configures the deltacloud connection.
- *
- * @author Adrian Cole
- */
-@ConfiguresRestClient
-public class DeltacloudRestClientModule extends RestClientModule {
-
- @Override
- protected void bindErrorHandlers() {
- bind(HttpErrorHandler.class).annotatedWith(Redirection.class).to(DeltacloudErrorHandler.class);
- bind(HttpErrorHandler.class).annotatedWith(ClientError.class).to(DeltacloudErrorHandler.class);
- bind(HttpErrorHandler.class).annotatedWith(ServerError.class).to(DeltacloudErrorHandler.class);
- }
-
- @Override
- protected void bindRetryHandlers() {
- bind(HttpRetryHandler.class).annotatedWith(Redirection.class).to(DeltacloudRedirectionRetryHandler.class);
- }
-
- protected AtomicReference authException = Atomics.newReference();
-
- @Provides
- @Singleton
- protected Supplier> provideCollections(
- @Named(PROPERTY_SESSION_INTERVAL) long seconds, final DeltacloudClient client) {
- return MemoizedRetryOnTimeOutButNotOnAuthorizationExceptionSupplier.create(
- authException, new Supplier>() {
- @Override
- public Set extends DeltacloudCollection> get() {
- return client.getCollections();
- }
- @Override
- public String toString() {
- return Objects.toStringHelper(client).add("method", "getCollections").toString();
- }
- }, seconds, TimeUnit.SECONDS);
- }
-
- /**
- * since the supplier is memoized, and there are no objects created here, this doesn't need to be
- * singleton.
- */
- @Provides
- @Images
- protected Supplier provideImageCollection(Supplier> collectionSupplier) {
- return Suppliers2.compose(new FindCollectionWithRelAndReturnHref("images"), collectionSupplier);
- }
-
- public static class FindCollectionWithRelAndReturnHref implements Function, URI> {
- private final String rel;
-
- public FindCollectionWithRelAndReturnHref(String rel) {
- this.rel = rel;
- }
-
- @Override
- public URI apply(Set extends DeltacloudCollection> arg0) {
- try {
- return Iterables.find(arg0, new Predicate() {
-
- @Override
- public boolean apply(DeltacloudCollection arg0) {
- return arg0.getRel().equals(rel);
- }
-
- }).getHref();
- } catch (NoSuchElementException e) {
- throw new NoSuchElementException("could not find rel " + rel + " in collections " + arg0);
- }
- }
-
- }
-
- @Provides
- @HardwareProfiles
- protected Supplier provideHardwareProfileCollection(Supplier> collectionSupplier) {
- return Suppliers2.compose(new FindCollectionWithRelAndReturnHref("hardware_profiles"), collectionSupplier);
- }
-
- @Provides
- @Instances
- protected Supplier provideInstanceCollection(Supplier> collectionSupplier) {
- return Suppliers2.compose(new FindCollectionWithRelAndReturnHref("instances"), collectionSupplier);
- }
-
- @Provides
- @Realms
- protected Supplier provideRealmCollection(Supplier> collectionSupplier) {
- return Suppliers2.compose(new FindCollectionWithRelAndReturnHref("realms"), collectionSupplier);
- }
-
- @Provides
- @InstanceStates
- protected Supplier provideInstanceStateCollection(Supplier> collectionSupplier) {
- return Suppliers2.compose(new FindCollectionWithRelAndReturnHref("instance_states"), collectionSupplier);
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/Architecture.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/Architecture.java
deleted file mode 100644
index 2c41976e1b..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/Architecture.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.domain;
-
-/**
- *
- * @author Adrian Cole
- */
-public interface Architecture {
- public static final String I386 = "i386";
- public static final String X86_64 = "x86_64";
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/DeltacloudCollection.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/DeltacloudCollection.java
deleted file mode 100644
index bfb9f575f2..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/DeltacloudCollection.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.domain;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.net.URI;
-import java.util.Set;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- *
- * @author Adrian Cole
- */
-public class DeltacloudCollection {
- private final URI href;
- private final String rel;
- private final Set extends Feature> features;
-
- public DeltacloudCollection(URI href, String rel) {
- this(href, rel, ImmutableSet. of());
- }
-
- public DeltacloudCollection(URI href, String rel, Set extends Feature> features) {
- this.href = checkNotNull(href, "href");
- this.rel = checkNotNull(rel, "rel");
- this.features = ImmutableSet.copyOf(checkNotNull(features, "features"));
- }
-
- public URI getHref() {
- return href;
- }
-
- public String getRel() {
- return rel;
- }
-
- public Set extends Feature> getFeatures() {
- return features;
- }
-
- @Override
- public int hashCode() {
- final int prime = 31;
- int result = 1;
- result = prime * result + ((features == null) ? 0 : features.hashCode());
- result = prime * result + ((href == null) ? 0 : href.hashCode());
- result = prime * result + ((rel == null) ? 0 : rel.hashCode());
- return result;
- }
-
- @Override
- public boolean equals(Object obj) {
- if (this == obj)
- return true;
- if (obj == null)
- return false;
- if (getClass() != obj.getClass())
- return false;
- DeltacloudCollection other = (DeltacloudCollection) obj;
- if (features == null) {
- if (other.features != null)
- return false;
- } else if (!features.equals(other.features))
- return false;
- if (href == null) {
- if (other.href != null)
- return false;
- } else if (!href.equals(other.href))
- return false;
- if (rel == null) {
- if (other.rel != null)
- return false;
- } else if (!rel.equals(other.rel))
- return false;
- return true;
- }
-
- @Override
- public String toString() {
- return "[href=" + href + ", rel=" + rel + ", features=" + features + "]";
- }
-}
diff --git a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/EnumHardwareProperty.java b/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/EnumHardwareProperty.java
deleted file mode 100644
index 3de1d06d24..0000000000
--- a/apis/deltacloud/src/main/java/org/jclouds/deltacloud/domain/EnumHardwareProperty.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/**
- * Licensed to jclouds, Inc. (jclouds) under one or more
- * contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. jclouds licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.jclouds.deltacloud.domain;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.util.Set;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- *
- * @author Adrian Cole
- */
-public class EnumHardwareProperty extends ParameterizedHardwareProperty {
-
- private final Set