This is an automated email from the ASF dual-hosted git repository.

oleewere pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ambari.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 07287c5  AMBARI-22962. ADDENDUM - UI and stack advistor changes for 
Ambari Infra rename
07287c5 is described below

commit 07287c5da0d246ace9243b1804afbdd5a33a5d7d
Author: Oliver Szabo <oleew...@gmail.com>
AuthorDate: Tue Feb 20 09:11:06 2018 +0100

    AMBARI-22962. ADDENDUM - UI and stack advistor changes for Ambari Infra 
rename
---
 .../LOGSEARCH/0.5.0/service_advisor.py             |  2 +-
 .../stacks/HDP/2.5/services/stack_advisor.py       |  6 +--
 .../LOGSEARCH/test_service_advisor.py              |  4 +-
 .../python/stacks/2.5/common/test_stack_advisor.py |  4 +-
 .../highAvailability/nameNode/step7_controller.js  |  5 +-
 .../app/controllers/wizard/step4_controller.js     |  6 +--
 ...operties.js => ambari_infra_solr_properties.js} | 54 +++++++++++-----------
 ambari-web/app/data/configs/site_properties.js     |  2 +-
 ambari-web/app/models/stack_service.js             |  2 +-
 .../nameNode/step7_controller_test.js              |  2 +-
 .../test/controllers/main/host/details_test.js     |  2 +-
 ambari-web/test/controllers/wizard/step4_test.js   | 12 ++---
 12 files changed, 50 insertions(+), 51 deletions(-)

diff --git 
a/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/service_advisor.py
 
b/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/service_advisor.py
index 406f844..059f593 100644
--- 
a/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/service_advisor.py
+++ 
b/ambari-server/src/main/resources/common-services/LOGSEARCH/0.5.0/service_advisor.py
@@ -137,7 +137,7 @@ class 
LogSearchServiceAdvisor(service_advisor.ServiceAdvisor):
         self.putPropertyAttribute(configurations, "logsearch-admin-json")(key, 
'visible', 'false')
     # if there is a Log Search server on the cluster
     else:
-      infraSolrHosts = self.getComponentHostNames(services, "AMBARI_INFRA", 
"INFRA_SOLR")
+      infraSolrHosts = self.getComponentHostNames(services, 
"AMBARI_INFRA_SOLR", "INFRA_SOLR")
       # if there is AMBARI_INFRA, calculate the min/max shards and 
recommendations based on the number of infra solr hosts
       if infraSolrHosts is not None and len(infraSolrHosts) > 0 and 
"logsearch-properties" in services["configurations"]:
         replicationReccomendFloat = math.log(len(infraSolrHosts), 5)
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.5/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/2.5/services/stack_advisor.py
index f069ed4..b8de372 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.5/services/stack_advisor.py
+++ b/ambari-server/src/main/resources/stacks/HDP/2.5/services/stack_advisor.py
@@ -215,7 +215,7 @@ class HDP25StackAdvisor(HDP24StackAdvisor):
             not 
