Package org.jclouds.ec2.compute.config
Class EC2ComputeServiceDependenciesModule
- java.lang.Object
-
- com.google.inject.AbstractModule
-
- org.jclouds.ec2.compute.config.EC2ComputeServiceDependenciesModule
-
- All Implemented Interfaces:
com.google.inject.Module
- Direct Known Subclasses:
AWSEC2ComputeServiceDependenciesModule
public class EC2ComputeServiceDependenciesModule extends com.google.inject.AbstractModule
-
-
Field Summary
Fields Modifier and Type Field Description static Map<Image.ImageState,Image.Status>
toPortableImageStatus
static Map<InstanceState,NodeMetadata.Status>
toPortableNodeStatus
-
Constructor Summary
Constructors Constructor Description EC2ComputeServiceDependenciesModule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.google.common.base.Function<RunningInstance,NodeMetadata>
bindNodeConverter(RunningInstanceToNodeMetadata baseConverter, AddElasticIpsToNodemetadata addElasticIpsToNodemetadata, boolean autoAllocateElasticIps)
only add the overhead of looking up ips when we have enabled the auto-allocate functionalityprotected void
configure()
protected com.google.common.cache.LoadingCache<RunningInstance,com.google.common.base.Optional<LoginCredentials>>
credentialsMap(com.google.common.cache.CacheLoader<RunningInstance,com.google.common.base.Optional<LoginCredentials>> in)
protected com.google.common.cache.LoadingCache<RegionAndName,String>
instanceToElasticIp(com.google.common.cache.CacheLoader<RegionAndName,String> in)
protected ConcurrentMap<RegionAndName,KeyPair>
keypairMap(com.google.inject.Injector i)
protected com.google.common.base.Predicate<RegionAndName>
securityGroupEventualConsistencyDelay(SecurityGroupPresent in, long msDelay)
protected com.google.common.cache.LoadingCache<RegionAndName,String>
securityGroupMap(com.google.common.cache.CacheLoader<RegionAndName,String> in)
protected Map<Image.ImageState,Image.Status>
toPortableImageStatus()
protected Map<InstanceState,NodeMetadata.Status>
toPortableNodeStatus()
-
Methods inherited from class com.google.inject.AbstractModule
addError, addError, addError, bind, bind, bind, bindConstant, binder, bindInterceptor, bindListener, bindListener, bindScope, configure, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, requestInjection, requestStaticInjection, requireBinding, requireBinding
-
-
-
-
Field Detail
-
toPortableNodeStatus
public static final Map<InstanceState,NodeMetadata.Status> toPortableNodeStatus
-
toPortableImageStatus
public static final Map<Image.ImageState,Image.Status> toPortableImageStatus
-
-
Method Detail
-
toPortableNodeStatus
@Singleton @Provides protected final Map<InstanceState,NodeMetadata.Status> toPortableNodeStatus()
-
toPortableImageStatus
@Singleton @Provides protected final Map<Image.ImageState,Image.Status> toPortableImageStatus()
-
configure
protected void configure()
- Overrides:
configure
in classcom.google.inject.AbstractModule
-
bindNodeConverter
@Provides @Singleton public final com.google.common.base.Function<RunningInstance,NodeMetadata> bindNodeConverter(RunningInstanceToNodeMetadata baseConverter, AddElasticIpsToNodemetadata addElasticIpsToNodemetadata, @Named("jclouds.ec2.auto-allocate-elastic-ips") boolean autoAllocateElasticIps)
only add the overhead of looking up ips when we have enabled the auto-allocate functionality
-
credentialsMap
@Provides @Singleton protected final com.google.common.cache.LoadingCache<RunningInstance,com.google.common.base.Optional<LoginCredentials>> credentialsMap(com.google.common.cache.CacheLoader<RunningInstance,com.google.common.base.Optional<LoginCredentials>> in)
-
keypairMap
@Provides @Singleton protected final ConcurrentMap<RegionAndName,KeyPair> keypairMap(com.google.inject.Injector i)
-
securityGroupMap
@Provides @Singleton @Named("SECURITY") protected final com.google.common.cache.LoadingCache<RegionAndName,String> securityGroupMap(@Named("SECURITY") com.google.common.cache.CacheLoader<RegionAndName,String> in)
-
instanceToElasticIp
@Provides @Singleton @Named("ELASTICIP") protected final com.google.common.cache.LoadingCache<RegionAndName,String> instanceToElasticIp(@Named("ELASTICIP") com.google.common.cache.CacheLoader<RegionAndName,String> in)
-
securityGroupEventualConsistencyDelay
@Provides @Singleton @Named("SECURITY") protected final com.google.common.base.Predicate<RegionAndName> securityGroupEventualConsistencyDelay(SecurityGroupPresent in, @Named("jclouds.ec2.timeout.securitygroup-present") long msDelay)
-
-