|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.oozie.command.wf.ActionXCommand.ActionExecutorContext
public static class ActionXCommand.ActionExecutorContext
Workflow action executor context
Constructor Summary | |
---|---|
ActionXCommand.ActionExecutorContext(WorkflowJobBean workflow,
WorkflowActionBean action,
boolean isRetry,
boolean isUserRetry)
Constructing the ActionExecutorContext, setting the private members and constructing the proto configuration |
Method Summary | |
---|---|
org.apache.oozie.client.WorkflowAction |
getAction()
Returns the workflow action of the given action context |
org.apache.hadoop.fs.Path |
getActionDir()
|
org.apache.hadoop.fs.FileSystem |
getAppFileSystem()
|
String |
getCallbackUrl(String externalStatusVar)
Create the callback URL for the action. |
ELEvaluator |
getELEvaluator()
Return an ELEvaluator with the context injected. |
org.apache.hadoop.conf.Configuration |
getProtoActionConf()
Return a proto configuration for actions with auth properties already set. |
String |
getRecoveryId()
Get the Action Recovery ID. |
String |
getVar(String name)
Get a workflow action variable. |
org.apache.oozie.client.WorkflowJob |
getWorkflow()
Return the workflow job. |
boolean |
isEnded()
Returns whether setEndData has been called or not. |
boolean |
isExecuted()
Returns whether setExecutionData has been called or not. |
boolean |
isRetry()
Return if the executor invocation is a retry or not. |
boolean |
isStarted()
Returns whether setStartData has been called or not. |
boolean |
isUserRetry()
Return if the executor invocation is a user retry or not. |
void |
setEndData(org.apache.oozie.client.WorkflowAction.Status status,
String signalValue)
Set the action end completion information for a completed action. |
void |
setErrorInfo(String str,
String exMsg)
|
void |
setExecutionData(String externalStatus,
Properties actionData)
Set the action execution completion information for an action. |
void |
setExecutionStats(String jsonStats)
Set execution statistics information for a particular action. |
void |
setExternalChildIDs(String externalChildIDs)
Set external child IDs for a particular action (Eg: pig). |
void |
setExternalStatus(String externalStatus)
Sets the external status for the action in context. |
void |
setStartData(String externalId,
String trackerUri,
String consoleUrl)
Set the action tracking information for an successfully started action. |
void |
setStartTime()
Setting the start time of the action |
void |
setVar(String name,
String value)
Set a workflow action variable. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ActionXCommand.ActionExecutorContext(WorkflowJobBean workflow, WorkflowActionBean action, boolean isRetry, boolean isUserRetry)
Method Detail |
---|
public String getCallbackUrl(String externalStatusVar)
ActionExecutor.Context
getCallbackUrl
in interface ActionExecutor.Context
externalStatusVar
- variable for the caller to inject the external status.
public org.apache.hadoop.conf.Configuration getProtoActionConf()
ActionExecutor.Context
getProtoActionConf
in interface ActionExecutor.Context
public org.apache.oozie.client.WorkflowJob getWorkflow()
ActionExecutor.Context
getWorkflow
in interface ActionExecutor.Context
public org.apache.oozie.client.WorkflowAction getAction()
public ELEvaluator getELEvaluator()
ActionExecutor.Context
getELEvaluator
in interface ActionExecutor.Context
public void setVar(String name, String value)
ActionExecutor.Context
setVar
in interface ActionExecutor.Context
name
- variable name.value
- variable value, null
removes the variable.public String getVar(String name)
ActionExecutor.Context
getVar
in interface ActionExecutor.Context
name
- variable name.
null
if not set.public void setStartData(String externalId, String trackerUri, String consoleUrl)
ActionExecutor.Context
setStartData
in interface ActionExecutor.Context
externalId
- the action external ID.trackerUri
- the action tracker URI.consoleUrl
- the action console URL.public void setStartTime()
public void setExecutionData(String externalStatus, Properties actionData)
ActionExecutor.Context
WorkflowAction.Status.DONE
setExecutionData
in interface ActionExecutor.Context
externalStatus
- the action external end status.actionData
- the action data on completion, null
if none.public void setExecutionStats(String jsonStats)
ActionExecutor.Context
WorkflowAction.Status.DONE
setExecutionStats
in interface ActionExecutor.Context
jsonStats
- the JSON string representation of the stats.public void setExternalChildIDs(String externalChildIDs)
ActionExecutor.Context
WorkflowAction.Status.DONE
setExternalChildIDs
in interface ActionExecutor.Context
externalChildIDs
- the external child IDs as a comma-delimited string.public void setEndData(org.apache.oozie.client.WorkflowAction.Status status, String signalValue)
ActionExecutor.Context
setEndData
in interface ActionExecutor.Context
status
- the action end status, it can be WorkflowAction.Status.OK
or
WorkflowAction.Status.ERROR
.signalValue
- the action external end status.public boolean isRetry()
ActionExecutor.Context
isRetry
in interface ActionExecutor.Context
public boolean isUserRetry()
public boolean isStarted()
public boolean isExecuted()
public boolean isEnded()
public void setExternalStatus(String externalStatus)
ActionExecutor.Context
setExternalStatus
in interface ActionExecutor.Context
externalStatus
- the external status.public String getRecoveryId()
ActionExecutor.Context
getRecoveryId
in interface ActionExecutor.Context
public org.apache.hadoop.fs.Path getActionDir() throws HadoopAccessorException, IOException, URISyntaxException
getActionDir
in interface ActionExecutor.Context
HadoopAccessorException
IOException
URISyntaxException
public org.apache.hadoop.fs.FileSystem getAppFileSystem() throws HadoopAccessorException, IOException, URISyntaxException
getAppFileSystem
in interface ActionExecutor.Context
HadoopAccessorException
IOException
URISyntaxException
public void setErrorInfo(String str, String exMsg)
setErrorInfo
in interface ActionExecutor.Context
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |