You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ja...@apache.org on 2015/03/03 22:06:06 UTC

ambari git commit: AMBARI-9909. Move Master Wizard 'Manual Commands' page doesn't load in secure cluster for Webhcat server and MySQL server.

Repository: ambari
Updated Branches:
  refs/heads/branch-2.0.0 17c1a8d52 -> f78854ec1


AMBARI-9909. Move Master Wizard 'Manual Commands' page doesn't load in secure cluster for Webhcat server and MySQL server.


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

Branch: refs/heads/branch-2.0.0
Commit: f78854ec151e7217f49de8d31943784452b324c2
Parents: 17c1a8d
Author: Jaimin Jetly <ja...@hortonworks.com>
Authored: Tue Mar 3 13:05:32 2015 -0800
Committer: Jaimin Jetly <ja...@hortonworks.com>
Committed: Tue Mar 3 13:05:32 2015 -0800

----------------------------------------------------------------------
 .../main/service/reassign/step1_controller.js   |  2 +-
 .../main/service/reassign/step4_controller.js   | 35 ++++++++++++++++++++
 .../main/service/reassign_controller.js         | 18 ++++++----
 .../views/main/service/reassign/step5_view.js   |  4 +++
 4 files changed, 51 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/f78854ec/ambari-web/app/controllers/main/service/reassign/step1_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/service/reassign/step1_controller.js b/ambari-web/app/controllers/main/service/reassign/step1_controller.js
index d417dbf..0cd333b 100644
--- a/ambari-web/app/controllers/main/service/reassign/step1_controller.js
+++ b/ambari-web/app/controllers/main/service/reassign/step1_controller.js
@@ -102,7 +102,7 @@ App.ReassignMasterWizardStep1Controller = Em.Controller.extend({
     databaseType = databaseProperty.match(/MySQL|PostgreS|Oracle|Derby|MSSQL/gi)[0];
     this.set('databaseType', databaseType);
 
-    if (databaseType !== 'derby') {
+    if (this.get('content.reassign.component_name') == 'OOZIE_SERVER' && databaseType !== 'derby') {
       App.router.reassignMasterController.set('content.hasManualSteps', false);
     } else {
       App.router.reassignMasterController.set('content.hasManualSteps', true);

http://git-wip-us.apache.org/repos/asf/ambari/blob/f78854ec/ambari-web/app/controllers/main/service/reassign/step4_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/service/reassign/step4_controller.js b/ambari-web/app/controllers/main/service/reassign/step4_controller.js
index 0d2d658..4a37f88 100644
--- a/ambari-web/app/controllers/main/service/reassign/step4_controller.js
+++ b/ambari-web/app/controllers/main/service/reassign/step4_controller.js
@@ -206,6 +206,41 @@ App.ReassignMasterWizardStep4Controller = App.HighAvailabilityProgressPageContro
           principal: 'oozie.service.HadoopAccessorService.kerberos.principal'
         }
       ]
+    },
+    {
+      componentName: 'WEBHCAT_SERVER',
+      configs: [
+        {
+          site: 'webhcat-site',
+          keytab: 'templeton.kerberos.keytab',
+          principal: 'templeton.kerberos.principal'
+        }
+      ]
+    },
+    {
+      componentName: 'HIVE_SERVER',
+      configs: [
+        {
+          site: 'hive-site',
+          keytab: 'hive.server2.authentication.kerberos.keytab',
+          principal: 'hive.server2.authentication.kerberos.principal'
+        },
+        {
+          site: 'hive-site',
+          keytab: 'hive.server2.authentication.spnego.keytab',
+          principal: 'hive.server2.authentication.spnego.principal'
+        }
+      ]
+    },
+    {
+      componentName: 'HIVE_METASTORE',
+      configs: [
+        {
+          site: 'hive-site',
+          keytab: 'hive.metastore.kerberos.keytab.file',
+          principal: 'hive.metastore.kerberos.principal'
+        }
+      ]
     }
 
   ],

http://git-wip-us.apache.org/repos/asf/ambari/blob/f78854ec/ambari-web/app/controllers/main/service/reassign_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/service/reassign_controller.js b/ambari-web/app/controllers/main/service/reassign_controller.js
index 4e0ca4d..2793491 100644
--- a/ambari-web/app/controllers/main/service/reassign_controller.js
+++ b/ambari-web/app/controllers/main/service/reassign_controller.js
@@ -59,7 +59,8 @@ App.ReassignMasterController = App.WizardController.extend({
     hasManualSteps: false,
     hasCheckDBStep: false,
     componentsWithCheckDBStep: ['HIVE_METASTORE', 'HIVE_SERVER', 'OOZIE_SERVER'],
-    securityEnabled: false
+    securityEnabled: false,
+    componentsWithoutSecurityConfigs: ['MYSQL_SERVER']
   }),
 
   /**
@@ -287,12 +288,15 @@ App.ReassignMasterController = App.WizardController.extend({
   loadDatabaseType: function () {
     var databaseType = this.getDBProperty('databaseType');
     this.set('content.databaseType', databaseType);
-
-    if (this.get('content.hasCheckDBStep') && databaseType && databaseType !== 'derby') {
-      // components with manual commands
-      var manual = App.router.reassignMasterController.get('content.componentsWithManualCommands').without('OOZIE_SERVER');
-      App.router.reassignMasterController.set('content.hasManualSteps', false);
-      App.router.reassignMasterController.set('content.componentsWithManualCommands', manual);
+    var component = this.get('content.reassign.component_name');
+
+    if (component === 'OOZIE_SERVER') {
+      if (this.get('content.hasCheckDBStep') && databaseType && databaseType !== 'derby') {
+        // components with manual commands
+        var manual = App.router.reassignMasterController.get('content.componentsWithManualCommands').without('OOZIE_SERVER');
+        App.router.reassignMasterController.set('content.hasManualSteps', false);
+        App.router.reassignMasterController.set('content.componentsWithManualCommands', manual);
+      }
     }
   },
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/f78854ec/ambari-web/app/views/main/service/reassign/step5_view.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/service/reassign/step5_view.js b/ambari-web/app/views/main/service/reassign/step5_view.js
index 61ea860..fb59bbe 100644
--- a/ambari-web/app/views/main/service/reassign/step5_view.js
+++ b/ambari-web/app/views/main/service/reassign/step5_view.js
@@ -49,6 +49,10 @@ App.ReassignMasterWizardStep5View = Em.View.extend({
   securityNotice: function () {
     var secureConfigs = this.get('controller.content.secureConfigs');
     var proceedMsg = Em.I18n.t('services.reassign.step5.body.proceedMsg');
+    var hasSecureConfigs = !this.get('controller.content.componentsWithoutSecurityConfigs').contains(this.get('controller.content.reassign.component_name'));
+    if(!hasSecureConfigs) {
+      secureConfigs = [];
+    }
     if (!this.get('controller.content.securityEnabled') || !secureConfigs.length) {
       return proceedMsg;
     }