Review Board 1.7.22


DRILL-156: union pop

Review Request #12960 - Created July 26, 2013 and updated

Lisen Mu
Reviewers
drill-git
drill-git
union pop.
org.apache.drill.exec.physical.impl.union.TestSimpleUnion
From 15a9b42c4694774b827c421616fc8f456139af66 Mon
From: immars <immars@gmail.com>
Date: Tue, 30 Jul 2013 10:17:34 +0800
Subject: [PATCH 2/2] addressing review

sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/AbstractMultiple.java
New File

    
   
1
package org.apache.drill.exec.physical.base;

    
   
2

   

    
   
3
import com.google.common.collect.Iterators;

    
   
4

   

    
   
5
import java.util.Iterator;

    
   
6

   

    
   
7
/**

    
   
8
 * Describes an operator that expects more than one children operators as its input.

    
   
9
 */

    
   
10
public abstract class AbstractMultiple extends AbstractBase{

    
   
11
  static final org.slf4j.Logger logger = org.slf4j.LoggerFactory.getLogger(AbstractMultiple.class);  

    
   
12
  

    
   
13
  protected final PhysicalOperator[] children;

    
   
14

   

    
   
15
  protected AbstractMultiple(PhysicalOperator[] children) {

    
   
16
    this.children = children;

    
   
17
  }

    
   
18

   

    
   
19
  public PhysicalOperator[] getChildren() {

    
   
20
    return children;

    
   
21
  }

    
   
22
  

    
   
23
  @Override

    
   
24
  public Iterator<PhysicalOperator> iterator() {

    
   
25
    return Iterators.forArray(children);

    
   
26
  }

    
   
27
  

    
   
28
  public Size getSize() {

    
   
29
    Size size = new Size(0,0);

    
   
30
    for(PhysicalOperator child:children){

    
   
31
      size.add(child.getSize());

    
   
32
    }

    
   
33
    return size;

    
   
34
  }

    
   
35
    

    
   
36
}
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/AbstractPhysicalVisitor.java
Revision 3b58803 New Change
 
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/PhysicalVisitor.java
Revision 8e09e3a New Change
 
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/config/Union.java
New File
 
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/ImplCreator.java
Revision 2ce5c28 New Change
 
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/ScreenCreator.java
Revision 9b31407 New Change
 
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/union/UnionBatchCreator.java
New File
 
sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/union/UnionRecordBatch.java
New File
 
sandbox/prototype/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/TestSimpleFragmentRun.java
Revision 6587237 New Change
 
sandbox/prototype/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/filter/TestSimpleFilter.java
Revision afb0b3a New Change
 
sandbox/prototype/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/union/TestSimpleUnion.java
New File
 
sandbox/prototype/exec/java-exec/src/test/resources/filter/test1.json
Revision 4f82145 New Change
 
sandbox/prototype/exec/java-exec/src/test/resources/union/test1.json
New File
 
  1. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/AbstractMultiple.java: Loading...
  2. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/AbstractPhysicalVisitor.java: Loading...
  3. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/base/PhysicalVisitor.java: Loading...
  4. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/config/Union.java: Loading...
  5. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/ImplCreator.java: Loading...
  6. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/ScreenCreator.java: Loading...
  7. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/union/UnionBatchCreator.java: Loading...
  8. sandbox/prototype/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/union/UnionRecordBatch.java: Loading...
  9. sandbox/prototype/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/TestSimpleFragmentRun.java: Loading...
  10. sandbox/prototype/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/filter/TestSimpleFilter.java: Loading...
  11. sandbox/prototype/exec/java-exec/src/test/java/org/apache/drill/exec/physical/impl/union/TestSimpleUnion.java: Loading...
  12. sandbox/prototype/exec/java-exec/src/test/resources/filter/test1.json: Loading...
  13. sandbox/prototype/exec/java-exec/src/test/resources/union/test1.json: Loading...