Package org.jclouds.compute.functions
Class PollNodeRunning
java.lang.Object
org.jclouds.compute.functions.PollNodeRunning
- All Implemented Interfaces:
com.google.common.base.Function<AtomicReference<NodeMetadata>,
,AtomicReference<NodeMetadata>> Function<AtomicReference<NodeMetadata>,
AtomicReference<NodeMetadata>>
@Named("jclouds.compute.timeout.node-running")
public class PollNodeRunning
extends Object
implements com.google.common.base.Function<AtomicReference<NodeMetadata>,AtomicReference<NodeMetadata>>
Polls until the node is running or throws
IllegalStateException
if
this cannot be achieved within the timeout.-
Constructor Summary
ConstructorsConstructorDescriptionPollNodeRunning
(com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeRunning) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.google.common.base.Function
equals
-
Constructor Details
-
PollNodeRunning
@Inject public PollNodeRunning(@Named("jclouds.compute.timeout.node-running") com.google.common.base.Predicate<AtomicReference<NodeMetadata>> nodeRunning)
-
-
Method Details
-
apply
public AtomicReference<NodeMetadata> apply(AtomicReference<NodeMetadata> node) throws IllegalStateException - Specified by:
apply
in interfacecom.google.common.base.Function<AtomicReference<NodeMetadata>,
AtomicReference<NodeMetadata>> - Specified by:
apply
in interfaceFunction<AtomicReference<NodeMetadata>,
AtomicReference<NodeMetadata>> - Parameters:
node
- will be updated with the node which is running- Throws:
IllegalStateException
-