|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.objectweb.proactive.core.descriptor.data.RuntimeDeploymentProperties | +--org.objectweb.proactive.core.descriptor.data.VirtualNodeLookup
A VirtualNode
represents a conceptual entity. After activation
a VirtualNode
represents one or several nodes.
This class represents a remote VirtualNode resulting from a lookup in some registry such as RMIRegistry
or JINI Lookup service.
Objects of this class will be created when in an XML descriptor a VirtualNode is declared
in the virtualNodesAcquisition tag and defined with
lookup virtualNode="Dispatcher" host="hostname" protocol="rmi or jini"
Field Summary | |
protected java.lang.String |
runtimeHostForLookup
|
Fields inherited from class org.objectweb.proactive.core.descriptor.data.RuntimeDeploymentProperties |
runtimeProperties |
Fields inherited from interface org.objectweb.proactive.core.descriptor.data.VirtualNode |
logger |
Constructor Summary | |
VirtualNodeLookup(java.lang.String name)
|
Method Summary | |
void |
activate()
Activates all the Nodes mapped to this VirtualNode in the XML Descriptor |
void |
addVirtualMachine(VirtualMachine virtualMachine)
Adds a VirtualMachine entity to this VirtualNode |
int |
createdNodeCount()
Returns the number of Nodes already created among the Nodes mapped to this VirtualNode in the XML Descriptor |
void |
createNodeOnCurrentJvm(java.lang.String protocol)
Creates a node with the given protocol on the current jvm, ie the jvm that originates the creation of this VirtualNode. |
java.security.cert.X509Certificate |
getCreatorCertificate()
// * @return creator certificate |
java.lang.String |
getJobID()
|
java.lang.String |
getName()
Returns the name of this VirtualNode |
Node |
getNode()
Returns the first Node created among Nodes mapped to this VirtualNode in the XML Descriptor Another call to this method will return the following created node if any. |
Node |
getNode(int index)
Returns the Node mapped to this VirtualNode with the specified index. |
Node |
getNode(java.lang.String url)
Returns the node of the given url among nodes mapped to this VirtualNode in the xml descriptor or null if such node does not exist. |
int |
getNodeCount()
Returns the number of Nodes mapped to this VirtualNode in the XML Descriptor |
Node[] |
getNodes()
Returns all nodes mapped to this VirtualNode |
java.lang.String[] |
getNodesURL()
Returns all nodes url mapped to this VirualNode |
PolicyServer |
getPolicyServer()
|
java.lang.String |
getProperty()
Returns the value of property attribute. |
java.lang.Object |
getUniqueAO()
Returns the unique active object created on the unique node mapped to this VirtualNode. |
VirtualMachine |
getVirtualMachine()
Returns the virtualMachine entity linked to this VirtualNode or if cyclic, returns one of the VirtualMachines linked to this VirtualNode with a cyclic manner(internal count incremented each time this method is called). |
boolean |
isActivated()
Returns true is this VirtualNode is already activated, false otherwise |
void |
killAll(boolean softly)
Kills all nodes mapped to this VirtualNode. |
void |
setLookupInformations(java.lang.String url,
java.lang.String protocol,
int port)
|
void |
setName(java.lang.String s)
Sets the name of this VirtualNode |
void |
setPolicyFile(java.lang.String file)
|
void |
setPolicyServer(PolicyServer ps)
|
void |
setProperty(java.lang.String property)
Sets the property attribute to the given value |
void |
setRuntimeInformations(java.lang.String information,
java.lang.String value)
Allows to set runtime informations for this VirtualNode activation. |
void |
setTimeout(java.lang.String timeout,
boolean waitForTimeout)
Sets the timeout variable to the given value. |
Methods inherited from class org.objectweb.proactive.core.descriptor.data.RuntimeDeploymentProperties |
checkProperty |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.lang.String runtimeHostForLookup
Constructor Detail |
public VirtualNodeLookup(java.lang.String name)
Method Detail |
public void setProperty(java.lang.String property)
VirtualNode
setProperty
in interface VirtualNode
property
- the value of property attribute, this value can be "unique", "unique_singleAO", "multiple", "multiple_cyclic" or nothingVirtualNode.setProperty(String)
public java.lang.String getProperty()
VirtualNode
getProperty
in interface VirtualNode
VirtualNode.getProperty()
public void setTimeout(java.lang.String timeout, boolean waitForTimeout)
VirtualNode
setTimeout
in interface VirtualNode
public void setName(java.lang.String s)
VirtualNode
setName
in interface VirtualNode
s
- VirtualNode.setName(String)
public java.lang.String getName()
VirtualNode
getName
in interface VirtualNode
VirtualNode.getName()
public void addVirtualMachine(VirtualMachine virtualMachine)
VirtualNode
addVirtualMachine
in interface VirtualNode
virtualMachine
- VirtualNode.addVirtualMachine(VirtualMachine)
public VirtualMachine getVirtualMachine()
VirtualNode
getVirtualMachine
in interface VirtualNode
VirtualNode.getVirtualMachine()
public void activate()
VirtualNode
activate
in interface VirtualNode
VirtualNode.activate()
public int getNodeCount()
VirtualNode
getNodeCount
in interface VirtualNode
VirtualNode.getNodeCount()
public int createdNodeCount()
VirtualNode
createdNodeCount
in interface VirtualNode
VirtualNode.createdNodeCount()
public Node getNode() throws NodeException
VirtualNode
getNode
in interface VirtualNode
NodeException
VirtualNode.getNode()
public Node getNode(int index) throws NodeException
VirtualNode
getNode
in interface VirtualNode
index
-
NodeException
VirtualNode.getNode(int)
public java.lang.String[] getNodesURL() throws NodeException
VirtualNode
getNodesURL
in interface VirtualNode
NodeException
VirtualNode.getNodesURL()
public Node[] getNodes() throws NodeException
VirtualNode
getNodes
in interface VirtualNode
NodeException
VirtualNode.getNodes()
public Node getNode(java.lang.String url) throws NodeException
VirtualNode
getNode
in interface VirtualNode
NodeException
VirtualNode.getNode(String)
public void killAll(boolean softly)
VirtualNode
killAll
in interface VirtualNode
softly
- if false, all jvms created when activating this VirtualNode are killed abruptely
if true a jvm that originates the creation of a rmi registry waits until registry is empty before
dying. To be more precise a thraed is created to ask periodically the registry if objects are still
registered.public void createNodeOnCurrentJvm(java.lang.String protocol)
VirtualNode
createNodeOnCurrentJvm
in interface VirtualNode
protocol
- the protocol to create the node. It has to be rmi or jini.VirtualNode.createNodeOnCurrentJvm(String)
public java.lang.Object getUniqueAO() throws ProActiveException
VirtualNode
getUniqueAO
in interface VirtualNode
ProActiveException
- if no active objects are created on this VirtualNode.public boolean isActivated()
VirtualNode
isActivated
in interface VirtualNode
public java.lang.String getJobID()
getJobID
in interface Job
public void setRuntimeInformations(java.lang.String information, java.lang.String value) throws ProActiveException
VirtualNode
lookup virtualNode="vnName" host="*" protocol="rmi or jini", ie the name of the host where to perform the lookup will be known at runtime.We expect to implement several runtime informations. If this method fails, for instance, if the property does not exist or has already been set, or is performed on a VirtualNode not resulting from a lookup, an exception will be thrown but the application will carry on.
setRuntimeInformations
in interface VirtualNode
information
- the information to be set at runtimevalue
- the value of the information
ProActiveException
- if the given information does not exist or has alredy been setAt the moment the only property that can be set at runtime is LOOKUP_HOST.
public void setLookupInformations(java.lang.String url, java.lang.String protocol, int port)
public java.security.cert.X509Certificate getCreatorCertificate() throws ProActiveException
VirtualNode
getCreatorCertificate
in interface VirtualNode
ProActiveException
public PolicyServer getPolicyServer()
getPolicyServer
in interface VirtualNode
public void setPolicyServer(PolicyServer ps)
setPolicyServer
in interface VirtualNode
public void setPolicyFile(java.lang.String file)
setPolicyFile
in interface VirtualNode
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |