mirror of https://github.com/apache/jclouds.git
Renamed servers -> compute, ServerService -> ComputeService
git-svn-id: http://jclouds.googlecode.com/svn/trunk@2347 3d8758e0-26b5-11de-8745-db77d3ebf521
This commit is contained in:
parent
0823f73c0d
commit
84116b387c
|
@ -1,4 +1,4 @@
|
||||||
package org.jclouds.servers;
|
package org.jclouds.compute;
|
||||||
|
|
||||||
import java.util.SortedSet;
|
import java.util.SortedSet;
|
||||||
import java.util.concurrent.Future;
|
import java.util.concurrent.Future;
|
||||||
|
@ -8,7 +8,7 @@ import java.util.concurrent.Future;
|
||||||
*
|
*
|
||||||
* @author Ivan Meredith
|
* @author Ivan Meredith
|
||||||
*/
|
*/
|
||||||
public interface ServerService {
|
public interface ComputeService {
|
||||||
public Server createServerAndWait(String name, String profile, String image);
|
public Server createServerAndWait(String name, String profile, String image);
|
||||||
|
|
||||||
public Future<Server> createServer(String name, String profile, String image);
|
public Future<Server> createServer(String name, String profile, String image);
|
|
@ -1,4 +1,4 @@
|
||||||
package org.jclouds.servers;
|
package org.jclouds.compute;
|
||||||
|
|
||||||
import com.google.common.base.Service;
|
import com.google.common.base.Service;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package org.jclouds.servers;
|
package org.jclouds.compute;
|
||||||
|
|
||||||
import java.util.SortedSet;
|
import java.util.SortedSet;
|
||||||
import java.util.concurrent.Future;
|
import java.util.concurrent.Future;
|
|
@ -1,9 +1,8 @@
|
||||||
package org.jclouds.servers;
|
package org.jclouds.compute;
|
||||||
|
|
||||||
import com.google.common.base.Service;
|
import com.google.common.base.Service;
|
||||||
|
|
||||||
import java.util.SortedSet;
|
import java.util.SortedSet;
|
||||||
import java.util.concurrent.Future;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Ivan Meredith
|
* @author Ivan Meredith
|
|
@ -1,7 +1,7 @@
|
||||||
package org.jclouds.rimuhosting.miro.servers;
|
package org.jclouds.rimuhosting.miro.servers;
|
||||||
|
|
||||||
import org.jclouds.servers.ServerService;
|
import org.jclouds.compute.ComputeService;
|
||||||
import org.jclouds.servers.Server;
|
import org.jclouds.compute.Server;
|
||||||
import org.jclouds.rimuhosting.miro.RimuHostingClient;
|
import org.jclouds.rimuhosting.miro.RimuHostingClient;
|
||||||
import org.jclouds.rimuhosting.miro.domain.Instance;
|
import org.jclouds.rimuhosting.miro.domain.Instance;
|
||||||
import org.jclouds.rimuhosting.miro.domain.NewInstanceResponse;
|
import org.jclouds.rimuhosting.miro.domain.NewInstanceResponse;
|
||||||
|
@ -16,11 +16,11 @@ import java.util.TreeSet;
|
||||||
* @author Ivan Meredith
|
* @author Ivan Meredith
|
||||||
*/
|
*/
|
||||||
@Singleton
|
@Singleton
|
||||||
public class RimuHostingServerService implements ServerService {
|
public class RimuHostingComputeService implements ComputeService {
|
||||||
RimuHostingClient rhClient;
|
RimuHostingClient rhClient;
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
public RimuHostingServerService(RimuHostingClient rhClient){
|
public RimuHostingComputeService(RimuHostingClient rhClient){
|
||||||
this.rhClient = rhClient;
|
this.rhClient = rhClient;
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,30 +3,19 @@ package org.jclouds.rimuhosting.miro.servers;
|
||||||
import org.testng.annotations.Test;
|
import org.testng.annotations.Test;
|
||||||
import org.testng.annotations.BeforeGroups;
|
import org.testng.annotations.BeforeGroups;
|
||||||
import org.jclouds.rimuhosting.miro.*;
|
import org.jclouds.rimuhosting.miro.*;
|
||||||
import org.jclouds.rimuhosting.miro.config.RimuHostingRestClientModule;
|
|
||||||
import org.jclouds.logging.log4j.config.Log4JLoggingModule;
|
import org.jclouds.logging.log4j.config.Log4JLoggingModule;
|
||||||
import org.jclouds.ssh.jsch.config.JschSshClientModule;
|
import org.jclouds.compute.Server;
|
||||||
import org.jclouds.predicates.SocketOpen;
|
|
||||||
import org.jclouds.predicates.RetryablePredicate;
|
|
||||||
import org.jclouds.predicates.AddressReachable;
|
|
||||||
import org.jclouds.servers.Server;
|
|
||||||
import com.google.inject.*;
|
import com.google.inject.*;
|
||||||
import static com.google.common.base.Preconditions.checkNotNull;
|
import static com.google.common.base.Preconditions.checkNotNull;
|
||||||
import static org.testng.Assert.assertNotNull;
|
import static org.testng.Assert.assertNotNull;
|
||||||
|
|
||||||
import com.google.common.base.Predicate;
|
|
||||||
|
|
||||||
import java.net.InetSocketAddress;
|
|
||||||
import java.net.InetAddress;
|
|
||||||
import java.util.concurrent.TimeUnit;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Ivan Meredith
|
* @author Ivan Meredith
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", sequential = true, testName = "rimuhosting.RimuHostingServerServiceLiveTest")
|
@Test(groups = "live", sequential = true, testName = "rimuhosting.RimuHostingServerServiceLiveTest")
|
||||||
public class RimuHostingServerServiceLiveTest {
|
public class RimuHostingComputeServiceLiveTest {
|
||||||
RimuHostingClient rhClient;
|
RimuHostingClient rhClient;
|
||||||
RimuHostingServerService rhServerService;
|
RimuHostingComputeService rhServerService;
|
||||||
|
|
||||||
@BeforeGroups(groups = { "live" })
|
@BeforeGroups(groups = { "live" })
|
||||||
public void setupClient() {
|
public void setupClient() {
|
||||||
|
@ -36,7 +25,7 @@ public class RimuHostingServerServiceLiveTest {
|
||||||
account, key).relaxSSLHostname().build()).withModules(new Log4JLoggingModule()).buildInjector();
|
account, key).relaxSSLHostname().build()).withModules(new Log4JLoggingModule()).buildInjector();
|
||||||
|
|
||||||
rhClient = injector.getInstance(RimuHostingClient.class);
|
rhClient = injector.getInstance(RimuHostingClient.class);
|
||||||
rhServerService = injector.getInstance(RimuHostingServerService.class);
|
rhServerService = injector.getInstance(RimuHostingComputeService.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
|
@ -1,12 +1,10 @@
|
||||||
package org.jclouds.rimuhosting.miro.servers;
|
package org.jclouds.rimuhosting.miro.servers;
|
||||||
|
|
||||||
import org.jclouds.servers.Server;
|
import org.jclouds.compute.Server;
|
||||||
import org.jclouds.servers.Platform;
|
import org.jclouds.compute.Platform;
|
||||||
import org.jclouds.servers.Instance;
|
import org.jclouds.compute.Instance;
|
||||||
import org.jclouds.rimuhosting.miro.RimuHostingClient;
|
import org.jclouds.rimuhosting.miro.RimuHostingClient;
|
||||||
import com.google.common.base.Service;
|
|
||||||
|
|
||||||
import java.util.concurrent.Future;
|
|
||||||
import java.util.SortedSet;
|
import java.util.SortedSet;
|
||||||
|
|
||||||
public class RimuHostingServer implements Server {
|
public class RimuHostingServer implements Server {
|
||||||
|
|
Loading…
Reference in New Issue