Repository navigation
Migrate source package in Flink - #10632
Conversation
|
This PR currently only has Flink 1.19 because the number of class changes is a bit many. Will create a backport PR for other Flink versions 1.17 and 1.18 |
|
@nastra when you have a chance, could you review this PR? Currently this PR only includes Flink 1.19 because of the a lot of file changes. |
| @@ -107,7 +114,11 @@ public void testSingleFileLessThanOneFullBatch() throws Exception { | |||
| public void testSingleFileWithMultipleBatches() throws Exception { | |||
There was a problem hiding this comment.
I set some comments to as(...) and remove some explicit comments to avoid exceeding 150 lines per a method limitation which is defined in the checkStyle.
|
|
||
| @Rule public TestName testName = new TestName(); | ||
| @RegisterExtension | ||
| private static final HadoopTableExtension tableResource = |
There was a problem hiding this comment.
given that it's a static final it should be all uppercase
There was a problem hiding this comment.
Sure, thanks for the advice. Will update the variables.
| @TempDir protected Path temporaryFolder; | ||
|
|
||
| @RegisterExtension | ||
| private static final HadoopTableExtension tableResource = |
nastra
left a comment
There was a problem hiding this comment.
LGTM, thanks for working on this @tomtongue. I've just left two small comments
| Assert.assertNull(batch11.nextRecordFromSplit()); | ||
| Assert.assertNull(batch11.nextSplit()); | ||
| assertThat(batch11.nextRecordFromSplit()).isNull(); | ||
| assertThat(batch11.nextSplit()); |
There was a problem hiding this comment.
Oops, sorry thanks for the review! @ebyhr
| break; | ||
| default: | ||
| Assert.fail("Unknown status: " + expectedStatus); | ||
| fail(String.format("Unknown status: %s", expectedStatus)); |
There was a problem hiding this comment.
String.format seems redundant because fail method supports (String failureMessage, Object... args).
Throws an AssertionError with the given message built as String.format(String, Object...).
There was a problem hiding this comment.
Thank for checking this. Fix in the new commit.
nastra
left a comment
There was a problem hiding this comment.
Thanks @tomtongue and also thanks to @ebyhr for the additional review
Migrate the following classes in
iceberg-flinkto JUnit 5 for #9087Curretly only including Flink 1.19.
SplitAssignerTestBaseTestDefaultSplitAssignerTestFileSequenceNumberBasedSplitAssignerTestWatermarkBasedSplitAssignerTestContinuousIcebergEnumeratorTestContinuousSplitPlannerImplTestContinuousSplitPlannerImplStartStrategyTestEnumerationHistoryTestIcebergEnumeratorStateSerializerReaderFunctionTestBaseReaderUtilTestArrayBatchRecordsTestArrayPoolDataIteratorBatcherRowDataTestIcebergSourceReaderTestRowDataReaderFunctionTestIcebergSourceSplitSerializerSplitHelpers