Brooklyn

brooklyn.management.internal
[Java] Class AbstractManagementContext

java.lang.Object
  brooklyn.management.internal.AbstractManagementContext
All Implemented Interfaces:
ManagementContext

public abstract class AbstractManagementContext

Field Summary
static java.lang.String EFFECTOR_TAG

protected BrooklynProperties configMap

 
Method Summary
void addEntitySetListener(CollectionChangeListener listener)

StringConfigMap getConfig()

EntityDriverFactory getEntityDriverFactory()

ExecutionContext getExecutionContext(Entity e)

SubscriptionContext getSubscriptionContext(Entity e)

long getTotalEffectorInvocations()

Task invokeEffector(Entity entity, Effector eff, java.util.Map parameters)

protected java.lang.Object invokeEffectorMethodLocal(Entity entity, Effector eff, java.lang.Object args)

protected java.lang.Object invokeEffectorMethodSync(Entity entity, Effector eff, java.lang.Object args)

Method for entity to make effector happen with correct semantics (right place, right task context), when a method is called on that entity.

boolean isManaged(Entity e)

boolean isManagedLocally(Entity e)

Whether the master entity record is local, and sensors and effectors can be properly accessed locally.

void manage(Entity e)

Begins management for the given entity and its children, recursively.

protected void manageIfNecessary(Entity entity, java.lang.Object context)

activates management when effector invoked, warning unless context is acceptable (currently only acceptable context is "start")

protected boolean manageNonRecursive(Entity e)

Implementor-supplied internal method.

void removeEntitySetListener(CollectionChangeListener listener)

Task runAtEntity(java.util.Map flags, Entity entity, java.util.concurrent.Callable c)

Causes the indicated runnable to be run at the right location for the given entity.

void unmanage(Entity e)

Causes the given entity and its children, recursively, to be removed from the management plane (for instance because the entity is no longer relevant)

protected boolean unmanageNonRecursive(Entity e)

Implementor-supplied internal method.

 
Methods inherited from class java.lang.Object
java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Field Detail

EFFECTOR_TAG

public static final java.lang.String EFFECTOR_TAG


configMap

protected BrooklynProperties configMap


 
Method Detail

addEntitySetListener

public void addEntitySetListener(CollectionChangeListener listener)


getConfig

@Override
public StringConfigMap getConfig()


getEntityDriverFactory

@Override
public EntityDriverFactory getEntityDriverFactory()


getExecutionContext

public ExecutionContext getExecutionContext(Entity e)


getSubscriptionContext

public SubscriptionContext getSubscriptionContext(Entity e)


getTotalEffectorInvocations

public long getTotalEffectorInvocations()


invokeEffector

public Task invokeEffector(Entity entity, Effector eff, java.util.Map parameters)


invokeEffectorMethodLocal

protected java.lang.Object invokeEffectorMethodLocal(Entity entity, Effector eff, java.lang.Object args)


invokeEffectorMethodSync

protected java.lang.Object invokeEffectorMethodSync(Entity entity, Effector eff, java.lang.Object args)
Method for entity to make effector happen with correct semantics (right place, right task context), when a method is called on that entity.
throws:
ExecutionException


isManaged

public boolean isManaged(Entity e)


isManagedLocally

public boolean isManagedLocally(Entity e)
Whether the master entity record is local, and sensors and effectors can be properly accessed locally.


manage

public void manage(Entity e)
Begins management for the given entity and its children, recursively. depending on the implementation of the management context, this might push it out to one or more remote management nodes.


manageIfNecessary

protected void manageIfNecessary(Entity entity, java.lang.Object context)
activates management when effector invoked, warning unless context is acceptable (currently only acceptable context is "start")


manageNonRecursive

protected boolean manageNonRecursive(Entity e)
Implementor-supplied internal method.

Should ensure that the entity is now managed somewhere, and known about in all the lists. Returns true if the entity has now become managed; false if it was already managed (anything else throws exception)


removeEntitySetListener

public void removeEntitySetListener(CollectionChangeListener listener)


runAtEntity

public Task runAtEntity(java.util.Map flags, Entity entity, java.util.concurrent.Callable c)
Causes the indicated runnable to be run at the right location for the given entity. Returns the actual task (if it is local) or a proxy task (if it is remote); if management for the entity has not yet started this may start it.


unmanage

public void unmanage(Entity e)
Causes the given entity and its children, recursively, to be removed from the management plane (for instance because the entity is no longer relevant)


unmanageNonRecursive

protected boolean unmanageNonRecursive(Entity e)
Implementor-supplied internal method.

Should ensure that the entity is no longer managed anywhere, remove from all lists. Returns true if the entity has been removed from management; if it was not previously managed (anything else throws exception)


 

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