public class ResourceRunner extends AbstractEngineRunnerBase implements CoreMetKeys, WorkflowStatus
WorkflowTask
to the Resource Manager.Modifier and Type | Field and Description |
---|---|
protected static String |
DEFAULT_QUEUE_NAME |
protected XmlRpcResourceManagerClient |
rClient |
instRep
JOB_ID, PROCESSING_NODE, QUEUE_NAME, TASK_ID, TASK_LOAD, WORKFLOW_ID, WORKFLOW_INST_ID, WORKFLOW_MANAGER_URL, WORKFLOW_NAME
CREATED, ERROR, FINISHED, METADATA_MISSING, PAUSED, QUEUED, RESMGR_SUBMIT, STARTED
Constructor and Description |
---|
ResourceRunner(URL resUrl,
WorkflowInstanceRepository instRep) |
Modifier and Type | Method and Description |
---|---|
void |
execute(TaskProcessor taskProcessor)
Executes a
TaskProcessor on an execution substrate. |
boolean |
hasOpenSlots(TaskProcessor taskProcessor)
Decides whether or not there are available slots within this runner
to execute the provided
TaskProcessor . |
protected boolean |
safeCheckJobComplete(String jobId) |
void |
setInstanceRepository(WorkflowInstanceRepository instRep) |
void |
shutdown()
Shuts this runner down and frees its resources.
|
protected boolean |
stopJob(String jobId) |
getLifecycle, getTaskFromProcessor, persist
protected static final String DEFAULT_QUEUE_NAME
protected XmlRpcResourceManagerClient rClient
public ResourceRunner(URL resUrl, WorkflowInstanceRepository instRep)
public void execute(TaskProcessor taskProcessor)
EngineRunner
TaskProcessor
on an execution substrate. Ideally there
will only ever be two of these substrates, one for local execution, and
another for communication with the Resource Manager.execute
in class EngineRunner
taskProcessor
- The TaskProcessor
to instantiate and execute.public void shutdown()
EngineRunner
shutdown
in class EngineRunner
public boolean hasOpenSlots(TaskProcessor taskProcessor)
EngineRunner
TaskProcessor
.hasOpenSlots
in class EngineRunner
taskProcessor
- The TaskProcessor
to execute.public void setInstanceRepository(WorkflowInstanceRepository instRep)
setInstanceRepository
in class EngineRunner
protected boolean safeCheckJobComplete(String jobId)
protected boolean stopJob(String jobId)
Copyright © 1999–2017 Apache OODT. All rights reserved.