Brooklyn

brooklyn.location.basic.jclouds
[Java] Class BrooklynMachinePool

java.lang.Object
  brooklyn.location.basic.jclouds.pool.MachinePool
      brooklyn.location.basic.jclouds.BrooklynMachinePool

public class BrooklynMachinePool
extends MachinePool

Field Summary
protected JcloudsLocation location

 
Fields inherited from class MachinePool
computeService
 
Constructor Summary
BrooklynMachinePool(JcloudsLocation l)

 
Method Summary
protected Task addTask(Task t)

void blockUntilTasksEnded()

MachineSet create(int count, ReusableMachineTemplate template)

boolean destroy(SshMachineLocation location)

protected MachineSet filterForAllowedMachines(MachineSet input)

java.util.List getActiveTasks()

SshMachineLocation obtain(ReusableMachineTemplate t)

claims a machine with the indicated spec, creating if necessary

Task start(ReusableMachineTemplate template, java.util.List entities)

starts the given template; for use only within a task (e.g. application's start effector).

Task start(ReusableMachineTemplate template, Startable... entities)

@see #start(ReusableMachineTemplate, List)

protected SshMachineLocation toSshMachineLocation(NodeMetadata m)

returns an SshMachineLocation, if one can be created and accessed; returns null if it cannot be created

boolean unclaim(SshMachineLocation location)

 
Methods inherited from class MachinePool
addToBlacklist, all, all, all, claim, claim, create, destroy, ensureExists, ensureExists, ensureUnclaimed, ensureUnclaimed, filterForAllowedMachines, getPoolName, getTemplates, getTemplatesMatchingInstance, init, newTemplate, refresh, registerNewNodes, registerTemplate, registerTemplates, setBlacklist, setPoolName, unclaim, unclaimed, unclaimed, unclaimed
 

Field Detail

location

protected final JcloudsLocation location


 
Constructor Detail

BrooklynMachinePool

public BrooklynMachinePool(JcloudsLocation l)


 
Method Detail

addTask

protected Task addTask(Task t)


blockUntilTasksEnded

public void blockUntilTasksEnded()


create

@Override
public MachineSet create(int count, ReusableMachineTemplate template)


destroy

public boolean destroy(SshMachineLocation location)


filterForAllowedMachines

protected MachineSet filterForAllowedMachines(MachineSet input)


getActiveTasks

public java.util.List getActiveTasks()


obtain

public SshMachineLocation obtain(ReusableMachineTemplate t)
claims a machine with the indicated spec, creating if necessary


start

public Task start(ReusableMachineTemplate template, java.util.List entities)
starts the given template; for use only within a task (e.g. application's start effector). returns a child task of the current task.

throws exception if not in a task. (you will have to claim, then invoke the effectors manually.)


start

public Task start(ReusableMachineTemplate template, Startable... entities)
See Also:
start(ReusableMachineTemplate, List)


toSshMachineLocation

protected SshMachineLocation toSshMachineLocation(NodeMetadata m)
returns an SshMachineLocation, if one can be created and accessed; returns null if it cannot be created


unclaim

public boolean unclaim(SshMachineLocation location)


 

Brooklyn Multi-Cloud Application Management Platform
brooklyncentral.github.com. Apache License. © 2012.