application_properties['atlas.graph.index.search.solr.zookeeper-url']:
       validationItems.append({"config-name": 
"atlas.graph.index.search.solr.zookeeper-url",
                               "item": self.getErrorItem(
-                                  "If AMBARI_INFRA is not installed then the 
SOLR zookeeper url configuration must be specified.")})
+                                  "If AMBARI_INFRA_SOLR is not installed then 
the SOLR zookeeper url configuration must be specified.")})
 
     if not application_properties['atlas.kafka.bootstrap.servers']:
       validationItems.append({"config-name": "atlas.kafka.bootstrap.servers",
@@ -609,7 +609,7 @@ class HDP25StackAdvisor(HDP24StackAdvisor):
     if atlas_rest_address is not None:
       putAtlasApplicationProperty("atlas.rest.address", atlas_rest_address)
 
-    if "AMBARI_INFRA" in servicesList and 'infra-solr-env' in 
services['configurations']:
+    if "AMBARI_INFRA_SOLR" in servicesList and 'infra-solr-env' in 
services['configurations']:
       if 'infra_solr_znode' in 
services['configurations']['infra-solr-env']['properties']:
         infra_solr_znode = 
services['configurations']['infra-solr-env']['properties']['infra_solr_znode']
       else:
@@ -2042,7 +2042,7 @@ 
yarn.scheduler.capacity.root.{0}.maximum-am-resource-percent=1""".format(llap_qu
 
     ranger_audit_zk_port = ''
 
-    if 'AMBARI_INFRA' in servicesList and zookeeper_host_port and 
is_solr_cloud_enabled and not is_external_solr_cloud_enabled:
+    if 'AMBARI_INFRA_SOLR' in servicesList and zookeeper_host_port and 
is_solr_cloud_enabled and not is_external_solr_cloud_enabled:
       zookeeper_host_port = zookeeper_host_port.split(',')
       zookeeper_host_port.sort()
       zookeeper_host_port = ",".join(zookeeper_host_port)
diff --git 
a/ambari-server/src/test/python/common-services/LOGSEARCH/test_service_advisor.py
 
b/ambari-server/src/test/python/common-services/LOGSEARCH/test_service_advisor.py
index 4c35f28..996df42 100644
--- 
a/ambari-server/src/test/python/common-services/LOGSEARCH/test_service_advisor.py
+++ 
b/ambari-server/src/test/python/common-services/LOGSEARCH/test_service_advisor.py
@@ -82,9 +82,9 @@ class TestLOGSEARCH050ServiceAdvisor(TestCase):
     services = {
       "services": [
         {
-          "href": "/api/v1/stacks/HDP/versions/2.3/services/AMBARI_INFRA",
+          "href": "/api/v1/stacks/HDP/versions/2.3/services/AMBARI_INFRA_SOLR",
           "StackServices": {
-            "service_name": "AMBARI_INFRA",
+            "service_name": "AMBARI_INFRA_SOLR",
             "service_version": "2.6.0.2.2",
             "stack_name": "HDP",
             "stack_version": "2.3"
diff --git 
a/ambari-server/src/test/python/stacks/2.5/common/test_stack_advisor.py 
b/ambari-server/src/test/python/stacks/2.5/common/test_stack_advisor.py
index bfac76b..9cfc12f 100644
--- a/ambari-server/src/test/python/stacks/2.5/common/test_stack_advisor.py
+++ b/ambari-server/src/test/python/stacks/2.5/common/test_stack_advisor.py
@@ -4867,9 +4867,9 @@ class TestHDP25StackAdvisor(TestCase):
       },
       "services": [
         {
-          "href": "/api/v1/stacks/HDP/versions/2.2/services/AMBARI_INFRA",
+          "href": "/api/v1/stacks/HDP/versions/2.2/services/AMBARI_INFRA_SOLR",
           "StackServices": {
-            "service_name": "AMBARI_INFRA",
+            "service_name": "AMBARI_INFRA_SOLR",
             "service_version": "2.6.0.2.2",
             "stack_name": "HDP",
             "stack_version": "2.3"
diff --git 
a/ambari-web/app/controllers/main/admin/highAvailability/nameNode/step7_controller.js
 
b/ambari-web/app/controllers/main/admin/highAvailability/nameNode/step7_controller.js
index 9e14281..f4b6ff7 100644
--- 
a/ambari-web/app/controllers/main/admin/highAvailability/nameNode/step7_controller.js
+++ 
b/ambari-web/app/controllers/main/admin/highAvailability/nameNode/step7_controller.js
@@ -28,7 +28,7 @@ App.HighAvailabilityWizardStep7Controller = 
App.HighAvailabilityProgressPageCont
     this._super();
     var tasksToRemove = [];
 
-    if (!App.Service.find().someProperty('serviceName', 'AMBARI_INFRA')) {
+    if (!App.Service.find().someProperty('serviceName', 'AMBARI_INFRA_SOLR')) {
       tasksToRemove.push('startAmbariInfra');
     }
 
@@ -39,7 +39,7 @@ App.HighAvailabilityWizardStep7Controller = 
App.HighAvailabilityProgressPageCont
   },
 
   startAmbariInfra: function () {
-    this.startServices(false, ['AMBARI_INFRA'], true);
+    this.startServices(false, ['AMBARI_INFRA_SOLR'], true);
   },
 
   startRanger: function () {
@@ -59,4 +59,3 @@ App.HighAvailabilityWizardStep7Controller = 
App.HighAvailabilityProgressPageCont
     this.updateComponent('NAMENODE', hostName, "HDFS", "Start");
   }
 });
-
diff --git a/ambari-web/app/controllers/wizard/step4_controller.js 
b/ambari-web/app/controllers/wizard/step4_controller.js
index 9defa12..5f9eea2 100644
--- a/ambari-web/app/controllers/wizard/step4_controller.js
+++ b/ambari-web/app/controllers/wizard/step4_controller.js
@@ -193,8 +193,8 @@ App.WizardStep4Controller = Em.ArrayController.extend({
       this.serviceValidation(callback, 'AMBARI_METRICS', 'ambariMetricsCheck');
       this.serviceValidation(callback, 'SMARTSENSE', 'smartSenseCheck');
     }
-    this.dependentServiceValidation('ATLAS', 'AMBARI_INFRA', 
'ambariInfraCheck', callback);
-    this.dependentServiceValidation('LOGSEARCH', 'AMBARI_INFRA', 
'ambariLogsearchCheck', callback);
+    this.dependentServiceValidation('ATLAS', 'AMBARI_INFRA_SOLR', 
'ambariInfraCheck', callback);
+    this.dependentServiceValidation('LOGSEARCH', 'AMBARI_INFRA_SOLR', 
'ambariLogsearchCheck', callback);
     this.rangerValidation(callback);
     this.sparkValidation(callback);
     if (!!this.get('errorStack').filterProperty('isShown', false).length) {
@@ -379,7 +379,7 @@ App.WizardStep4Controller = Em.ArrayController.extend({
         }
         else
         {
-          //if multiple DFS are not selected, remove the related error from 
the error array 
+          //if multiple DFS are not selected, remove the related error from 
the error array
           var fsError = 
this.get('errorStack').filterProperty('id',"multipleDFS");
           if(fsError)
           {
diff --git a/ambari-web/app/data/configs/services/ambari_infra_properties.js 
b/ambari-web/app/data/configs/services/ambari_infra_solr_properties.js
similarity index 82%
rename from ambari-web/app/data/configs/services/ambari_infra_properties.js
rename to ambari-web/app/data/configs/services/ambari_infra_solr_properties.js
index ab9471f..4d47720 100644
--- a/ambari-web/app/data/configs/services/ambari_infra_properties.js
+++ b/ambari-web/app/data/configs/services/ambari_infra_solr_properties.js
@@ -22,181 +22,181 @@ module.exports = [
     "filename": "infra-solr-client-log4j.xml",
     "index": 1,
     "name": "infra_solr_client_log_dir",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-client-log4j",
     "filename": "infra-solr-client-log4j.xml",
     "index": 2,
     "name": "infra_client_log_maxfilesize",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-client-log4j",
     "filename": "infra-solr-client-log4j.xml",
     "index": 3,
     "name": "infra_client_log_maxbackupindex",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-client-log4j",
     "filename": "infra-solr-client-log4j.xml",
     "index": 4,
     "name": "content",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 1,
     "name": "infra_solr_log_dir",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 2,
     "name": "infra_solr_pid_dir",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 3,
     "name": "infra_solr_port",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 4,
     "name": "infra_solr_jmx_port",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 5,
     "name": "infra_solr_jmx_enabled",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 6,
     "name": "infra_solr_ssl_enabled",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 7,
     "name": "infra_solr_truststore_location",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 8,
     "name": "infra_solr_truststore_type",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 9,
     "name": "infra_solr_truststore_password",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 10,
     "name": "infra_solr_keystore_location",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 11,
     "name": "infra_solr_keystore_type",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 12,
     "name": "infra_solr_keystore_password",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 13,
     "name": "infra_solr_kerberos_keytab",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 14,
     "name": "infra_solr_kerberos_principal",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 15,
     "name": "infra_solr_web_kerberos_keytab",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 16,
     "name": "infra_solr_web_kerberos_principal",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 17,
     "name": "infra_solr_kerberos_name_rules",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-env",
     "filename": "infra-solr-env.xml",
     "index": 18,
     "name": "content",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-log4j",
     "filename": "infra-solr-log4j.xml",
     "index": 1,
     "name": "infra_log_maxfilesize",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-log4j",
     "filename": "infra-solr-log4j.xml",
     "index": 2,
     "name": "infra_log_maxbackupindex",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-log4j",
     "filename": "infra-solr-log4j.xml",
     "index": 3,
     "name": "content",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   },
   {
     "category": "Advanced infra-solr-xml",
     "filename": "infra-solr-xml.xml",
     "index": 1,
     "name": "content",
-    "serviceName": "AMBARI_INFRA"
+    "serviceName": "AMBARI_INFRA_SOLR"
   }
-];
\ No newline at end of file
+];
diff --git a/ambari-web/app/data/configs/site_properties.js 
b/ambari-web/app/data/configs/site_properties.js
index 2fd4ac4..2151ead 100644
--- a/ambari-web/app/data/configs/site_properties.js
+++ b/ambari-web/app/data/configs/site_properties.js
@@ -31,7 +31,7 @@ var includeSiteProperties = function() {
 module.exports = {
   configProperties: includeSiteProperties(
     'accumulo',
-    'ambari_infra',
+    'ambari_infra_solr',
     'ambari_metrics',
     'falcon',
     'flume',
diff --git a/ambari-web/app/models/stack_service.js 
b/ambari-web/app/models/stack_service.js
index 1b583c1..2bd5217 100644
--- a/ambari-web/app/models/stack_service.js
+++ b/ambari-web/app/models/stack_service.js
@@ -320,7 +320,7 @@ App.StackService.displayOrder = [
   'STORM',
   'FLUME',
   'ACCUMULO',
-  'AMBARI_INFRA',
+  'AMBARI_INFRA_SOLR',
   'AMBARI_METRICS',
   'ATLAS',
   'KAFKA',
diff --git 
a/ambari-web/test/controllers/main/admin/highAvailability/nameNode/step7_controller_test.js
 
b/ambari-web/test/controllers/main/admin/highAvailability/nameNode/step7_controller_test.js
index a285952..09b70e6 100644
--- 
a/ambari-web/test/controllers/main/admin/highAvailability/nameNode/step7_controller_test.js
+++ 
b/ambari-web/test/controllers/main/admin/highAvailability/nameNode/step7_controller_test.js
@@ -53,7 +53,7 @@ describe('App.HighAvailabilityWizardStep7Controller', 
function() {
 
     it('startServices should be called', function() {
       controller.startAmbariInfra();
-      expect(controller.startServices.calledWith(false, ['AMBARI_INFRA'], 
true)).to.be.true;
+      expect(controller.startServices.calledWith(false, ['AMBARI_INFRA_SOLR'], 
true)).to.be.true;
     });
   });
 
diff --git a/ambari-web/test/controllers/main/host/details_test.js 
b/ambari-web/test/controllers/main/host/details_test.js
index 916f67e..a619270 100644
--- a/ambari-web/test/controllers/main/host/details_test.js
+++ b/ambari-web/test/controllers/main/host/details_test.js
@@ -1046,7 +1046,7 @@ describe('App.MainHostDetailsController', function () {
       
expect(controller.constructZookeeperConfigUrlParams(data)).to.eql(['(type=accumulo-site&tag=1)']);
     });
 
-    it('ATLAS is installed, AMBARI_INFRA isn\'t installed', function () {
+    it('ATLAS is installed, AMBARI_INFRA_SOLR isn\'t installed', function () {
       loadService('ATLAS');
       
expect(controller.constructZookeeperConfigUrlParams(data)).to.eql(['(type=application-properties&tag=1)']);
     });
diff --git a/ambari-web/test/controllers/wizard/step4_test.js 
b/ambari-web/test/controllers/wizard/step4_test.js
index e9942e0..8d17138 100644
--- a/ambari-web/test/controllers/wizard/step4_test.js
+++ b/ambari-web/test/controllers/wizard/step4_test.js
@@ -25,7 +25,7 @@ describe('App.WizardStep4Controller', function () {
 
   var services = [
     'HDFS', 'GANGLIA', 'OOZIE', 'HIVE', 'HBASE', 'PIG', 'SCOOP', 'ZOOKEEPER', 
'SMARTSENSE', 'LOGSEARCH',
-    'YARN', 'MAPREDUCE2', 'FALCON', 'TEZ', 'STORM', 'AMBARI_METRICS', 
'RANGER', 'SPARK', 'SLIDER', 'ATLAS', 'AMBARI_INFRA'
+    'YARN', 'MAPREDUCE2', 'FALCON', 'TEZ', 'STORM', 'AMBARI_METRICS', 
'RANGER', 'SPARK', 'SLIDER', 'ATLAS', 'AMBARI_INFRA_SOLR'
   ];
   var controller;
 
@@ -610,22 +610,22 @@ describe('App.WizardStep4Controller', function () {
     var tests = [
       {
         services: ['HDFS'],
-        dependencies: ['ZOOKEEPER'] 
+        dependencies: ['ZOOKEEPER']
       },
       {
         services: ['STORM'],
-        dependencies: ['ZOOKEEPER'] 
+        dependencies: ['ZOOKEEPER']
       }
     ];
     tests.forEach(function(test) {
       var message = '{0} dependency should be 
{1}'.format(test.services.join(','), test.dependencies.join(','));
       it(message, function() {
-        
+
         controller.clear();
         controller.set('content', 
generateSelectedServicesContent(test.services));
-        
+
         var dependentServicesTest = [];
-        
+
         test.services.forEach(function(serviceName) {
           var service = controller.filterProperty('serviceName', serviceName);
           service.forEach(function(item) {

-- 
To stop receiving notification emails like this one, please contact
oleew...@apache.org.

Reply via email to