|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.Packager
org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.MultiQueryPackager
public class MultiQueryPackager
The package operator that packages the globally rearranged tuples into output format as required by multi-query de-multiplexer.
This operator is used when merging multiple Map-Reduce splittees into a Map-only splitter during multi-query optimization. The package operators of the reduce plans of the splittees form an indexed package list inside this operator. When this operator receives an input, it extracts the index from the key and calls the corresponding package to get the output data.
Due to the recursive nature of multi-query optimization, this operator may be contained in another multi-query packager.
The successor of this operator must be a PODemux operator which knows how to consume the output of this operator.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.Packager |
---|
Packager.PackageType |
Field Summary |
---|
Fields inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.Packager |
---|
bags, distinct, illustrator, isKeyCompound, isKeyTuple, keyInfo, mBagFactory, mTupleFactory, parent, readOnce |
Constructor Summary | |
---|---|
MultiQueryPackager()
|
Method Summary | |
---|---|
void |
addIsKeyWrappedList(List<Boolean> lst)
Adds a list of IsKeyWrapped boolean values |
void |
addPackager(Packager pkgr)
Appends the specified package object to the end of the package list. |
void |
addPackager(Packager pkgr,
byte mapKeyType)
Appends the specified package object to the end of the package list. |
List<Boolean> |
getIsKeyWrappedList()
Returns the list of booleans that indicates if the key needs to unwrapped for the corresponding plan. |
Result |
getNext()
Constructs the output tuple from the inputs. |
int |
getNumInputs(byte index)
|
List<Packager> |
getPackagers()
Returns the list of packages. |
Tuple |
getValueTuple(PigNullableWritable keyWritable,
NullableTuple ntup,
int index)
|
boolean |
isInCombiner()
|
boolean |
isSameMapKeyType()
|
void |
setInCombiner(boolean inCombiner)
|
void |
setSameMapKeyType(boolean sameMapKeyType)
|
Methods inherited from class org.apache.pig.backend.hadoop.executionengine.physicalLayer.relationalOperators.Packager |
---|
attachInput, checkBagType, clone, detachInput, getBag, getIllustrator, getInner, getKey, getKey, getKeyAsTuple, getKeyInfo, getKeyTuple, getKeyType, getNumInputs, getPackageType, illustratorMarkup, illustratorMarkup2, isDistinct, name, numberOfEquivalenceClasses, setDistinct, setIllustrator, setInner, setKeyCompound, setKeyInfo, setKeyTuple, setKeyType, setNumInputs, setPackageType, setParent, setUseSecondaryKey, starMarkup |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MultiQueryPackager()
Method Detail |
---|
public void addPackager(Packager pkgr)
pack
- package to be appended to the listpublic void addPackager(Packager pkgr, byte mapKeyType)
pack
- package to be appended to the listmapKeyType
- the map key type associated with the packagepublic List<Packager> getPackagers()
public Result getNext() throws ExecException
The output is consumed by for the demultiplexer operator (PODemux) in the format (key, {bag of tuples}) where key is an indexed WritableComparable, not the wrapped value as a pig type.
getNext
in class Packager
ExecException
public List<Boolean> getIsKeyWrappedList()
public void addIsKeyWrappedList(List<Boolean> lst)
lst
- the list of boolean values to addpublic void setInCombiner(boolean inCombiner)
public boolean isInCombiner()
public void setSameMapKeyType(boolean sameMapKeyType)
public boolean isSameMapKeyType()
public int getNumInputs(byte index)
getNumInputs
in class Packager
public Tuple getValueTuple(PigNullableWritable keyWritable, NullableTuple ntup, int index) throws ExecException
getValueTuple
in class Packager
ExecException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |