phoenix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jamestay...@apache.org
Subject phoenix git commit: PHOENIX-2820 Investigate why SortMergeJoinIT has a sort in the explain plan
Date Fri, 08 Apr 2016 05:07:58 GMT
Repository: phoenix
Updated Branches:
  refs/heads/master 1e4782187 -> 91800b703


PHOENIX-2820 Investigate why SortMergeJoinIT has a sort in the explain plan


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/91800b70
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/91800b70
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/91800b70

Branch: refs/heads/master
Commit: 91800b703d9879574ac5b3ee6fcfe6dd73af2148
Parents: 1e47821
Author: James Taylor <jtaylor@salesforce.com>
Authored: Thu Apr 7 18:52:52 2016 -0700
Committer: James Taylor <jtaylor@salesforce.com>
Committed: Thu Apr 7 18:52:52 2016 -0700

----------------------------------------------------------------------
 .../org/apache/phoenix/end2end/SortMergeJoinIT.java     |  6 +-----
 .../phoenix/end2end/SubqueryUsingSortMergeJoinIT.java   |  2 --
 .../org/apache/phoenix/compile/GroupByCompiler.java     | 12 ++++++++++++
 3 files changed, 13 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/phoenix/blob/91800b70/phoenix-core/src/it/java/org/apache/phoenix/end2end/SortMergeJoinIT.java
----------------------------------------------------------------------
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SortMergeJoinIT.java b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SortMergeJoinIT.java
index b62acc4..f19b886 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SortMergeJoinIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SortMergeJoinIT.java
@@ -113,8 +113,6 @@ public class SortMergeJoinIT extends BaseHBaseManagedTimeIT {
                 "AND\n" +
                 "    SORT-MERGE-JOIN (INNER) TABLES\n" +
                 "        CLIENT PARALLEL 1-WAY FULL SCAN OVER " + JOIN_ITEM_TABLE_DISPLAY_NAME
+ "\n" +
-                "            SERVER SORTED BY [\"I.item_id\"]\n" +
-                "        CLIENT MERGE SORT\n" +
                 "    AND (SKIP MERGE)\n" +
                 "        CLIENT PARALLEL 1-WAY FULL SCAN OVER " + JOIN_ORDER_TABLE_DISPLAY_NAME
+ "\n" +
                 "            SERVER FILTER BY QUANTITY < 5000\n" +
@@ -134,9 +132,7 @@ public class SortMergeJoinIT extends BaseHBaseManagedTimeIT {
                 "    CLIENT PARALLEL 1-WAY FULL SCAN OVER Join.ItemTable\n" +
                 "AND\n" +
                 "    CLIENT PARALLEL 1-WAY FULL SCAN OVER Join.ItemTable\n" +
-                "        SERVER FILTER BY FIRST KEY ONLY\n" +
-                "        SERVER SORTED BY [\"I2.item_id\"]\n" + 
-                "    CLIENT MERGE SORT"
+                "        SERVER FILTER BY FIRST KEY ONLY"
                 }});
         testCases.add(new String[][] {
                 {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/91800b70/phoenix-core/src/it/java/org/apache/phoenix/end2end/SubqueryUsingSortMergeJoinIT.java
----------------------------------------------------------------------
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SubqueryUsingSortMergeJoinIT.java
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SubqueryUsingSortMergeJoinIT.java
index 6a34c57..f7a798e 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SubqueryUsingSortMergeJoinIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SubqueryUsingSortMergeJoinIT.java
@@ -114,8 +114,6 @@ public class SubqueryUsingSortMergeJoinIT extends BaseHBaseManagedTimeIT
{
                 "        CLIENT MERGE SORT\n" +
                 "    AND\n" +
                 "        CLIENT PARALLEL 1-WAY FULL SCAN OVER " + JOIN_SUPPLIER_TABLE_DISPLAY_NAME
+ "\n" +
-                "            SERVER SORTED BY [\"S.supplier_id\"]\n" + 
-                "        CLIENT MERGE SORT\n" + 
                 "    CLIENT SORTED BY [\"I.item_id\"]\n" +
                 "AND (SKIP MERGE)\n" +
                 "    CLIENT PARALLEL 1-WAY RANGE SCAN OVER " + JOIN_ORDER_TABLE_DISPLAY_NAME
+ " ['000000000000001'] - [*]\n" +

http://git-wip-us.apache.org/repos/asf/phoenix/blob/91800b70/phoenix-core/src/main/java/org/apache/phoenix/compile/GroupByCompiler.java
----------------------------------------------------------------------
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/compile/GroupByCompiler.java b/phoenix-core/src/main/java/org/apache/phoenix/compile/GroupByCompiler.java
index cabe777..ceab2f1 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/compile/GroupByCompiler.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/compile/GroupByCompiler.java
@@ -60,8 +60,14 @@ public class GroupByCompiler {
         private final boolean isOrderPreserving;
         public static final GroupByCompiler.GroupBy EMPTY_GROUP_BY = new GroupBy(new GroupByBuilder())
{
             @Override
+            public GroupBy compile(StatementContext context, TupleProjector tupleProjector)
throws SQLException {
+                return this;
+            }
+            
+            @Override
             public void explain(List<String> planSteps, Integer limit) {
             }
+            
             @Override
             public String getScanAttribName() {
                 return null;
@@ -69,9 +75,15 @@ public class GroupByCompiler {
         };
         public static final GroupByCompiler.GroupBy UNGROUPED_GROUP_BY = new GroupBy(new
GroupByBuilder().setIsOrderPreserving(true)) {
             @Override
+            public GroupBy compile(StatementContext context, TupleProjector tupleProjector)
throws SQLException {
+                return this;
+            }
+
+            @Override
             public void explain(List<String> planSteps, Integer limit) {
                 planSteps.add("    SERVER AGGREGATE INTO SINGLE ROW");
             }
+            
             @Override
             public String getScanAttribName() {
                 return BaseScannerRegionObserver.UNGROUPED_AGG;


Mime
View raw message