From ec28760decb9bd95ac6d3acf3eae1325c7ea9a38 Mon Sep 17 00:00:00 2001 From: Yuan Date: Fri, 8 Jan 2021 08:38:49 +0800 Subject: [PATCH] [NSE-15]fix unexpected exception (#16) * fix unexpected exception Signed-off-by: Yuan Zhou * do not early close sorter Signed-off-by: Yuan Zhou --- .../com/intel/oap/expression/ColumnarSortMergeJoin.scala | 4 ++++ .../main/scala/com/intel/oap/expression/ColumnarSorter.scala | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/core/src/main/scala/com/intel/oap/expression/ColumnarSortMergeJoin.scala b/core/src/main/scala/com/intel/oap/expression/ColumnarSortMergeJoin.scala index 7447e4b2c..b01dd688b 100644 --- a/core/src/main/scala/com/intel/oap/expression/ColumnarSortMergeJoin.scala +++ b/core/src/main/scala/com/intel/oap/expression/ColumnarSortMergeJoin.scala @@ -233,6 +233,10 @@ object ColumnarSortMergeJoin extends Logging { val lkeyProjectOrdinalList = new ListBuffer[Int]() val lkeyFieldList: List[Field] = leftKeys.toList.zipWithIndex.map { case (expr, i) => { + //TODO(): fix this workaround + if (expr.isInstanceOf[AttributeReference] && expr.asInstanceOf[AttributeReference].name == "none") { + return + } val (nativeNode, returnType) = ConverterUtils.getColumnarFuncNode(expr) if (s"${nativeNode.toProtobuf}".contains("none#")) { throw new UnsupportedOperationException( diff --git a/core/src/main/scala/com/intel/oap/expression/ColumnarSorter.scala b/core/src/main/scala/com/intel/oap/expression/ColumnarSorter.scala index a0ecd638f..0fe9b0389 100644 --- a/core/src/main/scala/com/intel/oap/expression/ColumnarSorter.scala +++ b/core/src/main/scala/com/intel/oap/expression/ColumnarSorter.scala @@ -157,7 +157,8 @@ class ColumnarSorter( has_next = sort_iterator.hasNext() if (has_next == false) { - close() + //TODO(): should try to close sorter + //close() } return has_next