You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@storm.apache.org by GitBox <gi...@apache.org> on 2019/02/09 08:30:18 UTC
[GitHub] srdo commented on a change in pull request #2957: STORM-3335 allow
timing out when scheduling a topology
srdo commented on a change in pull request #2957: STORM-3335 allow timing out when scheduling a topology
URL: https://github.com/apache/storm/pull/2957#discussion_r255291779
##########
File path: storm-server/src/main/java/org/apache/storm/scheduler/resource/ResourceAwareScheduler.java
##########
@@ -78,6 +85,9 @@ public void prepare(Map<String, Object> conf) {
configLoader = ConfigLoaderFactoryService.createConfigLoader(conf);
maxSchedulingAttempts = ObjectReader.getInt(
conf.get(DaemonConfig.RESOURCE_AWARE_SCHEDULER_MAX_TOPOLOGY_SCHEDULING_ATTEMPTS), 5);
+ schedulingTimeoutSeconds = ObjectReader.getInt(
+ conf.get(DaemonConfig.SCHEDULING_TIMEOUT_SECONDS_PER_TOPOLOGY), 60);
+ backgroundScheduling = Executors.newFixedThreadPool(1);
Review comment:
I think we need to add a method that allows cleanup of `IScheduler`, similar to the `cleanup` method we have on `IBolt`. This executor needs to be shut down, otherwise the thread will leak if this class gets used in tests.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services