Package hudson.slaves
Class NodeProvisioner.PlannedNode
- java.lang.Object
-
- hudson.slaves.NodeProvisioner.PlannedNode
-
- Enclosing class:
- NodeProvisioner
public static class NodeProvisioner.PlannedNode extends Object
The node addition activity in progress.
-
-
Field Summary
Fields Modifier and Type Field Description String
displayName
Used to display this planned node to UI.Future<Node>
future
Used to launch and return aNode
object.int
numExecutors
The number of executors that will be provided by theNode
launched by this object.
-
Constructor Summary
Constructors Constructor Description PlannedNode(String displayName, Future<Node> future, int numExecutors)
Construct a PlannedNode instance withoutCloud
callback for finalization.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
spent()
Indicate that thisNodeProvisioner.PlannedNode
is being finalized.
-
-
-
Field Detail
-
displayName
public final String displayName
Used to display this planned node to UI. Should ideally include the identifier unique to the node being provisioned (like the instance ID), but if such an identifier doesn't readily exist, this can be just a name of the template being provisioned (like the machine image ID.)
-
future
public final Future<Node> future
Used to launch and return aNode
object.NodeProvisioner
will check thisFuture
's isDone() method to determine when to finalize this object.
-
numExecutors
public final int numExecutors
The number of executors that will be provided by theNode
launched by this object. This is used for capacity planning inNodeProvisioner.update()
.
-
-
Constructor Detail
-
PlannedNode
public PlannedNode(String displayName, Future<Node> future, int numExecutors)
Construct a PlannedNode instance withoutCloud
callback for finalization.- Parameters:
displayName
- Used to display this object in the UI.future
- Used to launch a @{link Node} object.numExecutors
- The number of executors that will be provided by the launchedNode
.
-
-
Method Detail
-
spent
public void spent()
Indicate that thisNodeProvisioner.PlannedNode
is being finalized.NodeProvisioner
will call this method when it's done withNodeProvisioner.PlannedNode
. This indicates that theNodeProvisioner.PlannedNode
's work has been completed (successfully or otherwise) and it is about to be removed from the list of pendingNode
s to be launched.Create a subtype of this class and override this method to add any necessary behaviour.
- Since:
- 1.503
-
-