Github user HeartSaVioR commented on a diff in the pull request: https://github.com/apache/storm/pull/2202#discussion_r130254446 --- Diff: storm-client/src/jvm/org/apache/storm/utils/ReflectionUtils.java --- @@ -72,6 +74,17 @@ public static ReflectionUtils setInstance(ReflectionUtils u) { } } + public static <T> T newSchedulerStrategyInstance(String klass, Map<String, Object> conf) { + List<String> allowedSchedulerStrategies = (List<String>) conf.get(Config.NIMBUS_SCHEDULER_STRATEGY_CLASS_WHITELIST); + if(allowedSchedulerStrategies == null || allowedSchedulerStrategies.contains(klass)) { + return newInstance(klass); + } + else { + //throw new RuntimeException("Cannot run topology with strategy [" + klass + "]. Allowed strategies are: " + allowedSchedulerStrategies); --- End diff -- Nit: Better to remove comment here.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---