@Singleton public class EC2ListNodesStrategy extends Object implements ListNodesStrategy
Modifier and Type | Field and Description |
---|---|
protected EC2Client |
client |
protected Logger |
logger |
protected static Long |
maxTime |
protected com.google.common.base.Supplier<Set<String>> |
regions |
protected com.google.common.base.Function<RunningInstance,NodeMetadata> |
runningInstanceToNodeMetadata |
protected com.google.common.util.concurrent.ListeningExecutorService |
userExecutor |
Modifier | Constructor and Description |
---|---|
protected |
EC2ListNodesStrategy(EC2Client client,
com.google.common.base.Supplier<Set<String>> regions,
com.google.common.base.Function<RunningInstance,NodeMetadata> runningInstanceToNodeMetadata,
com.google.common.util.concurrent.ListeningExecutorService userExecutor) |
Modifier and Type | Method and Description |
---|---|
protected com.google.common.base.Function<String,Set<? extends Reservation<? extends RunningInstance>>> |
allInstancesInRegion() |
protected com.google.common.base.Function<String,Set<? extends Reservation<? extends RunningInstance>>> |
instancesByIdInRegion(com.google.common.collect.Multimap<String,String> idsByRegions) |
Set<? extends NodeMetadata> |
listDetailsOnNodesMatching(com.google.common.base.Predicate<ComputeMetadata> filter) |
Set<? extends ComputeMetadata> |
listNodes() |
Set<? extends NodeMetadata> |
listNodesByIds(Iterable<String> ids) |
protected Iterable<? extends RunningInstance> |
pollRunningInstances() |
protected Iterable<? extends RunningInstance> |
pollRunningInstancesByRegionsAndIds(com.google.common.collect.Multimap<String,String> idsByRegions) |
protected com.google.common.base.Function<String,String> |
splitHandle(int pos) |
@Named(value="jclouds.compute") protected Logger logger
@Inject(optional=true) @Named(value="jclouds.request-timeout") protected static Long maxTime
protected final EC2Client client
protected final com.google.common.base.Function<RunningInstance,NodeMetadata> runningInstanceToNodeMetadata
protected final com.google.common.util.concurrent.ListeningExecutorService userExecutor
@Inject protected EC2ListNodesStrategy(EC2Client client, com.google.common.base.Supplier<Set<String>> regions, com.google.common.base.Function<RunningInstance,NodeMetadata> runningInstanceToNodeMetadata, @Named(value="jclouds.user-threads") com.google.common.util.concurrent.ListeningExecutorService userExecutor)
public Set<? extends ComputeMetadata> listNodes()
listNodes
in interface ListNodesStrategy
public Set<? extends NodeMetadata> listNodesByIds(Iterable<String> ids)
listNodesByIds
in interface ListNodesStrategy
public Set<? extends NodeMetadata> listDetailsOnNodesMatching(com.google.common.base.Predicate<ComputeMetadata> filter)
listDetailsOnNodesMatching
in interface ListNodesStrategy
protected Iterable<? extends RunningInstance> pollRunningInstances()
protected Iterable<? extends RunningInstance> pollRunningInstancesByRegionsAndIds(com.google.common.collect.Multimap<String,String> idsByRegions)
protected com.google.common.base.Function<String,Set<? extends Reservation<? extends RunningInstance>>> allInstancesInRegion()
protected com.google.common.base.Function<String,Set<? extends Reservation<? extends RunningInstance>>> instancesByIdInRegion(com.google.common.collect.Multimap<String,String> idsByRegions)
Copyright © 2009-2013 jclouds. All Rights Reserved.