adarshsanjeev commented on code in PR #17775:
URL: https://github.com/apache/druid/pull/17775#discussion_r1984563276
##########
server/src/main/java/org/apache/druid/server/coordination/SegmentLoadDropHandler.java:
##########
@@ -386,5 +416,31 @@ public boolean cancel(boolean interruptIfRunning)
return true;
}
}
+
+ public ScheduledExecutorService getExecutorService(SegmentLoadingMode
loadingMode)
+ {
+ switch (loadingMode) {
+ case TURBO:
+ return turboExec;
+ case NORMAL:
+ return exec;
+ default:
+ throw DruidException.defensive("Unknown execution mode [%s]",
loadingMode);
+ }
+ }
+
+ public static SegmentLoadingMode getLoadingMode(CoordinatorDynamicConfig
coordinatorDynamicConfig, String serverName)
+ {
+ final Set<String> turboLoadHistoricals =
coordinatorDynamicConfig.getTurboLoadHistoricals();
+ return turboLoadHistoricals.contains(serverName) ?
+ SegmentLoadingMode.TURBO :
+ SegmentLoadingMode.NORMAL;
+ }
+
+ public enum SegmentLoadingMode
Review Comment:
Moved
--
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]