nsivabalan commented on code in PR #13229:
URL: https://github.com/apache/hudi/pull/13229#discussion_r2103609424


##########
hudi-client/hudi-java-client/src/test/java/org/apache/hudi/testutils/HoodieJavaClientTestHarness.java:
##########
@@ -672,49 +689,61 @@ public List<WriteStatus> writeBatch(HoodieJavaWriteClient 
client, String newComm
    * @param expRecordsInThisCommit       Expected number of records in this 
commit
    * @param expTotalRecords              Expected number of records when 
scanned
    * @param expTotalCommits              Expected number of commits (including 
this commit)
-   * @param doCommit
    * @throws Exception in case of error
    */
   public List<WriteStatus> writeBatch(HoodieJavaWriteClient client, String 
newCommitTime, String prevCommitTime,
                                       Option<List<String>> 
commitTimesBetweenPrevAndNew, String initCommitTime, int numRecordsInThisCommit,
                                       Function2<List<HoodieRecord>, String, 
Integer> recordGenFunction,
                                       Function3<List<WriteStatus>, 
HoodieJavaWriteClient, List<HoodieRecord>, String> writeFn,
-                                      boolean assertForCommit, int 
expRecordsInThisCommit, int expTotalRecords, int expTotalCommits, boolean 
doCommit,
-                                      boolean filterForCommitTimeWithAssert, 
InstantGenerator instantGenerator) throws Exception {
+                                      boolean assertForCommit, int 
expRecordsInThisCommit, int expTotalRecords, int expTotalCommits,
+                                      boolean filterForCommitTimeWithAssert, 
InstantGenerator instantGenerator,
+                                      boolean skipCommit) throws Exception {
 
     List<HoodieRecord> records = recordGenFunction.apply(newCommitTime, 
numRecordsInThisCommit);
     return writeBatchHelper(client, newCommitTime, prevCommitTime, 
commitTimesBetweenPrevAndNew, initCommitTime,
         numRecordsInThisCommit, records, writeFn, assertForCommit, 
expRecordsInThisCommit, expTotalRecords,
-        expTotalCommits, doCommit, filterForCommitTimeWithAssert, 
instantGenerator);
+        expTotalCommits, filterForCommitTimeWithAssert, instantGenerator, 
skipCommit);
   }
 
   public List<WriteStatus> writeBatch(HoodieJavaWriteClient client, String 
newCommitTime, String prevCommitTime,
                                       Option<List<String>> 
commitTimesBetweenPrevAndNew, String initCommitTime, int numRecordsInThisCommit,
                                       Function3<List<HoodieRecord>, String, 
Integer, String> recordGenFunction,
                                       Function3<List<WriteStatus>, 
HoodieJavaWriteClient, List<HoodieRecord>, String> writeFn,
-                                      boolean assertForCommit, int 
expRecordsInThisCommit, int expTotalRecords, int expTotalCommits, boolean 
doCommit,
+                                      boolean assertForCommit, int 
expRecordsInThisCommit, int expTotalRecords, int expTotalCommits,
                                       boolean filterForCommitTimeWithAssert,
                                       String partition, InstantGenerator 
instantGenerator) throws Exception {
 
     List<HoodieRecord> records = recordGenFunction.apply(newCommitTime, 
numRecordsInThisCommit, partition);
     return writeBatchHelper(client, newCommitTime, prevCommitTime, 
commitTimesBetweenPrevAndNew, initCommitTime,
         numRecordsInThisCommit, records, writeFn, assertForCommit, 
expRecordsInThisCommit, expTotalRecords,
-        expTotalCommits, doCommit, filterForCommitTimeWithAssert, 
instantGenerator);
+        expTotalCommits, filterForCommitTimeWithAssert, instantGenerator);
+  }
+
+  private List<WriteStatus> writeBatchHelper(HoodieJavaWriteClient client, 
String newCommitTime, String prevCommitTime,
+                                             Option<List<String>> 
commitTimesBetweenPrevAndNew, String initCommitTime,
+                                             int numRecordsInThisCommit, 
List<HoodieRecord> records,
+                                             Function3<List<WriteStatus>, 
HoodieJavaWriteClient, List<HoodieRecord>, String> writeFn,
+                                             boolean assertForCommit, int 
expRecordsInThisCommit, int expTotalRecords,
+                                             int expTotalCommits, boolean 
filterForCommitTimeWithAssert, InstantGenerator instantGenerator) throws 
IOException {
+    return writeBatchHelper(client, newCommitTime, prevCommitTime, 
commitTimesBetweenPrevAndNew, initCommitTime,
+        numRecordsInThisCommit, records, writeFn, assertForCommit, 
expRecordsInThisCommit, expTotalRecords, expTotalCommits,
+        filterForCommitTimeWithAssert, instantGenerator, false);

Review Comment:
   ack. 



-- 
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]

Reply via email to