hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kevin Wilfong" <kevinwilf...@fb.com>
Subject Review Request: Make compression used between map reduce tasks configurable.
Date Tue, 16 Aug 2011 00:24:28 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/1516/
-----------------------------------------------------------

Review request for hive and Ning Zhang.


Summary
-------

I added a field to MapredWork and MapredLocalWork which indicates whether it is intermediate
or not.  By intermediate, I mean that if the query is an insert, there is at least one other
map reduce task that is guaranteed to happen before the move.  If the query is not an insert,
intermediate applies to them all.  I determine this by defaulting the flag to true, and setting
it to false when the tasks to move the data into a table or file are generated.

If the work for a map reduce task (local or otherwise) is intermediate, then we set the compression
to be used on the output of the reduce to some configured value, the default is LZO.


This addresses bug HIVE-2374.
    https://issues.apache.org/jira/browse/HIVE-2374


Diffs
-----

  trunk/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java 1157918 
  trunk/conf/hive-default.xml 1157918 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/ExecDriver.java 1157918 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/exec/MapredLocalTask.java 1157918 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/optimizer/GenMRFileSink1.java 1157918 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/MapredLocalWork.java 1157918 
  trunk/ql/src/java/org/apache/hadoop/hive/ql/plan/MapredWork.java 1157918 
  trunk/ql/src/test/org/apache/hadoop/hive/ql/exec/TestExecDriver.java 1157918 
  trunk/ql/src/test/org/apache/hadoop/hive/ql/hooks/VerifyIsIntermediateHook.java PRE-CREATION

  trunk/ql/src/test/queries/clientpositive/intermediate_compression.q PRE-CREATION 
  trunk/ql/src/test/results/clientpositive/intermediate_compression.q.out PRE-CREATION 

Diff: https://reviews.apache.org/r/1516/diff


Testing
-------

I added a test query and hook to verify that the is intermediate flag is set properly in the
MapredWork/MapredLocalWork.

I also added a test to TestExecDriver which checks that the correct compression is used on
the output of the reduce for each value of the is intermediate flag.


Thanks,

Kevin


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message