tassl.application.workflow
Class WorkflowManager

java.lang.Object
  extended by java.lang.Thread
      extended by tassl.application.workflow.WorkflowManager
All Implemented Interfaces:
java.lang.Runnable

public class WorkflowManager
extends java.lang.Thread


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Method Summary
 boolean contactSubscriber(java.lang.String address, int port, java.lang.String message)
          Send messages to the Subscriber.
protected  java.util.HashMap getSupportedApps()
           
static void main(java.lang.String[] args)
           
 void run()
           
 void scheduleNonBlockingStages(java.util.HashMap<java.lang.String,java.util.List<java.lang.String>> wflIdStageList)
          Schedule partial stages (after non-blocking transition) They will be added to the original stage in the scheduling
 boolean scheduleStages(java.lang.String wflId)
          Find stages that are ready to execute, generate their tasks by calling the taskgenerator(workflowmaster) and schedule them by calling the autonomic scheduler
 boolean sendInfo(java.lang.String address, int port, java.lang.String command, java.util.List param)
           
protected  boolean setStageDone(java.lang.String workflowId, java.lang.String stageId, java.lang.String latestStage, boolean iterate)
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

run

public void run()
Specified by:
run in interface java.lang.Runnable
Overrides:
run in class java.lang.Thread

getSupportedApps

protected java.util.HashMap getSupportedApps()
                                      throws java.io.IOException
Throws:
java.io.IOException

setStageDone

protected boolean setStageDone(java.lang.String workflowId,
                               java.lang.String stageId,
                               java.lang.String latestStage,
                               boolean iterate)
Parameters:
workflowId - id of affected workflow
stageId - stage that has to be set to done
latestStage - same as stageId parameter or the id of the final stage in a non-blocking transition series
iterate -
Returns:

contactSubscriber

public boolean contactSubscriber(java.lang.String address,
                                 int port,
                                 java.lang.String message)
Send messages to the Subscriber. It uses a PrintWriter for that.

Parameters:
address -
port -
message - The message is a string. If multiple lines are sent, they should be separated by the '\n' character
Returns:

scheduleStages

public boolean scheduleStages(java.lang.String wflId)
Find stages that are ready to execute, generate their tasks by calling the taskgenerator(workflowmaster) and schedule them by calling the autonomic scheduler

Parameters:
wflId -
Returns:
true if there are stages to execute

scheduleNonBlockingStages

public void scheduleNonBlockingStages(java.util.HashMap<java.lang.String,java.util.List<java.lang.String>> wflIdStageList)
Schedule partial stages (after non-blocking transition) They will be added to the original stage in the scheduling

Parameters:
wflIdStageList -

sendInfo

public boolean sendInfo(java.lang.String address,
                        int port,
                        java.lang.String command,
                        java.util.List param)

main

public static void main(java.lang.String[] args)