Jackie-Jiang commented on code in PR #12684:
URL: https://github.com/apache/pinot/pull/12684#discussion_r1535077183
##########
pinot-controller/src/test/java/org/apache/pinot/controller/helix/core/realtime/segment/FlushThresholdUpdaterTest.java:
##########
@@ -53,49 +53,57 @@ public class FlushThresholdUpdaterTest {
public void testFlushThresholdUpdateManager() {
FlushThresholdUpdateManager flushThresholdUpdateManager = new
FlushThresholdUpdateManager();
- // Flush threshold rows larger than 0 - DefaultFlushThresholdUpdater
should be returned
- FlushThresholdUpdater defaultFlushThresholdUpdater =
flushThresholdUpdateManager
-
.getFlushThresholdUpdater(mockStreamConfig(StreamConfig.DEFAULT_FLUSH_THRESHOLD_ROWS));
- assertTrue(defaultFlushThresholdUpdater instanceof
DefaultFlushThresholdUpdater);
- assertEquals(((DefaultFlushThresholdUpdater)
defaultFlushThresholdUpdater).getTableFlushSize(),
+ // Neither flush threshold rows nor segment size is set -
DefaultFlushThresholdUpdater should be returned
+ FlushThresholdUpdater flushThresholdUpdater =
+
flushThresholdUpdateManager.getFlushThresholdUpdater(mockStreamConfig(-1, -1));
+ assertTrue(flushThresholdUpdater instanceof DefaultFlushThresholdUpdater);
+ assertEquals(((DefaultFlushThresholdUpdater)
flushThresholdUpdater).getTableFlushSize(),
StreamConfig.DEFAULT_FLUSH_THRESHOLD_ROWS);
+ // Flush threshold rows larger than 0 - DefaultFlushThresholdUpdater
should be returned
Review Comment:
For existing table configs, we follow this order; we don't allow such config
in new added/updated table config as we validate only one can be configured
--
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]