|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.Observable
org.ow2.clif.deploy.ClifAppFacade
public class ClifAppFacade
This class is responsible for creating the initial Clif application. Then, it provides test plan deployment.
Field Summary | |
---|---|
protected org.objectweb.fractal.api.Component |
clifApp
|
protected org.objectweb.fractal.api.control.ContentController |
clifAppCc
|
protected java.lang.String |
clifAppDefinition
|
protected org.objectweb.fractal.api.control.LifeCycleController |
clifAppLfc
|
protected java.lang.String |
clifAppName
|
protected java.util.Map<java.lang.String,org.objectweb.fractal.api.Component> |
components
clif application static components indexed by their name (storage, supervisor, analyser) |
protected java.lang.String |
currentTestId
|
protected org.objectweb.fractal.api.Component |
storage
|
protected org.objectweb.fractal.api.control.BindingController |
storageBc
|
protected org.objectweb.fractal.api.Component |
supervisor
|
protected org.objectweb.fractal.api.control.BindingController |
supervisorBc
|
Constructor Summary | |
---|---|
ClifAppFacade(org.objectweb.fractal.api.Component clifApp,
java.lang.String name)
Constructor for ClifAppFacade. |
|
ClifAppFacade(java.lang.String testName,
java.lang.String appDefinition)
Create new ClifAppFacade with all components of a ClifApplication : supervisor, storage... |
Method Summary | |
---|---|
void |
changeParameter(java.lang.String bladeId,
java.lang.String name,
java.lang.String text)
|
int |
collect(java.lang.String[] selBladesId,
CollectListener listener)
Collect selected blades if global state is completed or stopped |
void |
deploy(java.util.Map definitions,
ClifRegistry registry)
Asynchronously deploys blades according to the given definitions, deploying Clif servers when necessary (i.e. when not already deployed in a previous test plan), and creates a Supervisor component to control the new test plan. |
org.objectweb.fractal.api.Component |
getClifApp()
Get clifApp component |
org.objectweb.fractal.api.Component |
getComponentByName(java.lang.String name)
Get a component of the clifApplication by his Fractal name |
java.util.Map |
getCurrentParameters(java.lang.String id)
|
java.lang.String |
getCurrentTestId()
Retrieve the currentTestId. |
BladeState |
getGlobalState(java.lang.String[] selBladesId)
Get global state for these blades. |
BladeState |
getState(java.lang.String id)
Get the state of a blade |
java.lang.String[] |
getStatLabels(java.lang.String bladeId)
Retrieve the ActionStat of a specific host. |
long[] |
getStats(java.lang.String bladeId)
Retrieve the ActionStat of a specific host. |
void |
init(java.lang.String testId)
Init selected blades if global state is deployed |
int |
join(java.lang.String[] selBladesId)
Join selected blades if global state is running |
void |
restart()
|
int |
resume(java.lang.String[] selBladesId)
Resume selected blades if global state is suspended |
int |
start(java.lang.String[] selBladesId)
Start selected blades if global state is initialized |
int |
stop(java.lang.String[] selBladesId)
Stop selected blades if global state is stationary |
int |
suspend(java.lang.String[] selBladesId)
Suspend selected blades if global state is running |
void |
syncDeploy(java.util.Map definitions,
ClifRegistry registry)
Synchronous version of deploy method (returns when deployment is complete). |
void |
update(java.util.Observable supervisor,
java.lang.Object observation)
|
int |
waitForState(java.lang.String[] selBladesId,
BladeState state)
Waits until this state is reached |
Methods inherited from class java.util.Observable |
---|
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.lang.String clifAppDefinition
protected java.lang.String clifAppName
protected java.lang.String currentTestId
protected org.objectweb.fractal.api.Component clifApp
protected org.objectweb.fractal.api.Component storage
protected org.objectweb.fractal.api.Component supervisor
protected java.util.Map<java.lang.String,org.objectweb.fractal.api.Component> components
protected org.objectweb.fractal.api.control.BindingController storageBc
protected org.objectweb.fractal.api.control.BindingController supervisorBc
protected org.objectweb.fractal.api.control.LifeCycleController clifAppLfc
protected org.objectweb.fractal.api.control.ContentController clifAppCc
Constructor Detail |
---|
public ClifAppFacade(java.lang.String testName, java.lang.String appDefinition)
testName
- the name in the Registry to be associated with the
resulting Clif Application.appDefinition
- fully-qualified Fractal ADL definition file of the
CLIF application to instantiate.
java.lang.Error
public ClifAppFacade(org.objectweb.fractal.api.Component clifApp, java.lang.String name)
clifApp
- the existing Clif application componentMethod Detail |
---|
public void restart()
public org.objectweb.fractal.api.Component getComponentByName(java.lang.String name)
name
- the name of the component to find
public org.objectweb.fractal.api.Component getClifApp()
public void deploy(java.util.Map definitions, ClifRegistry registry) throws ClifException
definitions
- a Map containing test plan definitions, indexed by a String blade identifierregistry
-
ClifException
DeployDefinition
,
DeployObservation
,
ClifException
public void syncDeploy(java.util.Map definitions, ClifRegistry registry) throws ClifException
definitions
- a Map containing test plan definitions, indexed by a String blade identifierregistry
-
ClifException
deploy(Map, ClifRegistry)
,
DeployDefinition
,
DeployObservation
,
ClifException
public void init(java.lang.String testId) throws ClifException
testId
- selected blades ids
ClifException
public int start(java.lang.String[] selBladesId)
selBladesId
- selected blades ids
public int stop(java.lang.String[] selBladesId)
selBladesId
- selected blades ids
public int suspend(java.lang.String[] selBladesId)
selBladesId
- selected blades ids
public int resume(java.lang.String[] selBladesId)
selBladesId
- selected blades ids
public int join(java.lang.String[] selBladesId)
selBladesId
- selected blades ids
public int collect(java.lang.String[] selBladesId, CollectListener listener)
selBladesId
- selected blades ids
public BladeState getGlobalState(java.lang.String[] selBladesId)
selBladesId
- the blades ids
public BladeState getState(java.lang.String id)
id
- the bladeId tested
public int waitForState(java.lang.String[] selBladesId, BladeState state)
selBladesId
- state
-
public long[] getStats(java.lang.String bladeId)
bladeId
- The blade identifier to get the statistical data from
public java.lang.String[] getStatLabels(java.lang.String bladeId)
bladeId
- The blade identifier to get the statistics labels from
public java.util.Map getCurrentParameters(java.lang.String id)
public java.lang.String getCurrentTestId()
public void changeParameter(java.lang.String bladeId, java.lang.String name, java.lang.String text) throws ClifException
ClifException
public void update(java.util.Observable supervisor, java.lang.Object observation)
update
in interface java.util.Observer
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |