Github user gauravgopi123 commented on a diff in the pull request:
https://github.com/apache/apex-core/pull/357#discussion_r70900700
--- Diff: engine/src/main/java/com/datatorrent/stram/util/ConfigUtils.java
---
@@ -68,15 +68,30 @@ public static String getRMUsername(Configuration conf)
return principal;
}
- public static String getSchemePrefix(YarnConfiguration conf)
+ public static boolean isSSLEnabled(Configuration conf)
+ {
+ if (HttpConfig.Policy.HTTPS_ONLY == HttpConfig.Policy.fromString(
+ conf.get(YarnConfiguration.YARN_HTTP_POLICY_KEY,
YarnConfiguration.YARN_HTTP_POLICY_DEFAULT))) {
+ return true;
+ }
+ return false;
+ }
+
+ public static String getSchemePrefix(Configuration conf)
{
- if (HttpConfig.Policy.HTTPS_ONLY ==
HttpConfig.Policy.fromString(conf.get(YarnConfiguration.YARN_HTTP_POLICY_KEY,
YarnConfiguration.YARN_HTTP_POLICY_DEFAULT))) {
+ if (isSSLEnabled(conf)) {
--- End diff --
@PramodSSImmaneni : I missed one thing. New method is needed as AppMaster
has Configuration and YarnConfiguration object..
Changes look good
---
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 [email protected] or file a JIRA ticket
with INFRA.
---