|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.objectweb.proactive.core.process.AbstractUniversalProcess | +--org.objectweb.proactive.core.process.AbstractExternalProcess | +--org.objectweb.proactive.core.process.AbstractExternalProcessDecorator | +--org.objectweb.proactive.core.process.ssh.SSHProcess | +--org.objectweb.proactive.core.process.ssh.SSHJVMProcess
The SSHJVMProcess class is able to start any class, of the ProActive library, using ssh protocol. The difference between this class and SSHProcess class is that the target process for this class is automatically a JVMProcess, whereas for the SSHProcess, the target process has to be defined and can be any command and any process.
For instance:
....... SSHProcess ssh = new SSHJVMProcess(new StandardOutputMessageLogger()); ssh.setHostname("machine_name"); ssh.startProcess(); .....
This piece of code creates a new SSHJVMProcess. It allows to log on a remote machine with the ssh protocol and then, on this machine to create a Java Virtual Machine, by launching a ProActive java class.
Nested Class Summary |
Nested classes inherited from class org.objectweb.proactive.core.process.AbstractExternalProcessDecorator |
AbstractExternalProcessDecorator.CompositeMessageLogger, AbstractExternalProcessDecorator.CompositeMessageSink |
Nested classes inherited from class org.objectweb.proactive.core.process.AbstractExternalProcess |
AbstractExternalProcess.NullMessageLogger, AbstractExternalProcess.ProcessInputHandler, AbstractExternalProcess.ProcessOutputHandler, AbstractExternalProcess.SimpleMessageSink, AbstractExternalProcess.StandardOutputMessageLogger |
Field Summary | |
protected JVMProcessImpl |
jvmProcess
|
Fields inherited from class org.objectweb.proactive.core.process.AbstractExternalProcessDecorator |
targetProcess |
Fields inherited from class org.objectweb.proactive.core.process.AbstractExternalProcess |
clogger, errorMessageLogger, externalProcess, inputMessageLogger, IS_WINDOWS_SYSTEM, outputMessageSink |
Fields inherited from class org.objectweb.proactive.core.process.AbstractUniversalProcess |
certificateLocation, command, DEFAULT_HOSTNAME, DEFAULT_USERNAME, environment, hostname, isFinished, isStarted, LOCALHOST, privateKeyLocation, securityFile, username |
Fields inherited from interface org.objectweb.proactive.core.process.UniversalProcess |
logger |
Fields inherited from interface org.objectweb.proactive.core.process.ExternalProcessDecorator |
APPEND_TO_COMMAND_COMPOSITION, GIVE_COMMAND_AS_PARAMETER, SEND_TO_OUTPUT_STREAM_COMPOSITION |
Constructor Summary | |
SSHJVMProcess()
Creates a new SSHJVMProcess Used with XML Descriptor |
|
SSHJVMProcess(MessageLogger messageLogger)
Creates a new SSHJVMProcess |
|
SSHJVMProcess(MessageLogger inputMessageLogger,
MessageLogger errorMessageLogger)
Creates a new SSHJVMProcess |
Method Summary | |
java.lang.String |
getBootClasspath()
Returns the boot classpath of the target JVMProcess |
java.lang.String |
getClassname()
Returns the class name that the target JVMProcess is about to start |
java.lang.String |
getClasspath()
Returns the classpath associated to the target JVMProcess |
java.lang.String |
getJavaPath()
Returns the java path associated the target JVMProcess |
java.lang.String |
getLog4jFile()
Returns the location of the log4j property file. |
java.lang.String |
getParameters()
Returns parameters associated to the class that the target JVMProcess is going to start |
java.lang.String |
getPolicyFile()
Returns the location (path) to the policy file for the target JVMProcess |
static void |
main(java.lang.String[] args)
|
void |
setBootClasspath(java.lang.String bootClasspath)
Sets the boot classpath for the target JVMProcess |
void |
setClassname(java.lang.String classname)
Sets the value of the class to start for the target JVMProcess |
void |
setClasspath(java.lang.String classpath)
Sets the classpath for the target JVMProcess |
void |
setJavaPath(java.lang.String javaPath)
Sets the java path for the target JVMProcess |
void |
setJvmOptions(java.lang.String parameters)
Sets the parameters of the jvm to start with the given parameters for the target JVMProcess |
void |
setLog4jFile(java.lang.String log4jFile)
Sets the location of the log4j property file. |
void |
setParameters(java.lang.String parameters)
Sets the parameters of the class to start with the given value for the target JVMProcess |
void |
setPolicyFile(java.lang.String policyFile)
Sets the location of the policy file for the target JVMProcess |
Methods inherited from class org.objectweb.proactive.core.process.ssh.SSHProcess |
buildSSHCommand, buildUnixSSHCommand, buildWindowsSSHCommand, internalBuildCommand |
Methods inherited from class org.objectweb.proactive.core.process.AbstractExternalProcessDecorator |
buildCommand, getCompositionType, getTargetProcess, handleOutput, internalStartProcess, setCompositionType, setTargetProcess, toString |
Methods inherited from class org.objectweb.proactive.core.process.AbstractExternalProcess |
buildEnvironmentCommand, buildUnixEnvironmentCommand, buildWindowsEnvironmentCommand, getErrorMessageLogger, getInputMessageLogger, getOutputMessageSink, handleError, handleInput, handleProcess, internalStopProcess, internalWaitFor, setErrorMessageLogger, setInputMessageLogger, setOutputMessageSink |
Methods inherited from class org.objectweb.proactive.core.process.AbstractUniversalProcess |
checkStarted, getCertificateLocation, getCommand, getEnvironment, getHostname, getPrivateKeyLocation, getSecurityFile, getUsername, isFinished, isStarted, setCertificateLocation, setEnvironment, setHostname, setPrivateKeyLocation, setSecurityFile, setUsername, startProcess, stopProcess, toString, waitFor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.objectweb.proactive.core.process.ExternalProcess |
getErrorMessageLogger, getInputMessageLogger, getOutputMessageSink, setErrorMessageLogger, setInputMessageLogger, setOutputMessageSink |
Methods inherited from interface org.objectweb.proactive.core.process.UniversalProcess |
getCertificateLocation, getCommand, getEnvironment, getHostname, getPrivateKeyLocation, getSecurityFile, getUsername, isFinished, isStarted, setCertificateLocation, setEnvironment, setHostname, setPrivateKeyLocation, setSecurityFile, setUsername, startProcess, stopProcess, waitFor |
Field Detail |
protected JVMProcessImpl jvmProcess
Constructor Detail |
public SSHJVMProcess()
public SSHJVMProcess(MessageLogger messageLogger)
messageLogger
- The logger that handles input and error stream of the target JVMProcesspublic SSHJVMProcess(MessageLogger inputMessageLogger, MessageLogger errorMessageLogger)
inputMessageLogger
- The logger that handles input stream of the target JVMProcesserrorMessageLogger
- The logger that handles error stream of the target JVMProcessMethod Detail |
public static void main(java.lang.String[] args)
public java.lang.String getClasspath()
getClasspath
in interface JVMProcess
public void setClasspath(java.lang.String classpath)
setClasspath
in interface JVMProcess
classpath
- The value of the classpath environment variablepublic java.lang.String getBootClasspath()
getBootClasspath
in interface JVMProcess
public void setBootClasspath(java.lang.String bootClasspath)
setBootClasspath
in interface JVMProcess
bootClasspath
- The boot classpath of the java commandpublic java.lang.String getJavaPath()
getJavaPath
in interface JVMProcess
public void setJavaPath(java.lang.String javaPath)
setJavaPath
in interface JVMProcess
javaPath
- The value of the path to execute 'java' commandpublic java.lang.String getPolicyFile()
getPolicyFile
in interface JVMProcess
public void setPolicyFile(java.lang.String policyFile)
setPolicyFile
in interface JVMProcess
policyFile
- The value of the path to the policy filepublic java.lang.String getLog4jFile()
JVMProcess
getLog4jFile
in interface JVMProcess
public void setLog4jFile(java.lang.String log4jFile)
JVMProcess
setLog4jFile
in interface JVMProcess
public java.lang.String getClassname()
getClassname
in interface JVMProcess
public void setClassname(java.lang.String classname)
setClassname
in interface JVMProcess
classname
- The name of the class to startpublic java.lang.String getParameters()
getParameters
in interface JVMProcess
public void setParameters(java.lang.String parameters)
setParameters
in interface JVMProcess
parameters
- Paramaters to be given in order to start the classpublic void setJvmOptions(java.lang.String parameters)
setJvmOptions
in interface JVMProcess
parameters
- Paramaters to be given in order to start the jvm
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |