jackjlli commented on a change in pull request #7516:
URL: https://github.com/apache/pinot/pull/7516#discussion_r724569790
##########
File path:
pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/test/java/org/apache/pinot/plugin/minion/tasks/mergerollup/MergeRollupTaskExecutorTest.java
##########
@@ -104,7 +104,7 @@ public void setUp()
@Test
public void testConvert()
throws Exception {
- MergeRollupTaskExecutor mergeRollupTaskExecutor = new
MergeRollupTaskExecutor();
+ MergeRollupTaskExecutor mergeRollupTaskExecutor = new
MergeRollupTaskExecutor(null);
Review comment:
If the minionZkMetadataManager is null, can we just use the default
constructor here?
##########
File path:
pinot-minion/src/main/java/org/apache/pinot/minion/BaseMinionStarter.java
##########
@@ -101,7 +101,11 @@ public void init(PinotConfiguration config)
_listenerConfigs = ListenerConfigUtil.buildMinionAdminConfigs(_config);
setupHelixSystemProperties();
_helixManager = new ZKHelixManager(helixClusterName, _instanceId,
InstanceType.PARTICIPANT, zkAddress);
- MinionTaskZkMetadataManager minionTaskZkMetadataManager = new
MinionTaskZkMetadataManager(_helixManager);
+ int endReplaceSegmentsSocketTimeoutMs =
+
_config.getProperty(CommonConstants.Minion.END_REPLACE_SEGMENTS_SOCKET_TIMEOUT_MS_KEY,
+
CommonConstants.Minion.DEFAULT_END_REPLACE_SEGMENTS_SOCKET_TIMEOUT_MS);
+ MinionTaskZkMetadataManager minionTaskZkMetadataManager =
+ new MinionTaskZkMetadataManager(_helixManager,
endReplaceSegmentsSocketTimeoutMs);
Review comment:
How about passing the whole PinotConfiguration to the
`MinionTaskZkMetadataManager` class? By doing so, you don't have to keep
adding parameters to the constructor (which is a bad idea) if needed.
--
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]