|
@@ -526,7 +526,7 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow
|
|
|
});
|
|
|
} else if (this.get('refreshYARNQueueComponents').contains(component.get('componentName'))) {
|
|
|
return App.showConfirmationPopup(function () {
|
|
|
- self.restartComponentAndRefreshYARNQueue(component);
|
|
|
+ self.refreshYARNQueueAndRestartComponent(component);
|
|
|
});
|
|
|
} else {
|
|
|
return App.showConfirmationPopup(function () {
|
|
@@ -535,7 +535,7 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow
|
|
|
}
|
|
|
},
|
|
|
|
|
|
- restartComponentAndRefreshYARNQueue: function (component) {
|
|
|
+ refreshYARNQueueAndRestartComponent: function (component) {
|
|
|
var componentToRestartHost = App.HostComponent.find().findProperty('componentName', component.get('componentName')).get('hostName');
|
|
|
var resourceManagerHost = App.HostComponent.find().findProperty('componentName', 'RESOURCEMANAGER').get('hostName');
|
|
|
var batches = [
|
|
@@ -545,19 +545,14 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow
|
|
|
"uri": App.apiPrefix + "/clusters/" + App.get('clusterName') + "/requests",
|
|
|
"RequestBodyInfo": {
|
|
|
"RequestInfo": {
|
|
|
- "context": "Restart " + component.get('displayName'),
|
|
|
- "command": "RESTART",
|
|
|
- "operation_level": {
|
|
|
- "level": "HOST_COMPONENT",
|
|
|
- "cluster_name": App.get('clusterName'),
|
|
|
- "service_name": component.get('service.serviceName'),
|
|
|
- "hostcomponent_name": component.get('componentName')
|
|
|
- }
|
|
|
+ "context": "Refresh YARN Capacity Scheduler",
|
|
|
+ "command": "REFRESHQUEUES",
|
|
|
+ "parameters/forceRefreshConfigTags": "capacity-scheduler"
|
|
|
},
|
|
|
"Requests/resource_filters": [{
|
|
|
- "service_name": component.get('service.serviceName'),
|
|
|
- "component_name": component.get('componentName'),
|
|
|
- "hosts": componentToRestartHost
|
|
|
+ "service_name": "YARN",
|
|
|
+ "component_name": "RESOURCEMANAGER",
|
|
|
+ "hosts": resourceManagerHost
|
|
|
}]
|
|
|
}
|
|
|
},
|
|
@@ -567,14 +562,19 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow
|
|
|
"uri": App.apiPrefix + "/clusters/" + App.get('clusterName') + "/requests",
|
|
|
"RequestBodyInfo": {
|
|
|
"RequestInfo": {
|
|
|
- "context": "Refresh YARN Capacity Scheduler",
|
|
|
- "command": "REFRESHQUEUES",
|
|
|
- "parameters/forceRefreshConfigTags": "capacity-scheduler"
|
|
|
+ "context": "Restart " + component.get('displayName'),
|
|
|
+ "command": "RESTART",
|
|
|
+ "operation_level": {
|
|
|
+ "level": "HOST_COMPONENT",
|
|
|
+ "cluster_name": App.get('clusterName'),
|
|
|
+ "service_name": component.get('service.serviceName'),
|
|
|
+ "hostcomponent_name": component.get('componentName')
|
|
|
+ }
|
|
|
},
|
|
|
"Requests/resource_filters": [{
|
|
|
- "service_name": "YARN",
|
|
|
- "component_name": "RESOURCEMANAGER",
|
|
|
- "hosts": resourceManagerHost
|
|
|
+ "service_name": component.get('service.serviceName'),
|
|
|
+ "component_name": component.get('componentName'),
|
|
|
+ "hosts": componentToRestartHost
|
|
|
}]
|
|
|
}
|
|
|
}
|