|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
@InterfaceAudience.Public @InterfaceStability.Evolving public interface ExecutionEngine
The main interface bridging the front end and back end of Pig. This allows Pig to be ran on multiple Execution Engines, and not being limited to only Hadoop MapReduce. The ExecutionEngines must support the following methods as these are all the access points for the Pig frontend for processing. Traditionally there is one ExecutionEngine created per processing job, but this is not necessary. The ExecutionEngine instance comes from the ExecType, and it can choose to reuse ExecutionEngine instances. All specifications for methods are listed below as well as expected behavior, and the ExecutionEngine must conform to these.
Method Summary | |
---|---|
void |
explain(LogicalPlan lp,
PigContext pc,
PrintStream ps,
String format,
boolean verbose,
File dir,
String suffix)
This method handles the backend processing of the Explain command. |
Properties |
getConfiguration()
Returns the Properties representation of the ExecutionEngine configuration. |
DataStorage |
getDataStorage()
Returns the DataStorage the ExecutionEngine is using. |
ExecutableManager |
getExecutableManager()
Returns the ExecutableManager to be used in Pig Streaming. |
void |
init()
This method is responsible for the initialization of the ExecutionEngine. |
PigStats |
instantiatePigStats()
Creates a PigStats object which will be accessible as a ThreadLocal variable inside the PigStats class. |
ScriptState |
instantiateScriptState()
Creates a ScriptState object which will be accessible as a ThreadLocal variable inside the ScriptState class. |
void |
killJob(String jobID)
This method is called when a user requests to kill a job associated with the given job id. |
PigStats |
launchPig(LogicalPlan lp,
String grpName,
PigContext pc)
This method is responsible for the actual execution of a LogicalPlan. |
void |
setConfiguration(Properties newConfiguration)
Responsible for updating the properties for the ExecutionEngine. |
void |
setProperty(String property,
String value)
Responsible for setting a specific property and value. |
Method Detail |
---|
void init() throws ExecException
ExecException
void setConfiguration(Properties newConfiguration) throws ExecException
newConfiguration
- -- Properties object holding all configuration vals
ExecException
void setProperty(String property, String value)
property
- to updatevalue
- to set for propertyProperties getConfiguration()
PigStats launchPig(LogicalPlan lp, String grpName, PigContext pc) throws FrontendException, ExecException
lp
- -- plan to compilegrpName
- -- group name for submissionpc
- -- context for execution
ExecException
FrontendException
void explain(LogicalPlan lp, PigContext pc, PrintStream ps, String format, boolean verbose, File dir, String suffix) throws PlanException, VisitorException, IOException
lp
- -- plan to explainpc
- -- context for explain processingps
- -- print stream to write all output to (if dir param is null)format
- -- format to print explainverbose
- dir
- -- directory to write output to. if not null, write to filessuffix
- -- if writing to files, suffix to be used for each file
PlanException
VisitorException
IOException
DataStorage getDataStorage()
ScriptState instantiateScriptState()
PigStats instantiatePigStats()
ExecutableManager getExecutableManager()
void killJob(String jobID) throws BackendException
BackendException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |