Skip to content

Commit 3d1b2a6

Browse files
committed
[KYUUBI #360] fix ut
1 parent eda3e59 commit 3d1b2a6

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

kyuubi-common/src/main/scala/org/apache/kyuubi/util/ThriftUtils.scala

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ object ThriftUtils {
2929
}
3030
}
3131

32-
val EMPTY_ROW_SET = new TRowSet(0, new java.util.ArrayList[TRow](0))
32+
def newEmptyRowSet: TRowSet = new TRowSet(0, new java.util.ArrayList[TRow](0))
33+
34+
val EMPTY_ROW_SET: TRowSet = newEmptyRowSet
3335

3436
}

kyuubi-common/src/test/scala/org/apache/kyuubi/operation/NoopOperation.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class NoopOperation(typ: OperationType, session: Session, shouldFail: Boolean =
7676

7777
override def getNextRowSet(order: FetchOrientation, rowSetSize: Int): TRowSet = {
7878
val col = TColumn.stringVal(new TStringColumn(Seq(typ.toString).asJava, ByteBuffer.allocate(0)))
79-
val tRowSet = ThriftUtils.EMPTY_ROW_SET
79+
val tRowSet = ThriftUtils.newEmptyRowSet
8080
tRowSet.addToColumns(col)
8181
tRowSet
8282
}

0 commit comments

Comments
 (0)