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

ababiichuk 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 1fa8541  AMBARI-25227 Unable to move Hive metastore from one node to 
another. (ababiichuk)
1fa8541 is described below

commit 1fa854123fe8fda8cc6126a11f17a4c24daf06d2
Author: aBabiichuk <ababiic...@hortonworks.com>
AuthorDate: Tue Apr 2 20:14:19 2019 +0300

    AMBARI-25227 Unable to move Hive metastore from one node to another. 
(ababiichuk)
---
 .../main/service/reassign/step1_controller.js      |  8 ++---
 .../main/service/reassign/step4_controller.js      | 37 ++--------------------
 2 files changed, 6 insertions(+), 39 deletions(-)

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 12d77d3..02eafa5 100644
--- a/ambari-web/app/controllers/main/service/reassign/step1_controller.js
+++ b/ambari-web/app/controllers/main/service/reassign/step1_controller.js
@@ -27,12 +27,12 @@ App.ReassignMasterWizardStep1Controller = 
Em.Controller.extend({
    */
   dbPropertyMap: {
     'HIVE_SERVER': {
-      type: 'hive-site',
-      name: 'javax.jdo.option.ConnectionDriverName'
+      type: 'hive-env',
+      name: 'hive_database_type'
     },
     'HIVE_METASTORE': {
-      type: 'hive-site',
-      name: 'javax.jdo.option.ConnectionDriverName'
+      type: 'hive-env',
+      name: 'hive_database_type'
     },
     'OOZIE_SERVER': {
       type: 'oozie-site',
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 b95e206..474a327 100644
--- a/ambari-web/app/controllers/main/service/reassign/step4_controller.js
+++ b/ambari-web/app/controllers/main/service/reassign/step4_controller.js
@@ -72,21 +72,6 @@ App.ReassignMasterWizardStep4Controller = 
App.HighAvailabilityProgressPageContro
 
   dependentHostComponents: [],
 
-  dbPropertyMap: {
-    'HIVE_SERVER': {
-      type: 'hive-site',
-      name: 'javax.jdo.option.ConnectionDriverName'
-    },
-    'HIVE_METASTORE': {
-      type: 'hive-site',
-      name: 'javax.jdo.option.ConnectionDriverName'
-    },
-    'OOZIE_SERVER': {
-      type: 'oozie-site',
-      name: 'oozie.service.JPAService.jdbc.url'
-    }
-  },
-
   /**
    * load step info
    */
@@ -659,30 +644,12 @@ App.ReassignMasterWizardStep4Controller = 
App.HighAvailabilityProgressPageContro
     return propertiesMap[this.get('content.reassign.service_id')];
   }.property(),
 
-  dbType: function() {
-    var databaseTypes = /MySQL|PostgreS|Oracle|Derby|MSSQL|Anywhere/gi,
-      dbPropertyMapItem = Em.getWithDefault(this.get('dbPropertyMap'), 
this.get('content.reassign.component_name'), null),
-      databasePropMatch,
-      databaseProp,
-      result;
-
-    if (dbPropertyMapItem) {
-      databaseProp = Em.getWithDefault(this.get('content.configs'), 
dbPropertyMapItem.type, {})[dbPropertyMapItem.name];
-      databasePropMatch = databaseProp && databaseProp.match(databaseTypes);
-      if (databasePropMatch) {
-        result = databasePropMatch[0];
-      }
-    }
-
-    return result;
-  }.property(),
-
   prepareDBCheckAction: function() {
     var params = this.get('preparedDBProperties');
 
     var ambariProperties = 
App.router.get('clusterController.ambariProperties');
 
-    params['db_name'] = this.get('dbType');
+    params['db_name'] = this.get('content.databaseType');
     params['jdk_location'] = ambariProperties['jdk_location'];
     params['jdk_name'] = ambariProperties['jdk.name'];
     params['java_home'] = ambariProperties['java.home'];
@@ -774,7 +741,7 @@ App.ReassignMasterWizardStep4Controller = 
App.HighAvailabilityProgressPageContro
 
   testDBRetryTooltip: function() {
     var db_host = this.get('content.serviceProperties.database_hostname');
-    var db_type = this.get('dbType');
+    var db_type = this.get('content.databaseType');
     var db_props = this.get('preparedDBProperties');
 
     return 
Em.I18n.t('services.reassign.step4.tasks.testDBConnection.tooltip').format(

Reply via email to