Skip to content

Commit

Permalink
[FLINK-16477][hotfix][test] Add SerialVersionUID to the test Class to…
Browse files Browse the repository at this point in the history
… get stable functionIdentifier
  • Loading branch information
hequn8128 committed Mar 11, 2020
1 parent 2a4a2e2 commit 5fa4259
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -132,12 +132,12 @@ Calc(select=[c, s])
<![CDATA[
LogicalCorrelate(correlation=[$cor0], joinType=[inner], requiredColumns=[{}])
:- LogicalTableScan(table=[[default_catalog, default_database, MyTable, source: [TestTableSource(a, b, c)]]])
+- LogicalTableFunctionScan(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$8c725e0df55184e548883d4b29709539($0, $1)], rowType=[RecordType(INTEGER x, INTEGER y)], elementType=[class [Ljava.lang.Object;])
+- LogicalTableFunctionScan(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$2db9292ec254f97ef03c249bd4e602fd($0, $1)], rowType=[RecordType(INTEGER x, INTEGER y)], elementType=[class [Ljava.lang.Object;])
]]>
</Resource>
<Resource name="planAfter">
<![CDATA[
PythonCorrelate(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$8c725e0df55184e548883d4b29709539($0, $1)], correlate=[table(MockPythonTableFunction(a,b))], select=[a,b,c,x,y], rowType=[RecordType(INTEGER a, INTEGER b, VARCHAR(2147483647) c, INTEGER x, INTEGER y)], joinType=[INNER])
PythonCorrelate(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$2db9292ec254f97ef03c249bd4e602fd($0, $1)], correlate=[table(MockPythonTableFunction(a,b))], select=[a,b,c,x,y], rowType=[RecordType(INTEGER a, INTEGER b, VARCHAR(2147483647) c, INTEGER x, INTEGER y)], joinType=[INNER])
+- TableSourceScan(table=[[default_catalog, default_database, MyTable, source: [TestTableSource(a, b, c)]]], fields=[a, b, c])
]]>
</Resource>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,12 @@ Correlate(invocation=[org$apache$flink$table$planner$utils$PojoTableFunc$eb4ab6b
<![CDATA[
LogicalCorrelate(correlation=[$cor0], joinType=[inner], requiredColumns=[{}])
:- LogicalTableScan(table=[[default_catalog, default_database, MyTable, source: [TestTableSource(a, b, c)]]])
+- LogicalTableFunctionScan(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$8c725e0df55184e548883d4b29709539($0, $1)], rowType=[RecordType(INTEGER x, INTEGER y)], elementType=[class [Ljava.lang.Object;])
+- LogicalTableFunctionScan(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$2db9292ec254f97ef03c249bd4e602fd($0, $1)], rowType=[RecordType(INTEGER x, INTEGER y)], elementType=[class [Ljava.lang.Object;])
]]>
</Resource>
<Resource name="planAfter">
<![CDATA[
PythonCorrelate(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$8c725e0df55184e548883d4b29709539($0, $1)], correlate=[table(MockPythonTableFunction(a,b))], select=[a,b,c,x,y], rowType=[RecordType(INTEGER a, INTEGER b, VARCHAR(2147483647) c, INTEGER x, INTEGER y)], joinType=[INNER])
PythonCorrelate(invocation=[org$apache$flink$table$planner$utils$MockPythonTableFunction$2db9292ec254f97ef03c249bd4e602fd($0, $1)], correlate=[table(MockPythonTableFunction(a,b))], select=[a,b,c,x,y], rowType=[RecordType(INTEGER a, INTEGER b, VARCHAR(2147483647) c, INTEGER x, INTEGER y)], joinType=[INNER])
+- TableSourceScan(table=[[default_catalog, default_database, MyTable, source: [TestTableSource(a, b, c)]]], fields=[a, b, c])
]]>
</Resource>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ class ExpressionReductionRulesTest extends TableTestBase {
}
}

@SerialVersionUID(1L)
object DeterministicPythonFunc extends ScalarFunction with PythonFunction {

def eval(): Long = 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ class TableFunc3(data: String, conf: Map[String, String]) extends TableFunction[
}
}

@SerialVersionUID(1L)
class MockPythonTableFunction extends TableFunction[Row] with PythonFunction {

def eval(x: Int, y: Int) = ???
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -574,6 +574,7 @@ object DeterministicNullFunc extends ScalarFunction {
override def isDeterministic = true
}

@SerialVersionUID(1L)
object DeterministicPythonFunc extends ScalarFunction with PythonFunction {

def eval(): Long = 1L
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ class PojoUser() {
}
}

@SerialVersionUID(1L)
class MockPythonTableFunction extends TableFunction[Row] with PythonFunction {

def eval(x: Int, y: Int) = ???
Expand Down

0 comments on commit 5fa4259

Please sign in to comment.