From fadae59decda28d3815b6bd71a557b47aa91e27b Mon Sep 17 00:00:00 2001 From: wudi <676366545@qq.com> Date: Tue, 10 Sep 2024 16:45:51 +0800 Subject: [PATCH] update --- .../doris/flink/source/reader/DorisSourceSplitReader.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/flink-doris-connector/src/main/java/org/apache/doris/flink/source/reader/DorisSourceSplitReader.java b/flink-doris-connector/src/main/java/org/apache/doris/flink/source/reader/DorisSourceSplitReader.java index d29dc0db8..ce863377b 100644 --- a/flink-doris-connector/src/main/java/org/apache/doris/flink/source/reader/DorisSourceSplitReader.java +++ b/flink-doris-connector/src/main/java/org/apache/doris/flink/source/reader/DorisSourceSplitReader.java @@ -66,7 +66,7 @@ public RecordsWithSplitIds fetch() throws IOException { } private void checkSplitOrStartNext() throws IOException, DorisException { - if (valueReader != null) { + if (valueReader != null && valueReader.hasNext()) { return; } final DorisSourceSplit nextSplit = splits.poll(); @@ -74,6 +74,7 @@ private void checkSplitOrStartNext() throws IOException, DorisException { throw new IOException("Cannot fetch from another split - no split remaining"); } currentSplitId = nextSplit.splitId(); + LOG.info("currentSplitId {}, split {}", currentSplitId, nextSplit); valueReader = ValueReader.createReader( nextSplit.getPartitionDefinition(), options, readOptions, LOG);