knox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pzamp...@apache.org
Subject knox git commit: KNOX-1377 - Ranger service discovery should use policymanager_external_url instead of ranger.externalurl
Date Thu, 05 Jul 2018 22:46:17 GMT
Repository: knox
Updated Branches:
  refs/heads/master b152de65c -> a3414a962


KNOX-1377 - Ranger service discovery should use policymanager_external_url instead of ranger.externalurl


Project: http://git-wip-us.apache.org/repos/asf/knox/repo
Commit: http://git-wip-us.apache.org/repos/asf/knox/commit/a3414a96
Tree: http://git-wip-us.apache.org/repos/asf/knox/tree/a3414a96
Diff: http://git-wip-us.apache.org/repos/asf/knox/diff/a3414a96

Branch: refs/heads/master
Commit: a3414a962be5c01d9aee5294cfb492564b7c1dbf
Parents: b152de6
Author: Phil Zampino <pzampino@apache.org>
Authored: Thu Jul 5 17:49:30 2018 -0400
Committer: Phil Zampino <pzampino@apache.org>
Committed: Thu Jul 5 17:49:30 2018 -0400

----------------------------------------------------------------------
 ...mbari-service-discovery-component-config-mapping.properties | 2 +-
 .../main/resources/ambari-service-discovery-url-mappings.xml   | 4 ++--
 .../discovery/ambari/AmbariDynamicServiceURLCreatorTest.java   | 6 ++++--
 3 files changed, 7 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/knox/blob/a3414a96/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-component-config-mapping.properties
----------------------------------------------------------------------
diff --git a/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-component-config-mapping.properties
b/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-component-config-mapping.properties
index 43e8b44..0834888 100644
--- a/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-component-config-mapping.properties
+++ b/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-component-config-mapping.properties
@@ -36,7 +36,7 @@ LIVY2_SERVER=livy2-conf
 LOGSEARCH_SERVER=logsearch-properties
 NAMENODE=hdfs-site
 OOZIE_SERVER=oozie-site
-RANGER_ADMIN=ranger-admin-site
+RANGER_ADMIN=admin-properties
 RESOURCEMANAGER=yarn-site
 SPARK_JOBHISTORYSERVER=spark-defaults
 SPARK2_JOBHISTORYSERVER=spark2-defaults

http://git-wip-us.apache.org/repos/asf/knox/blob/a3414a96/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-url-mappings.xml
----------------------------------------------------------------------
diff --git a/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-url-mappings.xml
b/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-url-mappings.xml
index 8165b79..5609de3 100644
--- a/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-url-mappings.xml
+++ b/gateway-discovery-ambari/src/main/resources/ambari-service-discovery-url-mappings.xml
@@ -390,7 +390,7 @@
         <properties>
           <property name="RANGER_EXTERNAL_URL">
             <component>RANGER_ADMIN</component>
-            <config-property>ranger.externalurl</config-property>
+            <config-property>policymgr_external_url</config-property>
           </property>
         </properties>
     </service>
@@ -400,7 +400,7 @@
         <properties>
             <property name="RANGER_EXTERNAL_URL">
                 <component>RANGER_ADMIN</component>
-                <config-property>ranger.externalurl</config-property>
+                <config-property>policymgr_external_url</config-property>
             </property>
         </properties>
     </service>

http://git-wip-us.apache.org/repos/asf/knox/blob/a3414a96/gateway-discovery-ambari/src/test/java/org/apache/knox/gateway/topology/discovery/ambari/AmbariDynamicServiceURLCreatorTest.java
----------------------------------------------------------------------
diff --git a/gateway-discovery-ambari/src/test/java/org/apache/knox/gateway/topology/discovery/ambari/AmbariDynamicServiceURLCreatorTest.java
b/gateway-discovery-ambari/src/test/java/org/apache/knox/gateway/topology/discovery/ambari/AmbariDynamicServiceURLCreatorTest.java
index 554fe88..96d8622 100644
--- a/gateway-discovery-ambari/src/test/java/org/apache/knox/gateway/topology/discovery/ambari/AmbariDynamicServiceURLCreatorTest.java
+++ b/gateway-discovery-ambari/src/test/java/org/apache/knox/gateway/topology/discovery/ambari/AmbariDynamicServiceURLCreatorTest.java
@@ -912,7 +912,8 @@ public class AmbariDynamicServiceURLCreatorTest {
         EasyMock.expect(rangerAdmin.getConfigProperty("ranger.service.https.attrib.ssl.enabled")).andReturn("false").anyTimes();
         EasyMock.expect(rangerAdmin.getConfigProperty("ranger.service.http.port")).andReturn(HTTP_PORT).anyTimes();
         EasyMock.expect(rangerAdmin.getConfigProperty("ranger.service.https.port")).andReturn(HTTPS_PORT).anyTimes();
-        EasyMock.expect(rangerAdmin.getConfigProperty("ranger.externalurl")).andReturn(EXT_URL).anyTimes();
+        EasyMock.expect(rangerAdmin.getConfigProperty("ranger.externalurl")).andReturn("http://host7:9898").anyTimes();
+        EasyMock.expect(rangerAdmin.getConfigProperty("policymgr_external_url")).andReturn(EXT_URL).anyTimes();
         EasyMock.replay(rangerAdmin);
 
         AmbariCluster cluster = EasyMock.createNiceMock(AmbariCluster.class);
@@ -931,7 +932,8 @@ public class AmbariDynamicServiceURLCreatorTest {
         EasyMock.expect(rangerAdmin.getConfigProperty("ranger.service.https.attrib.ssl.enabled")).andReturn("true").anyTimes();
         EasyMock.expect(rangerAdmin.getConfigProperty("ranger.service.http.port")).andReturn(HTTP_PORT).anyTimes();
         EasyMock.expect(rangerAdmin.getConfigProperty("ranger.service.https.port")).andReturn(HTTPS_PORT).anyTimes();
-        EasyMock.expect(rangerAdmin.getConfigProperty("ranger.externalurl")).andReturn(EXT_URL).anyTimes();
+        EasyMock.expect(rangerAdmin.getConfigProperty("ranger.externalurl")).andReturn("http://host7:9898").anyTimes();
+        EasyMock.expect(rangerAdmin.getConfigProperty("policymgr_external_url")).andReturn(EXT_URL).anyTimes();
         EasyMock.replay(rangerAdmin);
 
         // Run the test, making sure that the external URL is the result


Mime
View raw message