[Swift-commit] cog r4013

swift at ci.uchicago.edu swift at ci.uchicago.edu
Fri Jul 4 02:25:04 CDT 2014


------------------------------------------------------------------------
r4013 | hategan | 2014-07-04 02:23:20 -0500 (Fri, 04 Jul 2014) | 1 line

not used
------------------------------------------------------------------------
Index: modules/examples/.classpath
===================================================================
--- modules/examples/.classpath	(revision 4012)
+++ modules/examples/.classpath	(working copy)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="lib" path="etc"/>
-	<classpathentry exported="true" kind="src" path="/abstraction-common"/>
-	<classpathentry exported="true" kind="src" path="/grapheditor"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/abstraction-provider-gt2"/>
-	<classpathentry kind="lib" path="/abstraction/etc"/>
-	<classpathentry exported="true" kind="con" path="org.eclipse.jdt.USER_LIBRARY/junit"/>
-        <classpathentry kind="lib" path="lib/log4j-1.2.16.jar"/>
-	<classpathentry kind="output" path=".build"/>
-</classpath>
Index: modules/examples/project.properties
===================================================================
--- modules/examples/project.properties	(revision 4012)
+++ modules/examples/project.properties	(working copy)
@@ -1,6 +0,0 @@
-module.name 		= examples
-long.name 		= Various examples for the Java COG Kit
-version			= 2.2
-project			= Java CoG Kit
-lib.deps		= -
-debug 			= true
Index: modules/examples/launchers.xml
===================================================================
--- modules/examples/launchers.xml	(revision 4012)
+++ modules/examples/launchers.xml	(working copy)
@@ -1,29 +0,0 @@
-<project name="Launchers" default="create" basedir=".">
-	<target name="create">	  
-	  <ant antfile="${main.buildfile}" target="example.launcher">
-		<property name="launcher-name" value="hierarchical-dag-handler"/>
-		<property name="class-name"  value="org.globus.cog.abstraction.examples.taskgraph.HierarchicalDAG"/>
-		<property name="launcher-dir" value="examples"/>
-	  </ant>
-
-	  <ant antfile="${main.buildfile}" target="example.launcher">
-		<property name="launcher-name" value="cog-compile-execute"/>
-		<property name="class-name"  value="org.globus.cog.abstraction.examples.taskgraph.RemoteCompileExecute"/>
-		<property name="launcher-dir" value="examples"/>
-	  </ant>
-
-	  <ant antfile="${main.buildfile}" target="example.launcher">
-		<property name="launcher-name" value="hierarchical-dag-visualizer"/>
-		<property name="class-name"    value="org.globus.cog.abstraction.examples.taskgraph.HierarchicalDAGVisualizer"/>
-		<property name="launcher-dir" value="examples"/>
-	  </ant>
-	</target>
-	<target name="webstart">
-	  <ant antfile="${main.buildfile}" target="webstart.launcher">
-		<property name="launcher-name" value="hierarchical-dag-visualizer"/>
-		<property name="class-name"    value="org.globus.cog.abstraction.examples.taskgraph.HierarchicalDAGVisualizer"/>
-		<property name="display-name" value="Hierarchical DAG Visualizer"/>
-	  </ant>
-
-	</target>
-</project>
Index: modules/examples/.project
===================================================================
--- modules/examples/.project	(revision 4012)
+++ modules/examples/.project	(working copy)
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>examples</name>
-	<comment></comment>
-	<projects>
-		<project>abstraction-common</project>
-		<project>grapheditor</project>
-		<project>jglobus</project>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
Index: modules/examples/dependencies.xml
===================================================================
--- modules/examples/dependencies.xml	(revision 4012)
+++ modules/examples/dependencies.xml	(working copy)
@@ -1,17 +0,0 @@
-<project name="Project dependencies" default="deps" basedir=".">
-	<!-- project dependencies -->
-	<target name="deps">
-		<ant antfile="${main.buildfile}" target="dep">
-			<property name="module" value="abstraction"/>
-		</ant>
-		<ant antfile="${main.buildfile}" target="dep">
-			<property name="module" value="abstraction-common"/>
-		</ant>
-		<ant antfile="${main.buildfile}" target="dep">
-			<property name="module" value="grapheditor"/>
-		</ant>
-		<ant antfile="${main.buildfile}" target="dep">
-			<property name="module" value="jglobus"/>
-		</ant>
-	</target>
-</project>
Index: modules/examples/CHANGES.txt
===================================================================
--- modules/examples/CHANGES.txt	(revision 4012)
+++ modules/examples/CHANGES.txt	(working copy)
@@ -1,89 +0,0 @@
-(08/29/2006) v2.2
-
-*** Merged most things (besides DAG examples) into 
-    abstraction-common
-
-(02/08/2006)
-
-*** Added a -stdin option for cog-job-submit.
-
-(08/23/2005)
-
-*** Added  org.globus.cog.abstractions.examples.etc 
-    package to display the client-side environment. Useful for 
-    debugging purposes. Fixed bug:
-    http://www.cogkit.org/bugzilla/show_bug.cgi?id=161
-
-(08/11/2005)
-
-*** Added support for the -specification option in the 
-    JobSubmission example 
-
-(07/01/2005)
-
-*** Added the RemoteCompileExecute.java example in 
-    org.globus.cog.abstractions.examples.taskgraph package 
-
-(06/08/2005)
-
-*** Updated the JobSubmission example to accomodate 
-    job-manager abstractions 
-
-(06/02/2005)
-
-*** Implemented the CheckpointStatus.java example in the 
-    org.globus.cog.abstractions.examples.xml package and  
-    added the corresponding cog-checkpoint-status launcher
-	
--------------------------------2.1----------------------------------
-
-(05/29/2005)
-
-*** Added the cog-checkpoint-submit and the cog-task2xml 
-    launchers 
-
-(05/29/2005)
-
-*** improved the task examples in the  
-    org.globus.cog.abstractions.examples.execution package
-    to handle "attributes" "checkpoint" and "environment"
-    options	 
-
-(05/29/2005)
-
-*** improved the task checkpointing examples in the 
-    org.globus.cog.abstractions.examples.xml package
-
-(04/18/2005)
-
-*** renamed the module from "core-examples" to 
-    "abstraction-examples"
-	
--------------------------------2.0----------------------------------
-
-(03/24/2005)
-
-*** removed redundant files in the 
-    src/org/globus/cog/core/examples/file directory. Instead 
-    added a single FileOperation.java example that provides a 
-    generic example for all file operations. 
-
-(03/24/2005)
-
-*** removed the redundant launchers for file operation tests 
-    and examples. Instead added a single launcher for the file 
-    operation example.
-
-(03/17/2005)
-
-*** moved the cog-job-submit and cog-file-transfer launachers 
-    from the dist/cog-<version>/bin/example directory to the 
-    dist/cog-<version>/bin directory.
-
-(03/17/2005)
-
-*** added the cogrun launcher in the dist/cog-<version>/bin 
-    directory.
-
--------------------------------1.0----------------------------------
-
Index: modules/examples/meta/cog-job-submit/description.txt
===================================================================
--- modules/examples/meta/cog-job-submit/description.txt	(revision 4012)
+++ modules/examples/meta/cog-job-submit/description.txt	(working copy)
@@ -1,9 +0,0 @@
-This command submits a user-specified executable for remote
-execution. The user can specify the service contact for the job
-manager, the provider, the executable, and the optional
-arguments. Several other optional parameters control the behavior
-of the execution. The user can execute this job as a batch job,
-whereby the job status will not be updated on the client side. The
-user can also redirect the job output and error to a user-supplied
-file, either on the remote machine or on the local machine. It also allows 
-long-running jobs to be checkpointed to a local file. 
Index: modules/examples/meta/cog-job-submit/usage.txt
===================================================================
--- modules/examples/meta/cog-job-submit/usage.txt	(revision 4012)
+++ modules/examples/meta/cog-job-submit/usage.txt	(working copy)
@@ -1,57 +0,0 @@
-Usage:
-  cog-job-submit <options> 
-    [(-name | -n) <taskName>]
-      Task name 
-
-    (-service-contact | -s) <host>
-      Service contact 
-
-    [(-job-manager | -jm) <jobmanager>]
-      Execution JobManager (fork, pbs, etc) 
-
-    [(-provider | -p) <provider>]
-      Provider; available providers: [gt2ft, gsiftp, file, gt4.0.0, 
-      gt3.0.2, ssh, gt4ft, gridftp, local, gsiftp-old, http, gt3.2.1, 
-      gt2, gt3.2.0, gridftp-old, ftp, webdav] 
-
-    (-executable | -e) <file>
-      Executable 
-
-    [(-arguments | -args) <string>]
-      Arguments. If more than one, use quotes 
-
-    [(-environment | -env) <string>]
-      Environment variables for the remote execution environment, 
-      specified as "name=value[,name=value]" 
-
-    [(-directory | -d) <string>]
-      Target directory 
-
-    [(-batch | -b)]
-      If present, the job is run in batch mode 
-
-    [(-redirected | -r)]
-      If present, the arguments to -stdout and -stderr refer to local 
-      files 
-
-    [-stdout <file>]
-      Indicates a file where the standard output of the job should be 
-      redirected 
-
-    [-stderr <file>]
-      Indicates a file where the standard error of the job should be 
-      redirected 
-
-    [(-attributes | -a) <string>]
-      Additional task specification attributes. Attributes can be 
-      specified as "name=value[,name=value]" 
-
-    [(-checkpoint | -c) <fileName>]
-      Checkpoint file name. The task will be checkpointed to this file 
-      once submitted 
-
-    [(-verbose | -v)]
-      If enabled, display information about what is being done 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/meta/description.txt
===================================================================
--- modules/examples/meta/description.txt	(revision 4012)
+++ modules/examples/meta/description.txt	(working copy)
@@ -1,11 +0,0 @@
-The abstraction-example module contains the code base for several command 
-line clients and working examples showcasing various important concepts of 
-the abstraction framework. Contained examples demonstrate the following 
-features of the Java Cog Kit:
-
-- How to submit jobs on remote Grid resources 
-- How to transfer files betwen two Grid resources
-- How to invoke file operations on remote Grid resources
-- How to checkpoint and resubmit task executions
-- How to execute hierarchical taskgraphs, queues, and sets
-- How to visualize hierarchical taskgraph executions
Index: modules/examples/meta/cog-file-operation/description.txt
===================================================================
--- modules/examples/meta/cog-file-operation/description.txt	(revision 4012)
+++ modules/examples/meta/cog-file-operation/description.txt	(working copy)
@@ -1,28 +0,0 @@
-This command initiates a connection with a remote file server and
-allows the user to invoke operations on files hosted on that
-server. On execution, this commands enters a shell-based mode allowing the
-user to invoke file operation commands. The following commands are
-supported:
-
-Java CoG Kit File Operation commands 
------------------------------------- 
-Please Note: Commands are case sensitive and all arguments are
-required 
-
-1. stop 
-2. ls 
-3. ls <directory> 
-4. pwd 
-5. cd <directory> 
-6. mkdir <directoryName> 
-7. rmdir <directoryName> <force (true/false)> 
-8. rmfile <fileName> 
-9. isDirectory <directoryName> 
-10. exists <fileName> 
-11. getfile <sourceFileName on server> <destinationFileName on client> 
-12. putfile <sourceFileName on client> <destinationFileName on server> 
-13. getdir <sourceDirectoryName on server> <destinationDirectoryName
-on client> 
-14. putfile <sourceDirectoryName on client> <destinationDirectoryName on server> 
-15. rename <oldName> <newName> 
-16. chmod <fileName> <mode> 
Index: modules/examples/meta/cog-file-operation/usage.txt
===================================================================
--- modules/examples/meta/cog-file-operation/usage.txt	(revision 4012)
+++ modules/examples/meta/cog-file-operation/usage.txt	(working copy)
@@ -1,15 +0,0 @@
-Usage:
-  cog-file-operation <options> 
-    (-service-contact | -s) <hostname>
-      Service contact 
-
-    [(-provider | -p) <provider>]
-      Provider; available providers: [gt2ft, gsiftp, file, gt4.0.0, 
-      gt3.0.2, ssh, gt4ft, gridftp, local, gsiftp-old, http, gt3.2.1, 
-      gt2, gt3.2.0, gridftp-old, ftp, webdav] 
-
-    [(-verbose | -v)]
-      If enabled, display information about what is being done 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/meta/cog-file-transfer/description.txt
===================================================================
--- modules/examples/meta/cog-file-transfer/description.txt	(revision 4012)
+++ modules/examples/meta/cog-file-transfer/description.txt	(working copy)
@@ -1,3 +0,0 @@
-This command transfers a file hosted on one file server to another
-file server. If both the file servers are GridFTP servers, then
-the files can be transfered in third party mode.
Index: modules/examples/meta/cog-file-transfer/usage.txt
===================================================================
--- modules/examples/meta/cog-file-transfer/usage.txt	(revision 4012)
+++ modules/examples/meta/cog-file-transfer/usage.txt	(working copy)
@@ -1,15 +0,0 @@
-Usage:
-  cog-file-transfer <options> 
-    (-source-uri | -s) <URI>
-      Source URI: <provider>://<hostname>[:port]/<directory>/<file> 
-
-    (-destination-uri | -d) <URI>
-      Destination URI: 
-      <provider>://<hostname>[:port]/<directory>/<file> 
-
-    [(-thirdparty | -t)]
-      If present, performs a third party file transfer. Valid only 
-      between two GridFTP resources 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/meta/cog-task2xml/description.txt
===================================================================
--- modules/examples/meta/cog-task2xml/description.txt	(revision 4012)
+++ modules/examples/meta/cog-task2xml/description.txt	(working copy)
@@ -1,9 +0,0 @@
-This command simply translates the given task into an XML format
-without actually submitting the task. 
-The user can specify the service contact for the job
-manager, the provider, the executable, and the optional
-arguments. Several other optional parameters control the behavior
-of the execution. The user can execute this job as a batch job,
-whereby the job status will not be updated on the client side. The
-user can also redirect the job output and error to a user-supplied
-file, either on the remote machine or on the local machine.
Index: modules/examples/meta/cog-task2xml/usage.txt
===================================================================
--- modules/examples/meta/cog-task2xml/usage.txt	(revision 4012)
+++ modules/examples/meta/cog-task2xml/usage.txt	(working copy)
@@ -1,56 +0,0 @@
-Usage:
-  cog-task2xml <options> 
-    (-checkpoint | -c) <fileName>
-      Checkpoint file name. The task will be checkpointed to this file 
-
-    [(-name | -n) <taskName>]
-      Task name 
-
-    (-service-contact | -s) <host>
-      Service contact 
-
-    [(-job-manager | -jm) <jobmanager>]
-      Execution JobManager (fork, pbs, etc) 
-
-    [(-provider | -p) <provider>]
-      Provider; available providers: [gt2ft, gsiftp, file, gt4.0.0, 
-      gt3.0.2, ssh, gt4ft, gridftp, local, gsiftp-old, http, gt3.2.1, 
-      gt2, gt3.2.0, gridftp-old, ftp, webdav] 
-
-    (-executable | -e) <file>
-      Executable 
-
-    [(-arguments | -args) <string>]
-      Arguments. If more than one, use quotes 
-
-    [(-environment | -env) <string>]
-      Environment variables for the remote execution environment, 
-      specified as "name=value[,name=value]" 
-
-    [(-directory | -d) <string>]
-      Target directory 
-
-    [(-batch | -b)]
-      If present, the job is run in batch mode 
-
-    [(-redirected | -r)]
-      If present, the arguments to -stdout and -stderr refer to local 
-      files 
-
-    [-stdout <file>]
-      Indicates a file where the standard output of the job should be 
-      redirected 
-
-    [-stderr <file>]
-      Indicates a file where the standard error of the job should be 
-      redirected 
-
-    [(-attributes | -a) <string>]
-      Additional task specification attributes. Attributes can be 
-      specified as "name=value[,name=value]" 
-
-    [(-verbose | -v)]
-      If enabled, display information about what is being done 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/meta/cogrun/description.txt
===================================================================
--- modules/examples/meta/cogrun/description.txt	(revision 4012)
+++ modules/examples/meta/cogrun/description.txt	(working copy)
@@ -1,8 +0,0 @@
-This command submits a user-specified executable for remote
-execution. The user can specify the service contact for the job
-manager, the provider, the executable, and the optional
-arguments. Several other optional parameters control the behavior
-of the execution. The user can execute this job as a batch job,
-whereby the job status will not be updated on the client side. The
-user can also redirect the job output and error to a user-supplied
-file, either on the remote machine or on the local machine.
Index: modules/examples/meta/cogrun/usage.txt
===================================================================
--- modules/examples/meta/cogrun/usage.txt	(revision 4012)
+++ modules/examples/meta/cogrun/usage.txt	(working copy)
@@ -1,57 +0,0 @@
-Usage:
-  cogrun <options> 
-    [(-name | -n) <taskName>]
-      Task name 
-
-    (-service-contact | -s) <host>
-      Service contact 
-
-    [(-job-manager | -jm) <jobmanager>]
-      Execution JobManager (fork, pbs, etc) 
-
-    [(-provider | -p) <provider>]
-      Provider; available providers: [gt2ft, gsiftp, file, gt4.0.0, 
-      gt3.0.2, ssh, gt4ft, gridftp, local, gsiftp-old, http, gt3.2.1, 
-      gt2, gt3.2.0, gridftp-old, ftp, webdav] 
-
-    (-executable | -e) <file>
-      Executable 
-
-    [(-arguments | -args) <string>]
-      Arguments. If more than one, use quotes 
-
-    [(-environment | -env) <string>]
-      Environment variables for the remote execution environment, 
-      specified as "name=value[,name=value]" 
-
-    [(-directory | -d) <string>]
-      Target directory 
-
-    [(-batch | -b)]
-      If present, the job is run in batch mode 
-
-    [(-redirected | -r)]
-      If present, the arguments to -stdout and -stderr refer to local 
-      files 
-
-    [-stdout <file>]
-      Indicates a file where the standard output of the job should be 
-      redirected 
-
-    [-stderr <file>]
-      Indicates a file where the standard error of the job should be 
-      redirected 
-
-    [(-attributes | -a) <string>]
-      Additional task specification attributes. Attributes can be 
-      specified as "name=value[,name=value]" 
-
-    [(-checkpoint | -c) <fileName>]
-      Checkpoint file name. The task will be checkpointed to this file 
-      once submitted 
-
-    [(-verbose | -v)]
-      If enabled, display information about what is being done 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/meta/cog-checkpoint-status/description.txt
===================================================================
--- modules/examples/meta/cog-checkpoint-status/description.txt	(revision 4012)
+++ modules/examples/meta/cog-checkpoint-status/description.txt	(working copy)
@@ -1,6 +0,0 @@
-This command allows the user to check the status of a long running
-task. The task is represented by the checkpoint file (created by
-the cogrun, cog-job-submit, or cog-task2xml commands). Upon
-submission, the client re-connects to the remote execution service and
-retreives the latest execution status.
-
Index: modules/examples/meta/cog-checkpoint-status/usage.txt
===================================================================
--- modules/examples/meta/cog-checkpoint-status/usage.txt	(revision 4012)
+++ modules/examples/meta/cog-checkpoint-status/usage.txt	(working copy)
@@ -1,10 +0,0 @@
-Usage:
-  cog-checkpoint-status <options> 
-    (-checkpoint | -c) <fileName>
-      Input checkpoint file 
-
-    [(-verbose | -v)]
-      If enabled, display information about what is being done 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/meta/cog-checkpoint-submit/description.txt
===================================================================
--- modules/examples/meta/cog-checkpoint-submit/description.txt	(revision 4012)
+++ modules/examples/meta/cog-checkpoint-submit/description.txt	(working copy)
@@ -1,4 +0,0 @@
-This command allows the user to submit a checkpoint file (created by
-the cogrun, cog-job-submit, or cog-task2xml commands). Upon
-submission, the client re-connects to the remote execution service and
-actively monitors the status updates.
Index: modules/examples/meta/cog-checkpoint-submit/usage.txt
===================================================================
--- modules/examples/meta/cog-checkpoint-submit/usage.txt	(revision 4012)
+++ modules/examples/meta/cog-checkpoint-submit/usage.txt	(working copy)
@@ -1,10 +0,0 @@
-Usage:
-  cog-checkpoint-submit <options> 
-    (-checkpoint | -c) <fileName>
-      Input checkpoint file 
-
-    [(-verbose | -v)]
-      If enabled, display information about what is being done 
-
-    [(-help | -h)]
-      Display usage 
Index: modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/RemoteCompileExecute.java
===================================================================
--- modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/RemoteCompileExecute.java	(revision 4012)
+++ modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/RemoteCompileExecute.java	(working copy)
@@ -1,303 +0,0 @@
-// ----------------------------------------------------------------------
-//This code is developed as part of the Java CoG Kit project
-//The terms of the license can be found at http://www.cogkit.org/license
-//This message may not be removed or altered.
-//----------------------------------------------------------------------
-
-package org.globus.cog.abstraction.examples.taskgraph;
-
-import java.io.File;
-
-import org.apache.log4j.Logger;
-import org.globus.cog.abstraction.impl.common.AbstractionFactory;
-import org.globus.cog.abstraction.impl.common.AbstractionProperties;
-import org.globus.cog.abstraction.impl.common.ProviderMethodException;
-import org.globus.cog.abstraction.impl.common.StatusEvent;
-import org.globus.cog.abstraction.impl.common.task.ExecutionServiceImpl;
-import org.globus.cog.abstraction.impl.common.task.IllegalSpecException;
-import org.globus.cog.abstraction.impl.common.task.InvalidProviderException;
-import org.globus.cog.abstraction.impl.common.task.InvalidSecurityContextException;
-import org.globus.cog.abstraction.impl.common.task.InvalidServiceContactException;
-import org.globus.cog.abstraction.impl.common.task.JobSpecificationImpl;
-import org.globus.cog.abstraction.impl.common.task.ServiceContactImpl;
-import org.globus.cog.abstraction.impl.common.task.TaskImpl;
-import org.globus.cog.abstraction.impl.common.task.TaskSubmissionException;
-import org.globus.cog.abstraction.impl.common.taskgraph.TaskGraphHandlerImpl;
-import org.globus.cog.abstraction.impl.common.taskgraph.TaskGraphImpl;
-import org.globus.cog.abstraction.interfaces.ExecutableObject;
-import org.globus.cog.abstraction.interfaces.ExecutionService;
-import org.globus.cog.abstraction.interfaces.JobSpecification;
-import org.globus.cog.abstraction.interfaces.SecurityContext;
-import org.globus.cog.abstraction.interfaces.ServiceContact;
-import org.globus.cog.abstraction.interfaces.Status;
-import org.globus.cog.abstraction.interfaces.StatusListener;
-import org.globus.cog.abstraction.interfaces.Task;
-import org.globus.cog.abstraction.interfaces.TaskGraph;
-import org.globus.cog.abstraction.interfaces.TaskGraphHandler;
-import org.globus.cog.abstraction.tools.transfer.FileTransfer;
-import org.globus.cog.util.ArgumentParser;
-import org.globus.cog.util.ArgumentParserException;
-
-/*
- * This example demonstrates an execution flow where a local java file needs to
- * be compiled and executed remotely. Then it transfers the stdout of the remote
- * execution back to the local machine.
- */
-public class RemoteCompileExecute implements StatusListener {
-    static Logger logger = Logger.getLogger(RemoteCompileExecute.class
-            .getName());
-    private String serviceContact = null;
-    private String executionProvider = null;
-    private String transferProvider = null;
-    private String sourceFile = null;
-    private String normalizedFileName = null;
-    private String javaHome = null;
-    private String classpath = null;
-    private TaskGraph tg = null;
-
-    public static void main(String args[]) {
-        ArgumentParser ap = new ArgumentParser();
-        ap.setExecutableName("cog-compile-execute");
-        ap.addOption("src", "Name of the Java source file", "filename",
-                ArgumentParser.NORMAL);
-        ap.addAlias("src", "s");
-        ap.addOption("javaHome",
-                "Path of the Java environment on the remote machine", "path",
-                ArgumentParser.NORMAL);
-        ap.addAlias("javaHome", "j");
-        ap.addOption("classpath",
-                "Path of the Java classpath on the remote machine", "path",
-                ArgumentParser.OPTIONAL);
-        ap.addAlias("classpath", "cp");
-        ap.addOption("execution-provider",
-                "Execution provider; available providers: "
-                        + AbstractionProperties.getProviders().toString(),
-                "provider", ArgumentParser.NORMAL);
-        ap.addAlias("execution-provider", "ep");
-        ap.addOption("transfer-provider",
-                "Transfer provider; available providers: "
-                        + AbstractionProperties.getProviders().toString(),
-                "provider", ArgumentParser.NORMAL);
-        ap.addAlias("transfer-provider", "tp");
-        ap.addOption("service-contact", "Service contact for the remote host",
-                "host", ArgumentParser.NORMAL);
-        ap.addAlias("service-contact", "sc");
-        ap.addFlag("verbose",
-                "If enabled, display information about what is being done");
-        ap.addAlias("verbose", "v");
-        ap.addFlag("help", "Display usage");
-        ap.addAlias("help", "h");
-        try {
-            ap.parse(args);
-            if (ap.isPresent("help")) {
-                ap.usage();
-            } else {
-                ap.checkMandatory();
-                try {
-                    RemoteCompileExecute rce = new RemoteCompileExecute();
-                    rce.setServiceContact(ap.getStringValue("service-contact"));
-                    rce.setExecutionProvider(ap
-                            .getStringValue("execution-provider"));
-                    rce.setTransferProvider(ap
-                            .getStringValue("transfer-provider"));
-                    rce.setSourceFile(ap.getStringValue("src"));
-                    rce.setJavaHome(ap.getStringValue("javaHome"));
-                    rce.setClasspath(ap.getStringValue("classpath", null));
-                    rce.prepareTaskGraph();
-                    rce.submit();
-                } catch (Exception e) {
-                    logger.error("Exception in main", e);
-                }
-            }
-        } catch (ArgumentParserException e) {
-            System.err.println("Error parsing arguments: " + e.getMessage());
-            ap.usage();
-        }
-    }
-
-    private void prepareTaskGraph() throws Exception {
-        this.tg = new TaskGraphImpl();
-        tg.setName("Workflow");
-        Task transferTask = prepareFileTransferTask();
-        Task compileTask = prepareCompileTask();
-        Task executeTask = prepareExecutionTask();
-        tg.add(transferTask);
-        tg.add(compileTask);
-        tg.add(executeTask);
-
-        tg.addDependency(transferTask, compileTask);
-        tg.addDependency(compileTask, executeTask);
-        tg.addStatusListener(this);
-    }
-
-    private void submit() {
-        TaskGraphHandler handler = new TaskGraphHandlerImpl();
-        try {
-            handler.submit(this.tg);
-            logger.debug("TaskGraph submitted");
-        } catch (InvalidSecurityContextException ise) {
-            logger.error("Security Exception");
-            ise.printStackTrace();
-            System.exit(1);
-        } catch (TaskSubmissionException tse) {
-            logger.error("TaskSubmission Exception");
-            tse.printStackTrace();
-            System.exit(1);
-        } catch (IllegalSpecException ispe) {
-            logger.error("Specification Exception");
-            ispe.printStackTrace();
-            System.exit(1);
-        } catch (InvalidServiceContactException isce) {
-            logger.error("Service Contact Exception");
-            isce.printStackTrace();
-            System.exit(1);
-        }
-    }
-
-    private Task prepareFileTransferTask() throws Exception {
-        FileTransfer fileTransfer = new FileTransfer("Transfer_Task", "file://"
-                + this.sourceFile, this.transferProvider + "://"
-                + this.serviceContact + "///tmp/" + normalizedFileName
-                + ".java");
-        fileTransfer.prepareTask();
-        Task task = fileTransfer.getFileTransferTask();
-        task.removeStatusListener(fileTransfer);
-        task.addStatusListener(this);
-        return task;
-    }
-
-    private Task prepareCompileTask() throws InvalidProviderException,
-            ProviderMethodException {
-        Task task = new TaskImpl("Compile_Task", Task.JOB_SUBMISSION);
-        JobSpecification spec = new JobSpecificationImpl();
-
-        spec.setExecutable(this.javaHome + "/bin/javac");
-        if (this.classpath != null) {
-            spec.addArgument(" -classpath");
-            spec.addArgument(this.classpath);
-        }
-        spec.addArgument("/tmp/" + this.normalizedFileName + ".java");
-        spec.setRedirected(true);
-        task.setSpecification(spec);
-
-        ExecutionService service = new ExecutionServiceImpl();
-        service.setProvider(this.executionProvider.toLowerCase());
-
-        SecurityContext securityContext = AbstractionFactory
-                .newSecurityContext(this.executionProvider.toLowerCase());
-        securityContext.setCredentials(null);
-        service.setSecurityContext(securityContext);
-
-        ServiceContact sc = new ServiceContactImpl(this.serviceContact);
-        service.setServiceContact(sc);
-        task.addService(service);
-
-        task.addStatusListener(this);
-        return task;
-    }
-
-    private Task prepareExecutionTask() throws InvalidProviderException,
-            ProviderMethodException {
-        Task task = new TaskImpl("Execution_Task", Task.JOB_SUBMISSION);
-
-        JobSpecification spec = new JobSpecificationImpl();
-
-        spec.setExecutable(this.javaHome + "/bin/java");
-        if (this.classpath == null) {
-            spec.addArgument(" -classpath");
-            spec.addArgument("/tmp");
-        } else {
-            spec.addArgument(" -classpath");
-            spec.addArgument("/tmp" + File.pathSeparator + this.classpath);
-        }
-        spec.addArgument(normalizedFileName);
-        spec.setRedirected(true);
-        task.setSpecification(spec);
-
-        ExecutionService service = new ExecutionServiceImpl();
-        service.setProvider(this.executionProvider.toLowerCase());
-
-        SecurityContext securityContext = AbstractionFactory
-                .newSecurityContext(this.executionProvider.toLowerCase());
-        securityContext.setCredentials(null);
-        service.setSecurityContext(securityContext);
-
-        ServiceContact sc = new ServiceContactImpl(this.serviceContact);
-        service.setServiceContact(sc);
-        task.addService(service);
-
-        task.addStatusListener(this);
-        return task;
-    }
-
-    public String getExecutionProvider() {
-        return executionProvider;
-    }
-
-    public void setExecutionProvider(String provider) {
-        this.executionProvider = provider;
-    }
-
-    public String getSourceFile() {
-        return sourceFile;
-    }
-
-    public void setSourceFile(String sourceFile) {
-        this.sourceFile = sourceFile;
-        String filename = this.sourceFile.substring(this.sourceFile
-                .lastIndexOf("/"));
-        filename = filename.substring(1, filename.lastIndexOf(".java"));
-        this.normalizedFileName = filename;
-        logger.debug("Normalized file " + this.normalizedFileName);
-    }
-
-    public String getServiceContact() {
-        return serviceContact;
-    }
-
-    public void setServiceContact(String serviceContact) {
-        this.serviceContact = serviceContact;
-    }
-
-    public String getJavaHome() {
-        return javaHome;
-    }
-
-    public void setJavaHome(String javaHome) {
-        this.javaHome = javaHome;
-    }
-
-    public void statusChanged(StatusEvent event) {
-        ExecutableObject eo = event.getSource();
-        Status status = event.getStatus();
-        if (eo.getObjectType() == ExecutableObject.TASK) {
-            logger.debug("Status of " + eo.getName() + " changed to: "
-                    + status.getStatusString());
-            if (status.getStatusCode() == Status.COMPLETED
-                    && ((Task) eo).getStdOutput() != null) {
-                System.out.println("Output = " + ((Task) eo).getStdOutput());
-            }
-        } else {
-            if (status.getStatusCode() == Status.COMPLETED
-                    || status.getStatusCode() == Status.FAILED) {
-                System.exit(0);
-            }
-        }
-    }
-
-    public String getClasspath() {
-        return classpath;
-    }
-
-    public void setClasspath(String classpath) {
-        this.classpath = classpath;
-    }
-
-    public String getTransferProvider() {
-        return transferProvider;
-    }
-
-    public void setTransferProvider(String transferProvider) {
-        this.transferProvider = transferProvider;
-    }
-}
\ No newline at end of file
Index: modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/HierarchicalDAGVisualizer.java
===================================================================
--- modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/HierarchicalDAGVisualizer.java	(revision 4012)
+++ modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/HierarchicalDAGVisualizer.java	(working copy)
@@ -1,324 +0,0 @@
-// ----------------------------------------------------------------------
-// This code is developed as part of the Java CoG Kit project
-// The terms of the license can be found at http://www.cogkit.org/license
-// This message may not be removed or altered.
-// ----------------------------------------------------------------------
-
-package org.globus.cog.abstraction.examples.taskgraph;
-
-import java.awt.event.ActionEvent;
-import java.awt.event.ActionListener;
-import java.util.Enumeration;
-import java.util.Hashtable;
-
-import org.globus.cog.abstraction.impl.common.StatusEvent;
-import org.globus.cog.abstraction.impl.common.taskgraph.DependencyPair;
-import org.globus.cog.abstraction.interfaces.Dependency;
-import org.globus.cog.abstraction.interfaces.ExecutableObject;
-import org.globus.cog.abstraction.interfaces.Status;
-import org.globus.cog.abstraction.interfaces.StatusListener;
-import org.globus.cog.abstraction.interfaces.Task;
-import org.globus.cog.abstraction.interfaces.TaskGraph;
-import org.globus.cog.gui.grapheditor.RendererFactory;
-import org.globus.cog.gui.grapheditor.RootContainer;
-import org.globus.cog.gui.grapheditor.canvas.GraphCanvas;
-import org.globus.cog.gui.grapheditor.generic.GenericEdge;
-import org.globus.cog.gui.grapheditor.generic.GenericNode;
-import org.globus.cog.gui.grapheditor.generic.RootNode;
-import org.globus.cog.gui.grapheditor.properties.OverlayedProperty;
-import org.globus.cog.gui.grapheditor.properties.Property;
-import org.globus.cog.gui.grapheditor.targets.swing.GraphFrame;
-import org.globus.cog.gui.grapheditor.targets.swing.SwingCanvasRenderer;
-import org.globus.cog.gui.grapheditor.targets.swing.util.CanvasAction;
-import org.globus.cog.gui.grapheditor.targets.swing.util.CanvasActionEvent;
-import org.globus.cog.gui.grapheditor.targets.swing.util.CanvasActionListener;
-import org.globus.cog.gui.grapheditor.targets.swing.views.GraphView;
-import org.globus.cog.util.graph.Graph;
-import org.globus.cog.util.graph.Node;
-
-public class HierarchicalDAGVisualizer extends HierarchicalDAG implements
-        StatusListener, ActionListener, CanvasActionListener {
-    private Hashtable nodeMapping;
-    private CanvasAction run;
-
-    public HierarchicalDAGVisualizer() {
-        super();
-        this.nodeMapping = new Hashtable();
-    }
-
-    private RootNode init() {
-        RootNode rootNode = new RootNode();
-        rootNode.setName("Java CoG Kit Work Manager");
-        GraphCanvas graphCanvas = rootNode.getCanvas();
-        if (graphCanvas == null) {
-            graphCanvas = rootNode.createCanvas();
-        }
-        Graph graph = new Graph();
-        GenericNode gn = new GenericNode();
-        createSubGraph(gn, this.taskGraph);
-        graph.addNode(gn);
-        this.nodeMapping.put(this.taskGraph, gn);
-        graphCanvas.setGraph(graph);
-        return rootNode;
-    }
-
-    private void updateRenderer(SwingCanvasRenderer renderer) {
-        this.run = new CanvasAction("300#Control>1#Run", null,
-                CanvasAction.ACTION_NORMAL);
-        this.run.addCanvasActionListener(this);
-        renderer.addToolBarItem(this.run);
-
-        renderer.setView(new GraphView());
-    }
-
-    private void createSubGraph(GenericNode genericNode,
-            ExecutableObject executableObject) {
-        if (executableObject.getObjectType() == ExecutableObject.TASK) {
-            Task task = (Task) executableObject;
-            task.addStatusListener(this);
-            setTaskProperties(genericNode, task);
-        } else if (executableObject.getObjectType() == ExecutableObject.TASKGRAPH) {
-            TaskGraph taskGraph = (TaskGraph) executableObject;
-            taskGraph.addStatusListener(this);
-            setGraphProperties(genericNode, taskGraph);
-
-            GraphCanvas subCanvas = genericNode.getCanvas();
-            if (subCanvas == null) {
-                subCanvas = genericNode.createCanvas();
-            }
-            Graph graph = new Graph();
-
-            Enumeration en = taskGraph.elements();
-            while (en.hasMoreElements()) {
-                ExecutableObject eo = (ExecutableObject) en.nextElement();
-                GenericNode gn = new GenericNode();
-                createSubGraph(gn, eo);
-                graph.addNode(gn);
-                this.nodeMapping.put(eo, gn);
-            }
-
-            // Draw the dependencies
-            Dependency dependency = taskGraph.getDependency();
-            if (dependency != null) {
-                Enumeration en1 = dependency.elements();
-                while (en1.hasMoreElements()) {
-                    DependencyPair pair = (DependencyPair) en1.nextElement();
-                    ExecutableObject eo1 = pair.getFrom();
-                    ExecutableObject eo2 = pair.getTo();
-
-                    GenericNode gn1 = (GenericNode) this.nodeMapping.get(eo1);
-                    GenericNode gn2 = (GenericNode) this.nodeMapping.get(eo2);
-
-                    Node node1 = graph.findNode(gn1);
-                    Node node2 = graph.findNode(gn2);
-
-                    graph.addEdge(node1, node2, new GenericEdge());
-                }
-            }
-            subCanvas.setGraph(graph);
-        }
-    }
-
-    private void setTaskProperties(GenericNode genericNode, Task task) {
-        Property property;
-
-        property = new OverlayedProperty(genericNode, "Identity");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Type");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "StdError");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "StdOutput");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Provider");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "ServiceContact");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Specification");
-        genericNode.addProperty(property);
-
-        // set all the above defined properties:
-        genericNode.getProperty("name").setValue(task.getName());
-        genericNode.getProperty("Identity").setValue(
-                task.getIdentity().toString());
-        genericNode.getProperty("Type").setValue(
-                Integer.toString(task.getType()));
-        genericNode.getProperty("StdOutput").setValue(task.getStdOutput());
-        genericNode.getProperty("StdError").setValue(task.getStdError());
-        genericNode.getProperty("Provider").setValue(task.getProvider());
-        genericNode.getProperty("status").setValue(
-                new Integer(GenericNode.STATUS_STOPPED));
-        genericNode.getProperty("Specification").setValue(
-                task.getSpecification().getSpecification());
-    }
-
-    private void setGraphProperties(GenericNode genericNode, TaskGraph taskGraph) {
-        Property property;
-
-        property = new OverlayedProperty(genericNode, "Identity");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Size");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Unsubmitted");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Submitted");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Active");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Suspended");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Resumed");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Canceled");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Failed");
-        genericNode.addProperty(property);
-
-        property = new OverlayedProperty(genericNode, "Completed");
-        genericNode.addProperty(property);
-
-        // set all the above defined properties:
-        genericNode.getProperty("name").setValue(taskGraph.getName());
-        genericNode.getProperty("Identity").setValue(
-                taskGraph.getIdentity().toString());
-        genericNode.getProperty("status").setValue(
-                new Integer(GenericNode.STATUS_STOPPED));
-        genericNode.getProperty("Size").setValue(
-                Integer.toString(taskGraph.getSize()));
-        genericNode.getProperty("Unsubmitted").setValue(
-                Integer.toString(taskGraph.getUnsubmittedCount()));
-        genericNode.getProperty("Submitted").setValue(
-                Integer.toString(taskGraph.getSubmittedCount()));
-        genericNode.getProperty("Active").setValue(
-                Integer.toString(taskGraph.getActiveCount()));
-        genericNode.getProperty("Suspended").setValue(
-                Integer.toString(taskGraph.getSuspendedCount()));
-        genericNode.getProperty("Resumed").setValue(
-                Integer.toString(taskGraph.getResumedCount()));
-        genericNode.getProperty("Canceled").setValue(
-                Integer.toString(taskGraph.getCanceledCount()));
-        genericNode.getProperty("Failed").setValue(
-                Integer.toString(taskGraph.getFailedCount()));
-        genericNode.getProperty("Completed").setValue(
-                Integer.toString(taskGraph.getCompletedCount()));
-    }
-
-    public void updateProperties(StatusEvent event) {
-        TaskGraph taskGraph = (TaskGraph) event.getSource();
-        GenericNode genericNode = (GenericNode) this.nodeMapping.get(event
-                .getSource());
-
-        genericNode.getProperty("Unsubmitted").setValue(
-                Integer.toString(taskGraph.getUnsubmittedCount()));
-        genericNode.getProperty("Submitted").setValue(
-                Integer.toString(taskGraph.getSubmittedCount()));
-        genericNode.getProperty("Active").setValue(
-                Integer.toString(taskGraph.getActiveCount()));
-        genericNode.getProperty("Suspended").setValue(
-                Integer.toString(taskGraph.getSuspendedCount()));
-        genericNode.getProperty("Resumed").setValue(
-                Integer.toString(taskGraph.getResumedCount()));
-        genericNode.getProperty("Canceled").setValue(
-                Integer.toString(taskGraph.getCanceledCount()));
-        genericNode.getProperty("Failed").setValue(
-                Integer.toString(taskGraph.getFailedCount()));
-        genericNode.getProperty("Completed").setValue(
-                Integer.toString(taskGraph.getCompletedCount()));
-    }
-
-    public void statusChanged(StatusEvent event) {
-        ExecutableObject executableObject = event.getSource();
-        GenericNode gn = (GenericNode) this.nodeMapping.get(executableObject);
-        int status = event.getStatus().getStatusCode();
-        logger.debug("ID: " + executableObject.getIdentity().toString());
-        logger.debug("Status: " + executableObject.getStatus().getStatusCode());
-        switch (status) {
-        case Status.UNSUBMITTED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_STOPPED));
-            break;
-        case Status.SUBMITTED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_RUNNING));
-            break;
-        case Status.ACTIVE:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_RUNNING));
-            break;
-        case Status.FAILED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_FAILED));
-            break;
-        case Status.COMPLETED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_COMPLETED));
-            break;
-        case Status.CANCELED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_FAILED));
-            break;
-        case Status.SUSPENDED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_STOPPED));
-            break;
-        case Status.RESUMED:
-            gn.getProperty("status").setValue(
-                    new Integer(GenericNode.STATUS_RUNNING));
-            break;
-        default:
-            break;
-        }
-        if (executableObject.getObjectType() == ExecutableObject.TASKGRAPH) {
-            updateProperties(event);
-        }
-    }
-
-    public void actionPerformed(ActionEvent event) {
-        if (event.getActionCommand().equals("Run")) {
-            if (!this.active) {
-                this.active = true;
-                submitDAG();
-            }
-        }
-    }
-
-    public void canvasActionPerformed(CanvasActionEvent e) {
-        if (e.getSource() == this.run) {
-            if (!this.active) {
-                this.active = true;
-                submitDAG();
-            }
-        }
-    }
-
-    public static void main(String[] args) {
-        try {
-            HierarchicalDAGVisualizer dagViz = new HierarchicalDAGVisualizer();
-            dagViz.createDAG();
-            RendererFactory.addRootContainer("swing", GraphFrame.class);
-            RootContainer rootContainer = new GraphFrame();
-            RootNode rootNode = dagViz.init();
-            rootContainer.setRootNode(rootNode);
-            dagViz.updateRenderer((SwingCanvasRenderer) rootContainer
-                    .getCanvasRenderer());
-            Thread thread = new Thread(rootContainer);
-            thread.start();
-        } catch (Exception e) {
-            logger.error("Exception caught: ", e);
-        }
-    }
-}
\ No newline at end of file
Index: modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/HierarchicalDAG.java
===================================================================
--- modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/HierarchicalDAG.java	(revision 4012)
+++ modules/examples/src/org/globus/cog/abstraction/examples/taskgraph/HierarchicalDAG.java	(working copy)
@@ -1,182 +0,0 @@
-// ----------------------------------------------------------------------
-// This code is developed as part of the Java CoG Kit project
-// The terms of the license can be found at http://www.cogkit.org/license
-// This message may not be removed or altered.
-// ----------------------------------------------------------------------
-
-package org.globus.cog.abstraction.examples.taskgraph;
-
-import org.apache.log4j.Logger;
-import org.globus.cog.abstraction.impl.common.StatusEvent;
-import org.globus.cog.abstraction.impl.common.task.IllegalSpecException;
-import org.globus.cog.abstraction.impl.common.task.InvalidSecurityContextException;
-import org.globus.cog.abstraction.impl.common.task.InvalidServiceContactException;
-import org.globus.cog.abstraction.impl.common.task.TaskSubmissionException;
-import org.globus.cog.abstraction.impl.common.taskgraph.TaskGraphHandlerImpl;
-import org.globus.cog.abstraction.impl.common.taskgraph.TaskGraphImpl;
-import org.globus.cog.abstraction.interfaces.ExecutableObject;
-import org.globus.cog.abstraction.interfaces.Status;
-import org.globus.cog.abstraction.interfaces.StatusListener;
-import org.globus.cog.abstraction.interfaces.Task;
-import org.globus.cog.abstraction.interfaces.TaskGraph;
-import org.globus.cog.abstraction.interfaces.TaskGraphHandler;
-import org.globus.cog.abstraction.tools.transfer.FileTransfer;
-
-/*
- * This class serves as an example to demonstrate the execution of hierarchical
- * taskgraphs (DAGs). It simply shows the semantics of how a user can create a
- * hierarchy of task graph and submit additional tasks to an already executing
- * task graph (a.k.a adding tasks to a "live taskgraph"). The parameters to the
- * task specification MUST be changed to suite your requirements and
- * environment.
- */
-public class HierarchicalDAG implements StatusListener {
-    static Logger logger = Logger.getLogger(HierarchicalDAG.class.getName());
-    protected org.globus.cog.abstraction.interfaces.TaskGraph taskGraph;
-    protected boolean active = false;
-    private boolean submitted = false;
-    private Task task6 = null;
-    private Task task9 = null;
-    private TaskGraph tg5 = null;
-
-    public void createDAG() throws Exception {
-        TaskGraph tg1 = new TaskGraphImpl();
-        try {
-            tg1.setName("TG1");
-            Task task1 = prepareTask("Task1",
-                    "gridftp://hot.mcs.anl.gov:2811//home/cog/gridfile1",
-                    "gridftp://cold.mcs.anl.gov:2811//home/cog/gridfile1");
-            Task task2 = prepareTask("Task2",
-                    "gridftp://cold.mcs.anl.gov:2811//home/cog/gridfile2",
-                    "gridftp://hot.mcs.anl.gov:2811//home/cog/gridfile2");
-            tg1.add(task1);
-            tg1.add(task2);
-            tg1.addDependency(task1, task2);
-
-            TaskGraph tg2 = new TaskGraphImpl();
-            tg2.setName("TG2");
-            Task task3 = prepareTask("Task3",
-                    "gridftp://hot.mcs.anl.gov:2811//home/cog/gridfile3",
-                    "gridftp://cold.mcs.anl.gov:2811//home/cog/gridfile3");
-            Task task4 = prepareTask("Task4",
-                    "gridftp://cold.mcs.anl.gov:2811//home/cog/gridfile4",
-                    "gridftp://hot.mcs.anl.gov:2811//home/cog/gridfile4");
-            tg2.add(task3);
-            tg2.add(task4);
-            tg2.addDependency(task3, task4);
-
-            TaskGraph tg3 = new TaskGraphImpl();
-            tg3.setName("TG3");
-            tg3.add(tg1);
-            tg3.add(tg2);
-            tg3.addDependency(tg1, tg2);
-
-            TaskGraph tg4 = new TaskGraphImpl();
-            tg4.setName("TG4");
-            Task task5 = prepareTask("Task5",
-                    "gridftp://new.mcs.anl.gov:2811//home/cog/gridfile6",
-                    "gridftp://old.mcs.anl.gov:2811//home/cog/gridfile7");
-            tg4.add(tg3);
-            tg4.add(task5);
-            tg4.addDependency(tg3, task5);
-
-            tg5 = new TaskGraphImpl();
-
-            Task task7 = prepareTask("Task7",
-                    "gridftp://old.mcs.anl.gov:2811//home/cog/gridfile8",
-                    "gridftp://new.mcs.anl.gov:2811//home/cog/gridfile9");
-            Task task8 = prepareTask("Task8",
-                    "gridftp://here.mcs.anl.gov:2811//home/cog/gridfile10",
-                    "gridftp://there.mcs.anl.gov:2811//home/cog/gridfile10");
-            task9 = prepareTask("Task9",
-                    "gridftp://here.mcs.anl.gov:2811//home/cog/gridfile11",
-                    "gridftp://there.mcs.anl.gov:2811//home/cog/gridfile11");
-
-            tg5.add(task7);
-            tg5.add(task8);
-            tg5.add(task9);
-            tg5.add(tg4);
-
-            tg5.addDependency(task7, task8);
-            tg5.addDependency(task8, task9);
-            tg5.addDependency(task8, tg4);
-            tg5.addDependency(task9, tg4);
-
-            this.taskGraph = tg5;
-            this.taskGraph.setName("Main Graph");
-            this.taskGraph.addStatusListener(this);
-        } catch (Exception e) {
-            logger.error("Unable to create DAG", e);
-        }
-    }
-
-    public void submitDAG() {
-        TaskGraphHandler handler = new TaskGraphHandlerImpl();
-        try {
-            handler.submit(this.taskGraph);
-            logger.debug("TaskGraph submitted");
-        } catch (InvalidSecurityContextException ise) {
-            logger.error("Security Exception");
-            ise.printStackTrace();
-            System.exit(1);
-        } catch (TaskSubmissionException tse) {
-            logger.error("TaskSubmission Exception");
-            tse.printStackTrace();
-            System.exit(1);
-        } catch (IllegalSpecException ispe) {
-            logger.error("Specification Exception");
-            ispe.printStackTrace();
-            System.exit(1);
-        } catch (InvalidServiceContactException isce) {
-            logger.error("Service Contact Exception");
-            isce.printStackTrace();
-            System.exit(1);
-        }
-    }
-
-    private Task prepareTask(String name, String source, String destination)
-            throws Exception {
-        FileTransfer fileTransfer = new FileTransfer(name, source, destination);
-        fileTransfer.prepareTask();
-        Task task = fileTransfer.getFileTransferTask();
-        task.removeStatusListener(fileTransfer);
-        return task;
-    }
-
-    public void statusChanged(StatusEvent event) {
-        ExecutableObject eo = event.getSource();
-        logger.debug(eo.getName());
-        Status status = event.getStatus();
-        logger.debug("Status changed to: " + status.getStatusString());
-
-        // demonstrating "live" task graphs
-        if (status.getStatusCode() == Status.SUBMITTED && !submitted) {
-            submitted = true;
-            try {
-                task6 = prepareTask("Task6",
-                        "gridftp://this.mcs.anl.gov:2811//home/cog/gridfile12",
-                        "gridftp://that.mcs.anl.gov:2811//home/cog/gridfile12");
-                tg5.addDependency(task6, task9);
-                tg5.add(task6);
-            } catch (Exception e) {
-                e.printStackTrace();
-            }
-        }
-
-        if (status.getStatusCode() == Status.COMPLETED
-                || status.getStatusCode() == Status.FAILED) {
-            logger.info("Task Graph Done");
-            // System.exit(1);
-        }
-    }
-
-    public static void main(String arg[]) {
-        try {
-            HierarchicalDAG dag = new HierarchicalDAG();
-            dag.createDAG();
-            dag.submitDAG();
-        } catch (Exception e) {
-            logger.error("Exception caught: ", e);
-        }
-    }
-}
\ No newline at end of file
Index: modules/examples/etc/MANIFEST.MF.tail
===================================================================
--- modules/examples/etc/MANIFEST.MF.tail	(revision 4012)
+++ modules/examples/etc/MANIFEST.MF.tail	(working copy)
@@ -1 +0,0 @@
-
Index: modules/examples/etc/MANIFEST.MF.head
===================================================================
--- modules/examples/etc/MANIFEST.MF.head	(revision 4012)
+++ modules/examples/etc/MANIFEST.MF.head	(working copy)
@@ -1 +0,0 @@
-Manifest-Version: 1.0
Index: modules/examples/build.xml
===================================================================
--- modules/examples/build.xml	(revision 4012)
+++ modules/examples/build.xml	(working copy)
@@ -1,152 +0,0 @@
-<project name="Java CoG Kit" default="dist" basedir=".">
-
-	<property file="project.properties"/>
-	<property name="cog.dir"		value="${basedir}/../../"/>
-	<property name="main.buildfile"	value="${cog.dir}/mbuild.xml"/>
-	<property name="dist.dir" 		value="${cog.dir}/modules/${module.name}/dist/${module.name}-${version}"/>
-	<property name="build.dir" 		value="${cog.dir}/modules/${module.name}/build"/>
-
-    <!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Help                                                            | -->
-    <!-- \_________________________________________________________________/ -->
-	
-    <target name="help">
-        <echo>
-			Available targets:
-            	help:
-					prints out this help message
-					
-            	dist:
-					creates a distribution directory of the 
-					${project} ${long.name}
-					
-            	jar:
-					creates a jar file for the ${project} ${long.name}
-					named ${jar.filename}
-					
-            	javadoc:
-					creates the documentation
-					
-            	clean:
-					removes the compiled classes
-					
-            	distclean:
-					deletes the distribution directory
-
-				all:
-					dist and javadoc
-					
-				deploy.webstart:
-					deploys the module as a webstart application
-					
-				dist.joint:
-					builds everything into one jar file. Should only
-					be used globally (from all)
-
-                fixeol:
-                                        change newlines to the unix standard 
-        </echo>
-    </target>
-
-
-	<!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Dist                                                            | -->
-    <!-- \_________________________________________________________________/ -->
-	
-	<target name="dist">
-		<ant antfile="${main.buildfile}" target="dist"/>
-	</target>
-
-
-	<!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Compile                                                         | -->
-    <!-- \_________________________________________________________________/ -->
-	
-	<target name="compile">
-		<ant antfile="${main.buildfile}" target="compile"/>
-	</target>
-
-	<!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Clean                                                           | -->
-    <!-- \_________________________________________________________________/ -->
-	
-	<target name="clean">
-		<ant antfile="${main.buildfile}" target="clean"/>
-	</target>
-
-
-	<!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Distclean                                                       | -->
-    <!-- \_________________________________________________________________/ -->
-	
-	<target name="distclean">
-		<ant antfile="${main.buildfile}" target="distclean"/>
-	</target>
-
-
-    <!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Jar                                                             | -->
-    <!-- \_________________________________________________________________/ -->
-
-	<target name="jar">
-		<ant antfile="${main.buildfile}" target="jar"/>
-	</target>
-
-
-    <!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | Javadoc                                                         | -->
-    <!-- \_________________________________________________________________/ -->
-
-	<target name="javadoc">
-		<ant antfile="${main.buildfile}" target="javadoc"/>
-	</target>
-
-
-
-	<!--  _________________________________________________________________  -->
-    <!-- /                                                                 \ -->
-    <!-- | PMD                                                             | -->
-    <!-- \_________________________________________________________________/ -->
-
-	<target name="pmd">
-		<ant antfile="${main.buildfile}" target="pmd"/>
-	</target>
-	
-	<target name="deploy.webstart">
-		<ant antfile="${main.buildfile}" target="deploy.webstart"/>
-	</target>
-
-	<target name="replacelibs">
-		<ant antfile="${main.buildfile}" target="replacelibs"/>
-	</target>
-	
-	<target name="webstart.launchers">
-		<ant antfile="${main.buildfile}" target="webstart.launchers"/>
-	</target>
-	
-	<target name="dist.joint">
-		<ant antfile="${main.buildfile}" target="dist.all"/>
-	</target>
-
-	<target name="module.package">
-		<ant antfile="${main.buildfile}" target="module.package"/>
-	</target>
-
-    <!-- ================================================ -->
-    <!-- fixeol                                           -->
-    <!-- ================================================ -->
-
-	<target name="fixeol">
-		<ant antfile="${main.buildfile}" target="fixeol"/>
-	</target>
-
-</project>
-
-



More information about the Swift-commit mailing list