@Singleton public class CloudStackComputeService extends BaseComputeService
Modifier and Type | Field and Description |
---|---|
protected CloudStackApi |
client |
protected com.google.common.cache.LoadingCache<String,SshKeyPair> |
keyPairCache |
protected GroupNamingConvention.Factory |
namingConvention |
protected com.google.common.base.Function<Set<? extends NodeMetadata>,com.google.common.collect.Multimap<String,String>> |
orphanedGroupsByZoneId |
protected com.google.common.cache.LoadingCache<ZoneAndName,SecurityGroup> |
securityGroupMap |
protected com.google.common.base.Supplier<com.google.common.cache.LoadingCache<String,Zone>> |
zoneIdToZone |
context, credentialStore, logger
Modifier | Constructor and Description |
---|---|
protected |
CloudStackComputeService(ComputeServiceContext context,
Map<String,Credentials> credentialStore,
com.google.common.base.Supplier<Set<? extends Image>> images,
com.google.common.base.Supplier<Set<? extends Hardware>> sizes,
com.google.common.base.Supplier<Set<? extends Location>> locations,
ListNodesStrategy listNodesStrategy,
GetImageStrategy getImageStrategy,
GetNodeMetadataStrategy getNodeMetadataStrategy,
CreateNodesInGroupThenAddToSet runNodesAndAddToSetStrategy,
RebootNodeStrategy rebootNodeStrategy,
DestroyNodeStrategy destroyNodeStrategy,
ResumeNodeStrategy startNodeStrategy,
SuspendNodeStrategy stopNodeStrategy,
javax.inject.Provider<TemplateBuilder> templateBuilderProvider,
javax.inject.Provider<TemplateOptions> templateOptionsProvider,
com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeRunning,
com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeTerminated,
com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeSuspended,
InitializeRunScriptOnNodeOrPlaceInBadMap.Factory initScriptRunnerFactory,
RunScriptOnNode.Factory runScriptOnNodeFactory,
InitAdminAccess initAdminAccess,
PersistNodeCredentials persistNodeCredentials,
ComputeServiceConstants.Timeouts timeouts,
com.google.common.util.concurrent.ListeningExecutorService userExecutor,
CloudStackApi client,
com.google.common.cache.LoadingCache<ZoneAndName,SecurityGroup> securityGroupMap,
com.google.common.cache.LoadingCache<String,SshKeyPair> keyPairCache,
com.google.common.base.Function<Set<? extends NodeMetadata>,com.google.common.collect.Multimap<String,String>> orphanedGroupsByZoneId,
GroupNamingConvention.Factory namingConvention,
com.google.common.base.Supplier<com.google.common.cache.LoadingCache<String,Zone>> zoneIdToZone,
com.google.common.base.Optional<ImageExtension> imageExtension,
com.google.common.base.Optional<SecurityGroupExtension> securityGroupExtension) |
Modifier and Type | Method and Description |
---|---|
protected void |
cleanOrphanedGroupsInZone(Set<String> groups,
String zoneId) |
protected void |
cleanUpIncidentalResourcesOfDeadNodes(Set<? extends NodeMetadata> deadNodes) |
CloudStackTemplateOptions |
templateOptions()
returns template options, as
CloudStackTemplateOptions . |
createNodesInGroup, createNodesInGroup, createNodesInGroup, destroyNode, destroyNodesMatching, doDestroyNode, getContext, getImage, getImageExtension, getNodeMetadata, getSecurityGroupExtension, listAssignableLocations, listHardwareProfiles, listImages, listNodes, listNodesByIds, listNodesDetailsMatching, rebootNode, rebootNodesMatching, resumeNode, resumeNodesMatching, runScriptOnNode, runScriptOnNode, runScriptOnNode, runScriptOnNode, runScriptOnNodesMatching, runScriptOnNodesMatching, runScriptOnNodesMatching, runScriptOnNodesMatching, submitScriptOnNode, submitScriptOnNode, suspendNode, suspendNodesMatching, templateBuilder, updateNodeWithCredentialsIfPresent
protected final CloudStackApi client
protected final com.google.common.cache.LoadingCache<ZoneAndName,SecurityGroup> securityGroupMap
protected final com.google.common.cache.LoadingCache<String,SshKeyPair> keyPairCache
protected final com.google.common.base.Function<Set<? extends NodeMetadata>,com.google.common.collect.Multimap<String,String>> orphanedGroupsByZoneId
protected final GroupNamingConvention.Factory namingConvention
@Inject protected CloudStackComputeService(ComputeServiceContext context, Map<String,Credentials> credentialStore, com.google.common.base.Supplier<Set<? extends Image>> images, com.google.common.base.Supplier<Set<? extends Hardware>> sizes, com.google.common.base.Supplier<Set<? extends Location>> locations, ListNodesStrategy listNodesStrategy, GetImageStrategy getImageStrategy, GetNodeMetadataStrategy getNodeMetadataStrategy, CreateNodesInGroupThenAddToSet runNodesAndAddToSetStrategy, RebootNodeStrategy rebootNodeStrategy, DestroyNodeStrategy destroyNodeStrategy, ResumeNodeStrategy startNodeStrategy, SuspendNodeStrategy stopNodeStrategy, javax.inject.Provider<TemplateBuilder> templateBuilderProvider, @Named(value="DEFAULT") javax.inject.Provider<TemplateOptions> templateOptionsProvider, @Named(value="jclouds.compute.timeout.node-running") com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeRunning, @Named(value="jclouds.compute.timeout.node-terminated") com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeTerminated, @Named(value="jclouds.compute.timeout.node-suspended") com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeSuspended, InitializeRunScriptOnNodeOrPlaceInBadMap.Factory initScriptRunnerFactory, RunScriptOnNode.Factory runScriptOnNodeFactory, InitAdminAccess initAdminAccess, PersistNodeCredentials persistNodeCredentials, ComputeServiceConstants.Timeouts timeouts, @Named(value="jclouds.user-threads") com.google.common.util.concurrent.ListeningExecutorService userExecutor, CloudStackApi client, com.google.common.cache.LoadingCache<ZoneAndName,SecurityGroup> securityGroupMap, com.google.common.cache.LoadingCache<String,SshKeyPair> keyPairCache, com.google.common.base.Function<Set<? extends NodeMetadata>,com.google.common.collect.Multimap<String,String>> orphanedGroupsByZoneId, GroupNamingConvention.Factory namingConvention, com.google.common.base.Supplier<com.google.common.cache.LoadingCache<String,Zone>> zoneIdToZone, com.google.common.base.Optional<ImageExtension> imageExtension, com.google.common.base.Optional<SecurityGroupExtension> securityGroupExtension)
protected void cleanUpIncidentalResourcesOfDeadNodes(Set<? extends NodeMetadata> deadNodes)
cleanUpIncidentalResourcesOfDeadNodes
in class BaseComputeService
protected void cleanOrphanedGroupsInZone(Set<String> groups, String zoneId)
public CloudStackTemplateOptions templateOptions()
CloudStackTemplateOptions
.templateOptions
in interface ComputeService
templateOptions
in class BaseComputeService
Copyright © 2009-2016 The Apache Software Foundation. All Rights Reserved.