Package org.jppf.node.provisioning
Class SlaveNodeManager
java.lang.Object
org.jppf.node.provisioning.SlaveNodeManager
- All Implemented Interfaces:
EventListener,org.jppf.process.ProcessLauncherListener
public final class SlaveNodeManager
extends Object
implements org.jppf.process.ProcessLauncherListener
This class manages the slave nodes.
- Since:
- 4.1
- Author:
- Laurent Cohen
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAutomatically start slaves if specified in the configuration.intnbSlaves()Get the number of running slave nodes.voidprocessStarted(org.jppf.process.ProcessLauncherEvent event) voidprocessStopped(org.jppf.process.ProcessLauncherEvent event) voidStop all the slave nodes still running.
-
Constructor Details
-
SlaveNodeManager
public SlaveNodeManager(org.jppf.node.Node node) Initialize this manager.- Parameters:
node- the JPPF node that holds this manager.
-
-
Method Details
-
stopAllSlaves
public void stopAllSlaves()Stop all the slave nodes still running. -
nbSlaves
public int nbSlaves()Get the number of running slave nodes.- Returns:
- the number of slaves as an int.
-
processStarted
public void processStarted(org.jppf.process.ProcessLauncherEvent event) - Specified by:
processStartedin interfaceorg.jppf.process.ProcessLauncherListener
-
processStopped
public void processStopped(org.jppf.process.ProcessLauncherEvent event) - Specified by:
processStoppedin interfaceorg.jppf.process.ProcessLauncherListener
-
handleStartup
public void handleStartup()Automatically start slaves if specified in the configuration.
-