org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators
Class POPartitionRearrange

java.lang.Object
  extended by org.apache.pig.impl.plan.Operator<PhyPlanVisitor>
      extended by org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator
          extended by org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POLocalRearrange
              extended by org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POPartitionRearrange
All Implemented Interfaces:
Serializable, Cloneable, Comparable<Operator>, Illustrable

public class POPartitionRearrange
extends POLocalRearrange

The partition rearrange operator is a part of the skewed join implementation. It has an embedded physical plan that generates tuples of the form (inpKey,reducerIndex,(indxed inp Tuple)).

See Also:
Serialized Form

Field Summary
protected static BagFactory mBagFactory
           
 
Fields inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POLocalRearrange
index, isCross, keyType, leafOps, mainKeyType, mFakeTuple, mIsDistinct, mTupleFactory, plans, secondaryKeyType, secondaryLeafOps, secondaryPlans
 
Fields inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator
alias, dummyBag, dummyBool, dummyDBA, dummyDouble, dummyFloat, dummyInt, dummyLong, dummyMap, dummyString, dummyTuple, illustrator, input, inputAttached, inputs, lineageTracer, outputs, parentPlan, pigLogger, reporter, requestedParallelism, res, resultType
 
Fields inherited from class org.apache.pig.impl.plan.Operator
mKey
 
Constructor Summary
POPartitionRearrange(OperatorKey k)
           
POPartitionRearrange(OperatorKey k, int rp)
           
POPartitionRearrange(OperatorKey k, int rp, List<PhysicalOperator> inp)
           
POPartitionRearrange(OperatorKey k, List<PhysicalOperator> inp)
           
 
Method Summary
 POPartitionRearrange clone()
          Make a deep copy of this operator.
protected  DataBag constructPROutput(List<Result> resLst, Tuple value)
           
 Result getNext(Tuple t)
          Calls getNext on the generate operator inside the nested physical plan.
 PigContext getPigContext()
           
 String name()
           
 void setPigContext(PigContext pigContext)
           
 
Methods inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.POLocalRearrange
attachInput, constructLROutput, getIndex, getKeyFromResult, getKeyType, getPlans, getProjectedColsMap, getSecondaryProjectedColsMap, illustratorMarkup, isCross, isDistinct, isKeyTuple, isProjectStar, isSecondaryKeyTuple, isSecondaryProjectStar, setCross, setDistinct, setIndex, setKeyType, setMultiQueryIndex, setPlans, setPlansFromCombiner, setSecondaryPlans, setStripKeyFromValue, setUseSecondaryKey, supportsMultipleInputs, supportsMultipleOutputs, visit
 
Methods inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.PhysicalOperator
cloneHelper, detachInput, getAlias, getAliasString, getDummy, getIllustrator, getInputs, getLogger, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getNext, getPigLogger, getRequestedParallelism, getResultType, isAccumStarted, isAccumulative, isBlocking, isInputAttached, processInput, reset, setAccumEnd, setAccumStart, setAccumulative, setAlias, setIllustrator, setInputs, setParentPlan, setPigLogger, setReporter, setRequestedParallelism, setResultType
 
Methods inherited from class org.apache.pig.impl.plan.Operator
compareTo, equals, getOperatorKey, getProjectionMap, hashCode, regenerateProjectionMap, rewire, toString, unsetProjectionMap
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

mBagFactory

protected static final BagFactory mBagFactory
Constructor Detail

POPartitionRearrange

public POPartitionRearrange(OperatorKey k)

POPartitionRearrange

public POPartitionRearrange(OperatorKey k,
                            int rp)

POPartitionRearrange

public POPartitionRearrange(OperatorKey k,
                            List<PhysicalOperator> inp)

POPartitionRearrange

public POPartitionRearrange(OperatorKey k,
                            int rp,
                            List<PhysicalOperator> inp)
Method Detail

name

public String name()
Overrides:
name in class POLocalRearrange

getNext

public Result getNext(Tuple t)
               throws ExecException
Calls getNext on the generate operator inside the nested physical plan. Converts the generated tuple into the proper format, i.e, (key,indexedTuple(value))

Overrides:
getNext in class POLocalRearrange
Throws:
ExecException

constructPROutput

protected DataBag constructPROutput(List<Result> resLst,
                                    Tuple value)
                             throws ExecException
Throws:
ExecException

setPigContext

public void setPigContext(PigContext pigContext)
Parameters:
pigContext - the pigContext to set

getPigContext

public PigContext getPigContext()
Returns:
the pigContext

clone

public POPartitionRearrange clone()
                           throws CloneNotSupportedException
Make a deep copy of this operator.

Overrides:
clone in class POLocalRearrange
Throws:
CloneNotSupportedException
See Also:
Do not use the clone method directly. Operators are cloned when logical plans are cloned using {@link LogicalPlanCloner}


Copyright © ${year} The Apache Software Foundation