yihua commented on code in PR #13830:
URL: https://github.com/apache/hudi/pull/13830#discussion_r2319699769
##########
hudi-spark-datasource/hudi-spark/src/test/scala/org/apache/hudi/functional/TestRecordLevelIndex.scala:
##########
@@ -291,10 +291,14 @@ class TestRecordLevelIndex extends
RecordLevelIndexTestBase {
insertDf.cache()
val instantTime = getNewInstantTime
- // Issue two deletes, one with the original partition and one with an
updated partition
- val recordsToDelete = dataGen.generateUniqueDeleteRecords(instantTime, 1)
-
recordsToDelete.addAll(dataGen.generateUniqueDeleteRecordsWithUpdatedPartition(instantTime,
1))
- val deleteBatch = recordsToStrings(recordsToDelete).asScala
+ // Issue four deletes, one with the original partition, one with an
updated partition,
+ // and two with an older ordering value that should be ignored
+ val deletedRecords = dataGen.generateUniqueDeleteRecords(instantTime, 1)
+
deletedRecords.addAll(dataGen.generateUniqueDeleteRecordsWithUpdatedPartition(instantTime,
1))
+ val inputRecords = new util.ArrayList[HoodieRecord[_]](deletedRecords)
+ inputRecords.addAll(dataGen.generateUniqueDeleteRecords(instantTime, 1,
1L))
+
inputRecords.addAll(dataGen.generateUniqueDeleteRecordsWithUpdatedPartition(instantTime,
1, 1L))
Review Comment:
nit: add `val lowerOrderingValue = 1L` and use it here for readability?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]