Skip to content

Commit 38cb694

Browse files
author
yangtao555
committed
fix test
1 parent 669e180 commit 38cb694

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

‎fe/fe-connector/fe-connector-iceberg/src/test/java/org/apache/doris/connector/iceberg/IcebergWritePlanProviderTest.java‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1724,7 +1724,7 @@ public void planWriteThreadsPinnedReadSnapshotFromHandleToTransaction() {
17241724
}
17251725

17261726
@Test
1727-
public void planMergePreservesExplicitlyEmptyReadAcrossConcurrentFirstAppend() {
1727+
public void planMergeKeepsExplicitEmptyReadFencedAcrossConcurrentFirstAppend() {
17281728
InMemoryCatalog catalog = freshCatalog();
17291729
TableIdentifier id = TableIdentifier.of("db1", "tv2");
17301730
Table empty = catalog.createTable(id, SCHEMA, PartitionSpec.unpartitioned(),
@@ -1751,8 +1751,9 @@ public void planMergePreservesExplicitlyEmptyReadAcrossConcurrentFirstAppend() {
17511751
providerFor(ops.table, ctx).planWrite(new WriteSession(txn),
17521752
new WriteHandle(emptyPinnedHandle).writeOperation(WriteOperation.MERGE));
17531753

1754-
Assertions.assertNull(txn.getBaseSnapshotId(),
1755-
"an explicitly empty read must leave RowDelta validation unbounded across the first append");
1754+
Assertions.assertEquals(Long.valueOf(-1L), txn.getBaseSnapshotId(),
1755+
"an explicit empty read is an OCC fence (base -1), not an absent pin: the pinned empty "
1756+
+ "generation must survive the concurrent first append instead of drifting to S1");
17561757
}
17571758

17581759
// ───────────────────────────── MERGE sink (TIcebergMergeSink) ─────────────────────────────

0 commit comments

Comments
 (0)