|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.pig.impl.plan.Operator<PhyPlanVisitor>
org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator
org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.PODemux
public class PODemux
The MapReduce Demultiplexer operator.
This operator is used when merging multiple Map-Reduce splittees into a Map-only splitter during multi-query optimization. The reduce physical plans of the splittees become the inner plans of this operator.
Due to the recursive nature of multi-query optimization, this operator may be contained in another demux operator.
The predecessor of this operator must be a POMultiQueryPackage operator which passes the index (indicating which inner reduce plan to run) along with other data to this operator.
Field Summary |
---|
Fields inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator |
---|
dummyBag, dummyBool, dummyDBA, dummyDouble, dummyFloat, dummyInt, dummyLong, dummyMap, dummyString, dummyTuple, input, inputAttached, inputs, lineageTracer, outputs, parentPlan, pigLogger, reporter, requestedParallelism, res, resultType |
Fields inherited from class org.apache.pig.impl.plan.Operator |
---|
mKey |
Constructor Summary | |
---|---|
PODemux(OperatorKey k)
Constructs an operator with the specified key. |
|
PODemux(OperatorKey k,
int rp)
Constructs an operator with the specified key and degree of parallelism. |
|
PODemux(OperatorKey k,
int rp,
List<PhysicalOperator> inp)
Constructs an operator with the specified key, degree of parallelism and inputs. |
|
PODemux(OperatorKey k,
List<PhysicalOperator> inp)
Constructs an operator with the specified key and inputs. |
Method Summary | |
---|---|
void |
addPlan(PhysicalPlan inPlan,
byte mapKeyType)
Appends the specified plan at the end of the list. |
int |
getBaseIndex()
Returns the base index of this demux |
Result |
getNext(Tuple t)
|
List<PhysicalPlan> |
getPlans()
Returns the list of inner plans. |
boolean |
isInCombiner()
Returns a flag indicating if this operator is in a combiner. |
boolean |
isSameMapKeyType()
Returns a flag indicating if all inner plans have the same map key type |
String |
name()
|
void |
setBaseIndex(int idx)
Sets the base index of this demux. |
void |
setInCombiner(boolean inCombiner)
Sets a flag indicating if this operator is in a combiner. |
void |
setSameMapKeyType(boolean sameMapKeyType)
Sets a flag indicating if all inner plans have the same map key type. |
boolean |
supportsMultipleInputs()
Indicates whether this operator supports multiple inputs. |
boolean |
supportsMultipleOutputs()
Indicates whether this operator supports multiple outputs. |
void |
visit(PhyPlanVisitor v)
Visit this node with the provided visitor. |
Methods inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator |
---|
attachInput, clone, cloneHelper, detachInput, getInputs, getLogger, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getPigLogger, getRequestedParallelism, getResultType, isBlocking, isInputAttached, processInput, reset, setInputs, setLineageTracer, setParentPlan, setPigLogger, setReporter, setRequestedParallelism, setResultType |
Methods inherited from class org.apache.pig.impl.plan.Operator |
---|
compareTo, equals, getOperatorKey, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public PODemux(OperatorKey k)
k
- the operator keypublic PODemux(OperatorKey k, int rp)
k
- the operator keyrp
- the degree of parallelism requestedpublic PODemux(OperatorKey k, List<PhysicalOperator> inp)
k
- the operator keyinp
- the inputs that this operator will read data frompublic PODemux(OperatorKey k, int rp, List<PhysicalOperator> inp)
k
- the operator keyrp
- the degree of parallelism requestedinp
- the inputs that this operator will read data fromMethod Detail |
---|
public void visit(PhyPlanVisitor v) throws VisitorException
Operator
visit
in class PhysicalOperator
v
- Visitor to visit with.
VisitorException
- if the visitor has a problem.public String name()
name
in class Operator<PhyPlanVisitor>
public boolean supportsMultipleInputs()
Operator
supportsMultipleInputs
in class Operator<PhyPlanVisitor>
public boolean supportsMultipleOutputs()
Operator
supportsMultipleOutputs
in class Operator<PhyPlanVisitor>
public void setBaseIndex(int idx)
idx
- the base indexpublic int getBaseIndex()
public List<PhysicalPlan> getPlans()
public void addPlan(PhysicalPlan inPlan, byte mapKeyType)
inPlan
- plan to be appended to the inner plan listpublic Result getNext(Tuple t) throws ExecException
getNext
in class PhysicalOperator
ExecException
public void setSameMapKeyType(boolean sameMapKeyType)
sameMapKeyType
- true if all inner plans have
the same map key type; otherwise falsepublic boolean isSameMapKeyType()
public void setInCombiner(boolean inCombiner)
inCombiner
- true if this operator is in
a combiner; false if this operator is in a reducerpublic boolean isInCombiner()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |