org.objectweb.proactive.core.runtime.rmi
Class RmiProActiveRuntimeImpl
java.lang.Object
java.rmi.server.RemoteObject
java.rmi.server.RemoteServer
java.rmi.server.UnicastRemoteObject
org.objectweb.proactive.core.runtime.rmi.RmiProActiveRuntimeImpl
- All Implemented Interfaces:
- java.rmi.Remote, RemoteProActiveRuntime, RmiProActiveRuntime, java.io.Serializable
- Direct Known Subclasses:
- JiniRuntimeImpl, RmiProActiveRuntimeForwarderImpl, SshRmiProActiveRuntimeImpl
- public class RmiProActiveRuntimeImpl
- extends java.rmi.server.UnicastRemoteObject
- implements RmiProActiveRuntime
An adapter for a ProActiveRuntime to be able to receive remote calls. This helps isolate RMI-specific
code into a small set of specific classes, thus enabling reuse if we one day decide to switch
to anothe remote objects library.
- See Also:
- Adapter Pattern,
Serialized Form
Fields inherited from class java.rmi.server.RemoteObject |
ref |
Method Summary |
void |
addAcquaintance(java.lang.String proActiveRuntimeName)
|
UniversalBody |
createBody(java.lang.String nodeName,
ConstructorCall bodyConstructorCall,
boolean isNodeLocal)
|
java.lang.String |
createLocalNode(java.lang.String nodeName,
boolean replacePreviousBinding,
ProActiveSecurityManager securityManager,
java.lang.String VNname,
java.lang.String jobId)
|
void |
createVM(UniversalProcess remoteProcess)
|
java.lang.String[] |
getAcquaintances()
|
java.util.ArrayList |
getActiveObjects(java.lang.String nodeName)
|
java.util.ArrayList |
getActiveObjects(java.lang.String nodeName,
java.lang.String objectName)
|
java.security.cert.X509Certificate |
getCertificate()
|
byte[] |
getCertificateEncoded()
|
byte[] |
getClassDataFromParentRuntime(java.lang.String className)
|
byte[] |
getClassDataFromThisRuntime(java.lang.String className)
|
ProActiveDescriptor |
getDescriptor(java.lang.String url,
boolean isHierarchicalSearch)
|
java.util.ArrayList |
getEntities()
|
java.lang.String |
getJobID(java.lang.String nodeUrl)
|
java.lang.String[] |
getLocalNodeNames()
|
SecurityContext |
getPolicy(SecurityContext securityContext)
|
ProActiveRuntime |
getProActiveRuntime(java.lang.String proActiveRuntimeName)
|
ProActiveRuntime[] |
getProActiveRuntimes()
|
ExternalProcess |
getProcessToDeploy(ProActiveRuntime proActiveRuntimeDist,
java.lang.String creatorID,
java.lang.String vmName,
java.lang.String padURL)
|
protected java.lang.String |
getProtocol()
|
java.security.PublicKey |
getPublicKey()
|
java.lang.String |
getURL()
|
VirtualNode |
getVirtualNode(java.lang.String virtualNodeName)
|
VMInformation |
getVMInformation()
|
java.lang.String |
getVNName(java.lang.String nodename)
|
void |
killAllNodes()
|
void |
killNode(java.lang.String nodeName)
|
void |
killRT(boolean softly)
|
void |
launchMain(java.lang.String className,
java.lang.String[] parameters)
|
void |
newRemote(java.lang.String className)
|
byte[][] |
publicKeyExchange(long sessionID,
byte[] myPublicKey,
byte[] myCertificate,
byte[] signature)
|
byte[] |
randomValue(long sessionID,
byte[] clientRandomValue)
|
UniversalBody |
receiveBody(java.lang.String nodeName,
Body body)
|
UniversalBody |
receiveCheckpoint(java.lang.String nodeURL,
Checkpoint ckpt,
int inc)
|
void |
register(ProActiveRuntime proActiveRuntimeDist,
java.lang.String proActiveRuntimeName,
java.lang.String creatorID,
java.lang.String creationProtocol,
java.lang.String vmName)
|
void |
registerVirtualNode(java.lang.String virtualNodeName,
boolean replacePreviousBinding)
|
void |
rmAcquaintance(java.lang.String proActiveRuntimeName)
|
byte[][] |
secretKeyExchange(long sessionID,
byte[] encodedAESKey,
byte[] encodedIVParameters,
byte[] encodedClientMacKey,
byte[] encodedLockData,
byte[] parametersSignature)
|
long |
startNewSession(Communication policy)
|
void |
terminateSession(long sessionID)
|
void |
unregister(ProActiveRuntime proActiveRuntimeDist,
java.lang.String proActiveRuntimeName,
java.lang.String creatorID,
java.lang.String creationProtocol,
java.lang.String vmName)
|
void |
unregisterAllVirtualNodes()
|
void |
unregisterVirtualNode(java.lang.String virtualnodeName)
|
Methods inherited from class java.rmi.server.UnicastRemoteObject |
clone, exportObject, exportObject, exportObject, unexportObject |
Methods inherited from class java.rmi.server.RemoteServer |
getClientHost, getLog, setLog |
Methods inherited from class java.rmi.server.RemoteObject |
equals, getRef, hashCode, toString, toStub |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
proActiveRuntime
protected transient ProActiveRuntime proActiveRuntime
proActiveRuntimeURL
protected java.lang.String proActiveRuntimeURL
RmiProActiveRuntimeImpl
public RmiProActiveRuntimeImpl()
throws java.rmi.RemoteException,
java.rmi.AlreadyBoundException
RmiProActiveRuntimeImpl
public RmiProActiveRuntimeImpl(java.rmi.server.RMIClientSocketFactory csf,
java.rmi.server.RMIServerSocketFactory ssf)
throws java.rmi.RemoteException,
java.rmi.AlreadyBoundException
RmiProActiveRuntimeImpl
public RmiProActiveRuntimeImpl(boolean isJini)
throws java.rmi.RemoteException
getProcessToDeploy
public ExternalProcess getProcessToDeploy(ProActiveRuntime proActiveRuntimeDist,
java.lang.String creatorID,
java.lang.String vmName,
java.lang.String padURL)
throws ProActiveException,
java.io.IOException
- Specified by:
getProcessToDeploy
in interface RemoteProActiveRuntime
- Throws:
ProActiveException
java.io.IOException
createLocalNode
public java.lang.String createLocalNode(java.lang.String nodeName,
boolean replacePreviousBinding,
ProActiveSecurityManager securityManager,
java.lang.String VNname,
java.lang.String jobId)
throws NodeException,
java.rmi.RemoteException
- Specified by:
createLocalNode
in interface RemoteProActiveRuntime
- Throws:
NodeException
java.rmi.RemoteException
killAllNodes
public void killAllNodes()
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
killAllNodes
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
killNode
public void killNode(java.lang.String nodeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
killNode
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
createVM
public void createVM(UniversalProcess remoteProcess)
throws java.io.IOException,
ProActiveException
- Specified by:
createVM
in interface RemoteProActiveRuntime
- Throws:
java.io.IOException
ProActiveException
getLocalNodeNames
public java.lang.String[] getLocalNodeNames()
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getLocalNodeNames
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getVMInformation
public VMInformation getVMInformation()
- Specified by:
getVMInformation
in interface RemoteProActiveRuntime
register
public void register(ProActiveRuntime proActiveRuntimeDist,
java.lang.String proActiveRuntimeName,
java.lang.String creatorID,
java.lang.String creationProtocol,
java.lang.String vmName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
register
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
unregister
public void unregister(ProActiveRuntime proActiveRuntimeDist,
java.lang.String proActiveRuntimeName,
java.lang.String creatorID,
java.lang.String creationProtocol,
java.lang.String vmName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
unregister
in interface RemoteProActiveRuntime
- Throws:
ProActiveException
java.rmi.RemoteException
- See Also:
RemoteProActiveRuntime.unregister(org.objectweb.proactive.core.runtime.ProActiveRuntime, java.lang.String, java.lang.String, java.lang.String, java.lang.String)
getProActiveRuntimes
public ProActiveRuntime[] getProActiveRuntimes()
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getProActiveRuntimes
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getProActiveRuntime
public ProActiveRuntime getProActiveRuntime(java.lang.String proActiveRuntimeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getProActiveRuntime
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
addAcquaintance
public void addAcquaintance(java.lang.String proActiveRuntimeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
addAcquaintance
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getAcquaintances
public java.lang.String[] getAcquaintances()
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getAcquaintances
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
rmAcquaintance
public void rmAcquaintance(java.lang.String proActiveRuntimeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
rmAcquaintance
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
killRT
public void killRT(boolean softly)
throws java.lang.Exception
- Specified by:
killRT
in interface RemoteProActiveRuntime
- Throws:
java.lang.Exception
getURL
public java.lang.String getURL()
- Specified by:
getURL
in interface RemoteProActiveRuntime
getActiveObjects
public java.util.ArrayList getActiveObjects(java.lang.String nodeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getActiveObjects
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getActiveObjects
public java.util.ArrayList getActiveObjects(java.lang.String nodeName,
java.lang.String objectName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getActiveObjects
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getVirtualNode
public VirtualNode getVirtualNode(java.lang.String virtualNodeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getVirtualNode
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
registerVirtualNode
public void registerVirtualNode(java.lang.String virtualNodeName,
boolean replacePreviousBinding)
throws java.rmi.RemoteException
- Specified by:
registerVirtualNode
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
unregisterVirtualNode
public void unregisterVirtualNode(java.lang.String virtualnodeName)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
unregisterVirtualNode
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
unregisterAllVirtualNodes
public void unregisterAllVirtualNodes()
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
unregisterAllVirtualNodes
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
createBody
public UniversalBody createBody(java.lang.String nodeName,
ConstructorCall bodyConstructorCall,
boolean isNodeLocal)
throws java.rmi.RemoteException,
ConstructorCallExecutionFailedException,
ProActiveException,
java.lang.reflect.InvocationTargetException
- Specified by:
createBody
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ConstructorCallExecutionFailedException
ProActiveException
java.lang.reflect.InvocationTargetException
receiveBody
public UniversalBody receiveBody(java.lang.String nodeName,
Body body)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
receiveBody
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
receiveCheckpoint
public UniversalBody receiveCheckpoint(java.lang.String nodeURL,
Checkpoint ckpt,
int inc)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
receiveCheckpoint
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getJobID
public java.lang.String getJobID(java.lang.String nodeUrl)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getJobID
in interface RemoteProActiveRuntime
- Throws:
ProActiveException
java.rmi.RemoteException
- See Also:
RemoteProActiveRuntime.getJobID(java.lang.String)
getClassDataFromParentRuntime
public byte[] getClassDataFromParentRuntime(java.lang.String className)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getClassDataFromParentRuntime
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
- See Also:
ProActiveRuntime.getClassDataFromParentRuntime(String)
getClassDataFromThisRuntime
public byte[] getClassDataFromThisRuntime(java.lang.String className)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getClassDataFromThisRuntime
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
- See Also:
ProActiveRuntime.getClassDataFromThisRuntime(String)
launchMain
public void launchMain(java.lang.String className,
java.lang.String[] parameters)
throws java.io.IOException,
java.lang.ClassNotFoundException,
java.lang.NoSuchMethodException,
ProActiveException
- Specified by:
launchMain
in interface RemoteProActiveRuntime
- Throws:
java.io.IOException
java.lang.ClassNotFoundException
java.lang.NoSuchMethodException
ProActiveException
newRemote
public void newRemote(java.lang.String className)
throws java.io.IOException,
java.lang.ClassNotFoundException,
ProActiveException
- Specified by:
newRemote
in interface RemoteProActiveRuntime
- Throws:
java.io.IOException
java.lang.ClassNotFoundException
ProActiveException
getDescriptor
public ProActiveDescriptor getDescriptor(java.lang.String url,
boolean isHierarchicalSearch)
throws java.io.IOException,
ProActiveException
- Specified by:
getDescriptor
in interface RemoteProActiveRuntime
- Throws:
java.io.IOException
ProActiveException
getProtocol
protected java.lang.String getProtocol()
getVNName
public java.lang.String getVNName(java.lang.String nodename)
throws java.rmi.RemoteException,
ProActiveException
- Specified by:
getVNName
in interface RemoteProActiveRuntime
- Throws:
java.rmi.RemoteException
ProActiveException
getCertificate
public java.security.cert.X509Certificate getCertificate()
throws SecurityNotAvailableException,
java.io.IOException
- Specified by:
getCertificate
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
java.io.IOException
startNewSession
public long startNewSession(Communication policy)
throws SecurityNotAvailableException,
RenegotiateSessionException,
java.io.IOException
- Specified by:
startNewSession
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
RenegotiateSessionException
java.io.IOException
getPublicKey
public java.security.PublicKey getPublicKey()
throws SecurityNotAvailableException,
java.io.IOException
- Specified by:
getPublicKey
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
java.io.IOException
randomValue
public byte[] randomValue(long sessionID,
byte[] clientRandomValue)
throws SecurityNotAvailableException,
RenegotiateSessionException,
java.io.IOException
- Specified by:
randomValue
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
RenegotiateSessionException
java.io.IOException
publicKeyExchange
public byte[][] publicKeyExchange(long sessionID,
byte[] myPublicKey,
byte[] myCertificate,
byte[] signature)
throws SecurityNotAvailableException,
RenegotiateSessionException,
KeyExchangeException,
java.io.IOException
- Specified by:
publicKeyExchange
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
RenegotiateSessionException
KeyExchangeException
java.io.IOException
secretKeyExchange
public byte[][] secretKeyExchange(long sessionID,
byte[] encodedAESKey,
byte[] encodedIVParameters,
byte[] encodedClientMacKey,
byte[] encodedLockData,
byte[] parametersSignature)
throws SecurityNotAvailableException,
RenegotiateSessionException,
java.io.IOException
- Specified by:
secretKeyExchange
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
RenegotiateSessionException
java.io.IOException
getPolicy
public SecurityContext getPolicy(SecurityContext securityContext)
throws SecurityNotAvailableException,
java.io.IOException
- Specified by:
getPolicy
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
java.io.IOException
getCertificateEncoded
public byte[] getCertificateEncoded()
throws SecurityNotAvailableException,
java.io.IOException
- Specified by:
getCertificateEncoded
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
java.io.IOException
getEntities
public java.util.ArrayList getEntities()
throws SecurityNotAvailableException,
java.io.IOException
- Specified by:
getEntities
in interface RemoteProActiveRuntime
- Throws:
SecurityNotAvailableException
java.io.IOException
terminateSession
public void terminateSession(long sessionID)
throws java.io.IOException,
SecurityNotAvailableException
- Specified by:
terminateSession
in interface RemoteProActiveRuntime
- Throws:
java.io.IOException
SecurityNotAvailableException
Copyright 2001-2005 INRIA All Rights Reserved.