Classes | Static Public Member Functions | Static Public Attributes | Static Protected Attributes

alma.acs.commandcenter.engine.Executor Class Reference

List of all members.

Classes

class  LocalInProcFlow
class  LocalInProcStream
class  LocalOutProcFlow
class  RemoteContainerDaemonFlow
class  RemoteFlow
class  RemoteServicesDaemonFlow
interface  RunMain
class  SearchBuffer
class  SingleStepFlow

Static Public Member Functions

static boolean remote (boolean nativeSSH, String username, String password, String command, String endMark, NativeCommand.Listener listener, String host) throws Throwable
static void remoteDownAll ()
static void localInProc (Properties properties, String pexpect, NativeCommand.Listener listener, final RunMain runMain)
static void local (final RunMain runMain)
static void localOutProc (String command, boolean foreground, long maxExecutionTime, String endMark, NativeCommand.Listener listener) throws Throwable
static void remoteDaemonEnable (Firestarter fs)
static Exception remoteDaemonForServices (String host, int instance, boolean startStop, String cmdFlags, NativeCommand.Listener listener)
static Exception remoteDaemonForContainers (String host, int instance, boolean startStop, String contName, String contType, String[] contTypeMods, String cmdFlags, NativeCommand.Listener listener)

Static Public Attributes

static boolean disableRemote = false
static final String SYSPROP_COMMAND_NATIVE_SSH = "AcsCommandCenter.commandNativeSSH"
static RemoteFlow remoteFlow = new RemoteFlow()
static LocalInProcFlow localInProcFlow = new LocalInProcFlow()
static LocalOutProcFlow localOutProcFlow = new LocalOutProcFlow()
static SingleStepFlow singleStepFlow = new SingleStepFlow()
static RemoteServicesDaemonFlow remoteServicesDaemonFlow = new RemoteServicesDaemonFlow()
static RemoteContainerDaemonFlow remoteContainerDaemonFlow = new RemoteContainerDaemonFlow()
static int remoteDaemonForContainersCompletionDelay = 2500

Static Protected Attributes

static Vector< Connection > connections = new Vector<Connection>()
static Vector< Session > sessions = new Vector<Session>()

Detailed Description

Author:
mschilli

Member Function Documentation

static void alma.acs.commandcenter.engine.Executor.local ( final RunMain  runMain  )  [static]

The only sense of this is to have a flow for normal java instructions that may take a while.

Parameters:
runMain the java instructions to perform

References alma.acs.commandcenter.engine.Executor.singleStepFlow.

static void alma.acs.commandcenter.engine.Executor.localInProc ( Properties  properties,
String  pexpect,
NativeCommand.Listener  listener,
final RunMain  runMain 
) [static]
Parameters:
properties the properties to insert (and override) into the system properties
pexpect as soon as the process writes this to stdout, this method returns
listener a proprietary listener if the caller wants to hear about the process' output
runMain a callback that will be invoked by the newly spawned thread

References alma.acs.commandcenter.engine.Executor.localInProcFlow.

static void alma.acs.commandcenter.engine.Executor.localOutProc ( String  command,
boolean  foreground,
long  maxExecutionTime,
String  endMark,
NativeCommand.Listener  listener 
) throws Throwable [static]
static boolean alma.acs.commandcenter.engine.Executor.remote ( boolean  nativeSSH,
String  username,
String  password,
String  command,
String  endMark,
NativeCommand.Listener  listener,
String  host 
) throws Throwable [static]
Returns:
false - if this failed gracefully
Exceptions:
IOException - if this failed severely
static void alma.acs.commandcenter.engine.Executor.remoteDaemonEnable ( Firestarter  fs  )  [static]
static Exception alma.acs.commandcenter.engine.Executor.remoteDaemonForContainers ( String  host,
int  instance,
boolean  startStop,
String  contName,
String  contType,
String[]  contTypeMods,
String  cmdFlags,
NativeCommand.Listener  listener 
) [static]
Parameters:
startStop - if true, the daemon starts the container, otherwise stops it.
Todo:
rethink how useful this overloading is.
Parameters:
contType - only needed for starting (i.e. startStop==true)
contTypeMods - only needed for starting (i.e. startStop==true)
See also:
http://www.eso.org/projects/alma/develop/acs/OnlineDocs/ACS_docs/schemas/urn_schemas-cosylab-com_Container_1.0/complexType/DeployInfo.html

References alma.acs.commandcenter.engine.Executor.remoteContainerDaemonFlow, and alma.acs.commandcenter.engine.Executor.remoteDaemonForContainersCompletionDelay.

static Exception alma.acs.commandcenter.engine.Executor.remoteDaemonForServices ( String  host,
int  instance,
boolean  startStop,
String  cmdFlags,
NativeCommand.Listener  listener 
) [static]

Starts or stops ACS via the ACS services daemon. This call returns only when the action has completed. Exceptions will be returned instead of thrown.

Returns:
any exception that occurs underways

References alma.acs.container.corba.AcsCorba.activateOffShoot(), alma.acs.exceptions.AcsJCompletion.getAcsJException(), alma.acs.container.corba.AcsCorba.getORB(), alma.acs.container.corba.AcsCorba.getRootPOA(), alma.acs.exceptions.AcsJCompletion.isError(), and alma.acs.commandcenter.engine.Executor.remoteServicesDaemonFlow.

static void alma.acs.commandcenter.engine.Executor.remoteDownAll (  )  [static]

Member Data Documentation

Vector<Connection> alma.acs.commandcenter.engine.Executor.connections = new Vector<Connection>() [static, protected]
LocalInProcFlow alma.acs.commandcenter.engine.Executor.localInProcFlow = new LocalInProcFlow() [static]
LocalOutProcFlow alma.acs.commandcenter.engine.Executor.localOutProcFlow = new LocalOutProcFlow() [static]
RemoteContainerDaemonFlow alma.acs.commandcenter.engine.Executor.remoteContainerDaemonFlow = new RemoteContainerDaemonFlow() [static]
RemoteFlow alma.acs.commandcenter.engine.Executor.remoteFlow = new RemoteFlow() [static]
RemoteServicesDaemonFlow alma.acs.commandcenter.engine.Executor.remoteServicesDaemonFlow = new RemoteServicesDaemonFlow() [static]
Vector<Session> alma.acs.commandcenter.engine.Executor.sessions = new Vector<Session>() [static, protected]
SingleStepFlow alma.acs.commandcenter.engine.Executor.singleStepFlow = new SingleStepFlow() [static]
final String alma.acs.commandcenter.engine.Executor.SYSPROP_COMMAND_NATIVE_SSH = "AcsCommandCenter.commandNativeSSH" [static]

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Enumerations Properties