Browse Source

AMBARI-3164. NameNode HA wizard (rollback): Create API calls and shows the progress for Delete JNs and Additional NN, Start All Services. (onechiporenko)

Oleg Nechiporenko 11 years ago
parent
commit
32c3887ebd

+ 10 - 3
ambari-web/app/controllers/main/admin/highAvailability/rollback_controller.js

@@ -225,13 +225,20 @@ App.HighAvailabilityRollbackController = App.HighAvailabilityProgressPageControl
     this.stopComponent('JOURNALNODE', hostNames);
   },
   deleteJournalNodes: function(){
-
+    var hostNames = this.get('content.masterComponentHosts').filterProperty('component', 'JOURNALNODE').mapProperty('hostName');
+    this.unInstallComponent('JOURNALNODE', hostNames);
   },
   deleteAdditionalNameNode: function(){
-
+    var hostNames = this.get('content.masterComponentHosts').filterProperty('isAddNameNode', true).mapProperty('hostName');
+    this.unInstallComponent('NAMENODE', hostNames);
   },
   startAllServices: function(){
-
+    App.ajax.send({
+      name: 'admin.high_availability.start_all_services',
+      sender: this,
+      success: 'startPolling',
+      error: 'onTaskError'
+    });
   },
 
   onLoadHbaseConfigs: function (data) {