org/objectweb/proactive/core/runtime/ProActiveRuntime.java

00001 /* 
00002  * ################################################################
00003  * 
00004  * ProActive: The Java(TM) library for Parallel, Distributed, 
00005  *            Concurrent computing with Security and Mobility
00006  * 
00007  * Copyright (C) 1997-2007 INRIA/University of Nice-Sophia Antipolis
00008  * Contact: proactive@objectweb.org
00009  * 
00010  * This library is free software; you can redistribute it and/or
00011  * modify it under the terms of the GNU Lesser General Public
00012  * License as published by the Free Software Foundation; either
00013  * version 2.1 of the License, or any later version.
00014  *  
00015  * This library is distributed in the hope that it will be useful,
00016  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00017  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00018  * Lesser General Public License for more details.
00019  * 
00020  * You should have received a copy of the GNU Lesser General Public
00021  * License along with this library; if not, write to the Free Software
00022  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
00023  * USA
00024  *  
00025  *  Initial developer(s):               The ProActive Team
00026  *                        http://www.inria.fr/oasis/ProActive/contacts.html
00027  *  Contributor(s): 
00028  * 
00029  * ################################################################
00030  */ 
00031 package org.objectweb.proactive.core.runtime;
00032 
00033 import java.io.IOException;
00034 import java.rmi.AlreadyBoundException;
00035 import java.util.ArrayList;
00036 
00037 import org.apache.log4j.Logger;
00038 import org.objectweb.proactive.Body;
00039 import org.objectweb.proactive.Job;
00040 import org.objectweb.proactive.core.ProActiveException;
00041 import org.objectweb.proactive.core.body.UniversalBody;
00042 import org.objectweb.proactive.core.body.ft.checkpointing.Checkpoint;
00043 import org.objectweb.proactive.core.descriptor.data.ProActiveDescriptor;
00044 import org.objectweb.proactive.core.descriptor.data.VirtualNode;
00045 import org.objectweb.proactive.core.mop.ConstructorCall;
00046 import org.objectweb.proactive.core.mop.ConstructorCallExecutionFailedException;
00047 import org.objectweb.proactive.core.node.NodeException;
00048 import org.objectweb.proactive.core.process.ExternalProcess;
00049 import org.objectweb.proactive.core.process.UniversalProcess;
00050 import org.objectweb.proactive.core.util.log.Loggers;
00051 import org.objectweb.proactive.core.util.log.ProActiveLogger;
00052 import org.objectweb.proactive.ext.security.ProActiveSecurityManager;
00053 import org.objectweb.proactive.ext.security.SecurityEntity;
00054 
00055 
00080 public interface ProActiveRuntime extends Job, SecurityEntity {
00081     static Logger runtimeLogger = ProActiveLogger.getLogger(Loggers.RUNTIME);
00082 
00090     public String createLocalNode(String nodeName,
00091         boolean replacePreviousBinding,
00092         ProActiveSecurityManager nodeSecurityManager, String vnName,
00093         String jobId) throws NodeException, AlreadyBoundException;
00094 
00099     public void killAllNodes() throws ProActiveException;
00100 
00106     public void killNode(String nodeName) throws ProActiveException;
00107 
00114     public void createVM(UniversalProcess remoteProcess)
00115         throws java.io.IOException, ProActiveException;
00116 
00122     public String[] getLocalNodeNames() throws ProActiveException;
00123 
00129     public VMInformation getVMInformation();
00130 
00140     public void register(ProActiveRuntime proActiveRuntimeDist,
00141         String proActiveRuntimeUrl, String creatorID, String creationProtocol,
00142         String vmName) throws ProActiveException;
00143 
00154     public void unregister(ProActiveRuntime proActiveRuntimeDist,
00155         String proActiveRuntimeUrl, String creatorID, String creationProtocol,
00156         String vmName) throws ProActiveException;
00157 
00163     public ProActiveRuntime[] getProActiveRuntimes() throws ProActiveException;
00164 
00171     public ProActiveRuntime getProActiveRuntime(String proActiveRuntimeName)
00172         throws ProActiveException;
00173 
00179     void addAcquaintance(String proActiveRuntimeName) throws ProActiveException;
00180 
00186     public String[] getAcquaintances() throws ProActiveException;
00187 
00194     public void rmAcquaintance(String proActiveRuntimeName)
00195         throws ProActiveException;
00196 
00205     public void killRT(boolean softly) throws Exception;
00206 
00210     public String getURL();
00211 
00219     public ArrayList getActiveObjects(String nodeName)
00220         throws ProActiveException;
00221 
00230     public ArrayList getActiveObjects(String nodeName, String className)
00231         throws ProActiveException;
00232 
00240     public VirtualNode getVirtualNode(String virtualNodeName)
00241         throws ProActiveException;
00242 
00248     public void registerVirtualNode(String virtualNodeName,
00249         boolean replacePreviousBinding)
00250         throws ProActiveException, AlreadyBoundException;
00251 
00257     public void unregisterVirtualNode(String virtualNodeName)
00258         throws ProActiveException;
00259 
00264     public void unregisterAllVirtualNodes() throws ProActiveException;
00265 
00271     public String getJobID(String nodeUrl) throws ProActiveException;
00272 
00291     public UniversalBody createBody(String nodeName,
00292         ConstructorCall bodyConstructorCall, boolean isNodeLocal)
00293         throws ProActiveException, ConstructorCallExecutionFailedException,
00294             java.lang.reflect.InvocationTargetException;
00295 
00310     public UniversalBody receiveBody(String nodeName, Body body)
00311         throws ProActiveException;
00312 
00321     public UniversalBody receiveCheckpoint(String nodeName, Checkpoint ckpt,
00322         int inc) throws ProActiveException;
00323 
00334     public ExternalProcess getProcessToDeploy(
00335         ProActiveRuntime proActiveRuntimeDist, String creatorID, String vmName,
00336         String padURL) throws ProActiveException;
00337 
00338     // SECURITY
00339     public String getVNName(String Nodename) throws ProActiveException;
00340 
00349     public byte[] getClassDataFromThisRuntime(String className)
00350         throws ProActiveException;
00351 
00359     public byte[] getClassDataFromParentRuntime(String className)
00360         throws ProActiveException;
00361 
00370     public void launchMain(String className, String[] parameters)
00371         throws ClassNotFoundException, NoSuchMethodException, ProActiveException;
00372 
00379     public void newRemote(String className)
00380         throws ClassNotFoundException, ProActiveException;
00381 
00390     public ProActiveDescriptor getDescriptor(String url,
00391         boolean isHierarchicalSearch) throws IOException, ProActiveException;
00392 
00402     public Object setLocalNodeProperty(String nodeName, String key, String value)
00403         throws ProActiveException;
00404 
00413     public String getLocalNodeProperty(String nodeName, String key)
00414         throws ProActiveException;
00415 }

Generated on Mon Jan 22 15:16:09 2007 for ProActive by  doxygen 1.5.1