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

hapylestat pushed a commit to branch branch-2.7
in repository https://gitbox.apache.org/repos/asf/ambari.git


The following commit(s) were added to refs/heads/branch-2.7 by this push:
     new 3007339  AMBARI-25523. Ambari UI keeps loading at step3 while adding 
the new namespace for HDFS for the second time (dpidhaiets via dgrinenko) 
(#3235)
3007339 is described below

commit 3007339c4677958df2564fa5572781637c337ba0
Author: pidhaietsdp <[email protected]>
AuthorDate: Wed Sep 30 15:29:17 2020 +0300

    AMBARI-25523. Ambari UI keeps loading at step3 while adding the new 
namespace for HDFS for the second time (dpidhaiets via dgrinenko) (#3235)
---
 ambari-web/app/controllers/main/admin/federation/step3_controller.js | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git 
a/ambari-web/app/controllers/main/admin/federation/step3_controller.js 
b/ambari-web/app/controllers/main/admin/federation/step3_controller.js
index c4e0775..0e2c7ec 100644
--- a/ambari-web/app/controllers/main/admin/federation/step3_controller.js
+++ b/ambari-web/app/controllers/main/admin/federation/step3_controller.js
@@ -105,7 +105,9 @@ App.NameNodeFederationWizardStep3Controller = 
Em.Controller.extend(App.Blueprint
     var hdfsSiteConfigs = configsFromServer.findProperty('type', 
'hdfs-site').properties;
     var nameServices = 
App.HDFSService.find().objectAt(0).get('masterComponentGroups').mapProperty('name');
     ret.nameServicesList = nameServices.join(',');
-    ret.nameservice1 = nameServices[0];
+    ret.nameservice1 = nameServices.find(function (ns){
+      return hdfsSiteConfigs['dfs.namenode.rpc-address.' + ns + '.nn1'];
+    });
     ret.newNameservice = this.get('content.nameServiceId');
     ret.namenode1 = hdfsSiteConfigs['dfs.namenode.rpc-address.' + 
ret.nameservice1 + '.nn1'].split(':')[0];
     ret.namenode2 = hdfsSiteConfigs['dfs.namenode.rpc-address.' + 
ret.nameservice1 + '.nn2'].split(':')[0];

Reply via email to