drill-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject [33/50] [abbrv] drill git commit: MD-711: Enable support for UNION types in Drill-MapRDB plugin
Date Tue, 13 Sep 2016 01:32:20 GMT
MD-711: Enable support for UNION types in Drill-MapRDB plugin


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

Branch: refs/heads/master
Commit: b1218f318806c96a8e4e28f6298d17e180fd09eb
Parents: 8844a73
Author: Smidth Panchamia <spanchamia@mapr.com>
Authored: Thu Feb 25 16:46:38 2016 +0000
Committer: Aditya Kishore <adi@apache.org>
Committed: Fri Sep 9 10:08:37 2016 -0700

----------------------------------------------------------------------
 .../drill/exec/store/maprdb/json/MaprDBJsonRecordReader.java    | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/drill/blob/b1218f31/contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/maprdb/json/MaprDBJsonRecordReader.java
----------------------------------------------------------------------
diff --git a/contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/maprdb/json/MaprDBJsonRecordReader.java
b/contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/maprdb/json/MaprDBJsonRecordReader.java
index 0f01662..1d1ef44 100644
--- a/contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/maprdb/json/MaprDBJsonRecordReader.java
+++ b/contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/maprdb/json/MaprDBJsonRecordReader.java
@@ -31,6 +31,7 @@ import org.apache.drill.common.exceptions.ExecutionSetupException;
 import org.apache.drill.common.exceptions.UserException;
 import org.apache.drill.common.expression.PathSegment;
 import org.apache.drill.common.expression.SchemaPath;
+import org.apache.drill.exec.ExecConstants;
 import org.apache.drill.exec.ops.FragmentContext;
 import org.apache.drill.exec.ops.OperatorContext;
 import org.apache.drill.exec.ops.OperatorStats;
@@ -86,6 +87,7 @@ public class MaprDBJsonRecordReader extends AbstractRecordReader {
 
   private boolean includeId;
   private boolean idOnly;
+  private boolean unionEnabled;
 
   public MaprDBJsonRecordReader(MapRDBSubScanSpec subScanSpec,
       List<SchemaPath> projectedColumns, FragmentContext context) {
@@ -97,6 +99,7 @@ public class MaprDBJsonRecordReader extends AbstractRecordReader {
     idOnly    = false;
     condition = com.mapr.db.impl.ConditionImpl.parseFrom(ByteBufs.wrap(subScanSpec.getSerializedFilter()));
     setColumns(projectedColumns);
+    unionEnabled = context.getOptions().getOption(ExecConstants.ENABLE_UNION_TYPE);
   }
 
   @Override
@@ -137,7 +140,7 @@ public class MaprDBJsonRecordReader extends AbstractRecordReader {
 
   @Override
   public void setup(OperatorContext context, OutputMutator output) throws ExecutionSetupException
{
-    this.writer = new VectorContainerWriter(output);
+    this.writer = new VectorContainerWriter(output, unionEnabled);
     this.operatorContext = context;
 
     try {


Mime
View raw message