mirror of https://github.com/apache/jclouds.git
Issue 550: added providermetadata for Bluelock
This commit is contained in:
parent
1d23698300
commit
efb8f0103e
|
@ -92,8 +92,8 @@ cloudservers-uk.propertiesbuilder=org.jclouds.rackspace.cloudservers.CloudServer
|
||||||
cloudservers-us.contextbuilder=org.jclouds.cloudservers.CloudServersContextBuilder
|
cloudservers-us.contextbuilder=org.jclouds.cloudservers.CloudServersContextBuilder
|
||||||
cloudservers-us.propertiesbuilder=org.jclouds.rackspace.cloudservers.CloudServersUSPropertiesBuilder
|
cloudservers-us.propertiesbuilder=org.jclouds.rackspace.cloudservers.CloudServersUSPropertiesBuilder
|
||||||
|
|
||||||
bluelock-vcdirector.contextbuilder=org.jclouds.vcloud.bluelock.BlueLockVCloudDirectorContextBuilder
|
bluelock-vcdirector.contextbuilder=org.jclouds.vcloud.bluelock.BluelockVCloudDirectorContextBuilder
|
||||||
bluelock-vcdirector.propertiesbuilder=org.jclouds.vcloud.bluelock.BlueLockVCloudDirectorPropertiesBuilder
|
bluelock-vcdirector.propertiesbuilder=org.jclouds.vcloud.bluelock.BluelockVCloudDirectorPropertiesBuilder
|
||||||
|
|
||||||
gogrid.propertiesbuilder=org.jclouds.gogrid.GoGridPropertiesBuilder
|
gogrid.propertiesbuilder=org.jclouds.gogrid.GoGridPropertiesBuilder
|
||||||
gogrid.contextbuilder=org.jclouds.gogrid.GoGridContextBuilder
|
gogrid.contextbuilder=org.jclouds.gogrid.GoGridContextBuilder
|
||||||
|
|
|
@ -24,7 +24,7 @@ import java.util.Properties;
|
||||||
import org.jclouds.http.config.JavaUrlHttpCommandExecutorServiceModule;
|
import org.jclouds.http.config.JavaUrlHttpCommandExecutorServiceModule;
|
||||||
import org.jclouds.logging.jdk.config.JDKLoggingModule;
|
import org.jclouds.logging.jdk.config.JDKLoggingModule;
|
||||||
import org.jclouds.vcloud.VCloudContextBuilder;
|
import org.jclouds.vcloud.VCloudContextBuilder;
|
||||||
import org.jclouds.vcloud.bluelock.config.BlueLockVCloudDirectorRestClientModule;
|
import org.jclouds.vcloud.bluelock.config.BluelockVCloudDirectorRestClientModule;
|
||||||
import org.jclouds.vcloud.compute.config.VCloudComputeServiceContextModule;
|
import org.jclouds.vcloud.compute.config.VCloudComputeServiceContextModule;
|
||||||
|
|
||||||
import com.google.inject.Injector;
|
import com.google.inject.Injector;
|
||||||
|
@ -41,11 +41,10 @@ import com.google.inject.Module;
|
||||||
* {@link JavaUrlHttpCommandExecutorServiceModule http transports} will be installed.
|
* {@link JavaUrlHttpCommandExecutorServiceModule http transports} will be installed.
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
* @see BlueLockVCloudComputeServiceContext
|
|
||||||
*/
|
*/
|
||||||
public class BlueLockVCloudDirectorContextBuilder extends VCloudContextBuilder {
|
public class BluelockVCloudDirectorContextBuilder extends VCloudContextBuilder {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorContextBuilder(Properties props) {
|
public BluelockVCloudDirectorContextBuilder(Properties props) {
|
||||||
super(props);
|
super(props);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -56,7 +55,7 @@ public class BlueLockVCloudDirectorContextBuilder extends VCloudContextBuilder {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void addClientModule(List<Module> modules) {
|
protected void addClientModule(List<Module> modules) {
|
||||||
modules.add(new BlueLockVCloudDirectorRestClientModule());
|
modules.add(new BluelockVCloudDirectorRestClientModule());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,7 @@ import org.jclouds.vcloud.VCloudPropertiesBuilder;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
public class BlueLockVCloudDirectorPropertiesBuilder extends VCloudPropertiesBuilder {
|
public class BluelockVCloudDirectorPropertiesBuilder extends VCloudPropertiesBuilder {
|
||||||
@Override
|
@Override
|
||||||
protected Properties defaultProperties() {
|
protected Properties defaultProperties() {
|
||||||
Properties properties = super.defaultProperties();
|
Properties properties = super.defaultProperties();
|
||||||
|
@ -41,7 +41,7 @@ public class BlueLockVCloudDirectorPropertiesBuilder extends VCloudPropertiesBui
|
||||||
return properties;
|
return properties;
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlueLockVCloudDirectorPropertiesBuilder(Properties properties) {
|
public BluelockVCloudDirectorPropertiesBuilder(Properties properties) {
|
||||||
super(properties);
|
super(properties);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,116 @@
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Copyright (C) 2011 Cloud Conscious, LLC. <info@cloudconscious.com>
|
||||||
|
*
|
||||||
|
* ====================================================================
|
||||||
|
* Licensed 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.vcloud.bluelock;
|
||||||
|
|
||||||
|
import com.google.common.collect.ImmutableSet;
|
||||||
|
|
||||||
|
import java.net.URI;
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
|
import org.jclouds.providers.BaseProviderMetadata;
|
||||||
|
import org.jclouds.providers.ProviderMetadata;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Implementation of {@link org.jclouds.types.ProviderMetadata} for Bluelock vCloud Director.
|
||||||
|
*
|
||||||
|
* @author Adrian Cole
|
||||||
|
*/
|
||||||
|
public class BluelockVCloudDirectorProviderMetadata extends BaseProviderMetadata {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String getId() {
|
||||||
|
return "bluelock-vcdirector";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String getType() {
|
||||||
|
return ProviderMetadata.COMPUTE_TYPE;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String getName() {
|
||||||
|
return "Bluelock vCloud Director";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String getIdentityName() {
|
||||||
|
return "User at Organization (user@org)";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String getCredentialName() {
|
||||||
|
return "Password";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public URI getHomepage() {
|
||||||
|
return URI.create("http://www.bluelock.com/bluelock-cloud-hosting");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public URI getConsole() {
|
||||||
|
return URI.create("https://vcenterprise.bluelock.com/cloud/");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public URI getApiDocumentation() {
|
||||||
|
return URI.create("http://www.vmware.com/support/pubs/vcd_pubs.html");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public Set<String> getLinkedServices() {
|
||||||
|
return ImmutableSet.of("bluelock-vcdirector");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public Set<String> getIso3166Codes() {
|
||||||
|
return ImmutableSet.of("US-IN");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
|
@ -29,6 +29,6 @@ import org.jclouds.vcloud.config.VCloudRestClientModule;
|
||||||
*/
|
*/
|
||||||
@RequiresHttp
|
@RequiresHttp
|
||||||
@ConfiguresRestClient
|
@ConfiguresRestClient
|
||||||
public class BlueLockVCloudDirectorRestClientModule extends VCloudRestClientModule {
|
public class BluelockVCloudDirectorRestClientModule extends VCloudRestClientModule {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
org.jclouds.vcloud.bluelock.BluelockVCloudDirectorProviderMetadata
|
|
@ -18,31 +18,18 @@
|
||||||
*/
|
*/
|
||||||
package org.jclouds.vcloud.bluelock;
|
package org.jclouds.vcloud.bluelock;
|
||||||
|
|
||||||
import org.jclouds.compute.util.ComputeServiceUtils;
|
import org.jclouds.providers.BaseProviderMetadataTest;
|
||||||
import org.jclouds.rest.Providers;
|
import org.jclouds.providers.ProviderMetadata;
|
||||||
import org.testng.annotations.Test;
|
import org.testng.annotations.Test;
|
||||||
|
|
||||||
import com.google.common.collect.Iterables;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
@Test(groups = "unit")
|
@Test(groups = "unit", testName = "BluelockVCloudDirectorProviderTest")
|
||||||
public class ProvidersInPropertiesTest {
|
public class BluelockVCloudDirectorProviderTest extends BaseProviderMetadataTest {
|
||||||
|
|
||||||
@Test
|
|
||||||
public void testSupportedProviders() {
|
|
||||||
Iterable<String> providers = Providers.getSupportedProviders();
|
|
||||||
assert Iterables.contains(providers, "bluelock-vcdirector") : providers;
|
|
||||||
|
|
||||||
|
public BluelockVCloudDirectorProviderTest() {
|
||||||
|
super(new BluelockVCloudDirectorProviderMetadata(), ProviderMetadata.COMPUTE_TYPE);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
public void testSupportedComputeServiceProviders() {
|
|
||||||
Iterable<String> providers = ComputeServiceUtils.getSupportedProviders();
|
|
||||||
assert Iterables.contains(providers, "bluelock-vcdirector") : providers;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
|
@ -22,14 +22,13 @@ import org.jclouds.vcloud.DeprecatedVCloudClientLiveTest;
|
||||||
import org.testng.annotations.Test;
|
import org.testng.annotations.Test;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tests behavior of {@code BlueLockVCloudClient}
|
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Deprecated
|
@Deprecated
|
||||||
@Test(groups = "live", singleThreaded = true)
|
@Test(groups = "live", singleThreaded = true, testName = "DeprecatedBluelockVCloudDirectorClientLiveTest")
|
||||||
public class DeprecatedBlueLockVCloudDirectorClientLiveTest extends DeprecatedVCloudClientLiveTest {
|
public class DeprecatedBluelockVCloudDirectorClientLiveTest extends DeprecatedVCloudClientLiveTest {
|
||||||
public DeprecatedBlueLockVCloudDirectorClientLiveTest() {
|
public DeprecatedBluelockVCloudDirectorClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -34,9 +34,9 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, sequential = true)
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorComputeServiceLiveTest")
|
||||||
public class BlueLockVCloudDirectorComputeServiceLiveTest extends VCloudComputeServiceLiveTest {
|
public class BluelockVCloudDirectorComputeServiceLiveTest extends VCloudComputeServiceLiveTest {
|
||||||
public BlueLockVCloudDirectorComputeServiceLiveTest() {
|
public BluelockVCloudDirectorComputeServiceLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
// vcloud requires instantiate before deploy, which takes longer than 30 seconds
|
// vcloud requires instantiate before deploy, which takes longer than 30 seconds
|
||||||
nonBlockDuration = 300;
|
nonBlockDuration = 300;
|
||||||
|
|
|
@ -37,10 +37,10 @@ import com.google.common.collect.ImmutableSet;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live")
|
@Test(groups = "live", testName = "BluelockVCloudDirectorTemplateBuilderLiveTest")
|
||||||
public class BlueLockVCloudDirectorTemplateBuilderLiveTest extends BaseTemplateBuilderLiveTest {
|
public class BluelockVCloudDirectorTemplateBuilderLiveTest extends BaseTemplateBuilderLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorTemplateBuilderLiveTest() {
|
public BluelockVCloudDirectorTemplateBuilderLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorCatalogClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorCatalogClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorCatalogClientLiveTest extends CatalogClientLiveTest {
|
public class BluelockVCloudDirectorCatalogClientLiveTest extends CatalogClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorCatalogClientLiveTest() {
|
public BluelockVCloudDirectorCatalogClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorNetworkClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorNetworkClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorNetworkClientLiveTest extends NetworkClientLiveTest {
|
public class BluelockVCloudDirectorNetworkClientLiveTest extends NetworkClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorNetworkClientLiveTest() {
|
public BluelockVCloudDirectorNetworkClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorOrgClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorOrgClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorOrgClientLiveTest extends OrgClientLiveTest {
|
public class BluelockVCloudDirectorOrgClientLiveTest extends OrgClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorOrgClientLiveTest() {
|
public BluelockVCloudDirectorOrgClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorTaskClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorTaskClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorTaskClientLiveTest extends TaskClientLiveTest {
|
public class BluelockVCloudDirectorTaskClientLiveTest extends TaskClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorTaskClientLiveTest() {
|
public BluelockVCloudDirectorTaskClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorVAppClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorVAppClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorVAppClientLiveTest extends VAppClientLiveTest {
|
public class BluelockVCloudDirectorVAppClientLiveTest extends VAppClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorVAppClientLiveTest() {
|
public BluelockVCloudDirectorVAppClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorVAppTemplateClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorVAppTemplateClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorVAppTemplateClientLiveTest extends VAppTemplateClientLiveTest {
|
public class BluelockVCloudDirectorVAppTemplateClientLiveTest extends VAppTemplateClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorVAppTemplateClientLiveTest() {
|
public BluelockVCloudDirectorVAppTemplateClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorVDCClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorVDCClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorVDCClientLiveTest extends VDCClientLiveTest {
|
public class BluelockVCloudDirectorVDCClientLiveTest extends VDCClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorVDCClientLiveTest() {
|
public BluelockVCloudDirectorVDCClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -26,10 +26,10 @@ import org.testng.annotations.Test;
|
||||||
*
|
*
|
||||||
* @author Adrian Cole
|
* @author Adrian Cole
|
||||||
*/
|
*/
|
||||||
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BlueLockVCloudDirectorVmClientLiveTest")
|
@Test(groups = "live", enabled = true, singleThreaded = true, testName = "BluelockVCloudDirectorVmClientLiveTest")
|
||||||
public class BlueLockVCloudDirectorVmClientLiveTest extends VmClientLiveTest {
|
public class BluelockVCloudDirectorVmClientLiveTest extends VmClientLiveTest {
|
||||||
|
|
||||||
public BlueLockVCloudDirectorVmClientLiveTest() {
|
public BluelockVCloudDirectorVmClientLiveTest() {
|
||||||
provider = "bluelock-vcdirector";
|
provider = "bluelock-vcdirector";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue