somandal commented on code in PR #16096:
URL: https://github.com/apache/pinot/pull/16096#discussion_r2155516735
##########
pinot-controller/src/main/java/org/apache/pinot/controller/helix/core/realtime/PinotLLCRealtimeSegmentManager.java:
##########
@@ -2185,7 +2185,7 @@ private void processBatchesSequentially(List<Set<String>>
segmentBatchList, Stri
}
}
- private void waitUntilPrevBatchIsComplete(String tableNameWithType,
Set<String> segmentBatchToCommit,
+ public void waitUntilPrevBatchIsComplete(String tableNameWithType,
Set<String> segmentBatchToCommit,
Review Comment:
Usually it's better to have a utility if there are at least 2 code paths
that use it. We often do that even if it is not wider used. Main issue with
duplication is the maintenance overhead of fixing up the code in 2 or more
places instead of one when making bug fixes or changes. It is easy to miss and
this leads to accumulating more bugs over time.
I'm okay with making it public but prefer a rename for sure if going with
that route. The name should include something about forceCommit in it,
otherwise it is hard to make sense of what you're waiting for 😅 (try to think
in terms of code readability without having to jump to that function etc)
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]