You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ak...@apache.org on 2015/04/14 17:34:56 UTC
ambari git commit: AMBARI-10468. Remove rack awareness experimental,
turn on by default. (akovalenko)
Repository: ambari
Updated Branches:
refs/heads/trunk 5788780b4 -> 1de06bbe2
AMBARI-10468. Remove rack awareness experimental, turn on by default. (akovalenko)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/1de06bbe
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/1de06bbe
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/1de06bbe
Branch: refs/heads/trunk
Commit: 1de06bbe23f1b8764b568ac506ddf23387e405bf
Parents: 5788780
Author: Aleksandr Kovalenko <ak...@hortonworks.com>
Authored: Tue Apr 14 18:04:01 2015 +0300
Committer: Aleksandr Kovalenko <ak...@hortonworks.com>
Committed: Tue Apr 14 18:34:26 2015 +0300
----------------------------------------------------------------------
ambari-web/app/config.js | 3 +-
ambari-web/app/styles/application.less | 30 +++++++-------------
.../main/charts/heatmap/heatmap_host_detail.hbs | 4 +--
ambari-web/app/templates/main/host.hbs | 16 ++++-------
ambari-web/app/templates/main/host/summary.hbs | 6 ++--
ambari-web/app/views/main/host.js | 4 +--
ambari-web/app/views/main/host/details.js | 10 +++----
.../views/main/host/hosts_table_menu_view.js | 21 ++++++--------
8 files changed, 34 insertions(+), 60 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/config.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/config.js b/ambari-web/app/config.js
index 6e06e59..140e7c3 100644
--- a/ambari-web/app/config.js
+++ b/ambari-web/app/config.js
@@ -73,8 +73,7 @@ App.supports = {
installGanglia: false,
opsDuringRollingUpgrade: false,
customizedWidgets: false,
- enhancedConfigs: false,
- setRackId: false
+ enhancedConfigs: false
};
if (App.enableExperimental) {
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/styles/application.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less
index cd404dd..5ccc180 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -2889,20 +2889,6 @@ table.graphs {
}
thead {
background: none repeat scroll 0 0 #F8F8F8;
- th {
- //rack
- &.sort-view-12 {
- width: 15% !important;
- }
- //cpu
- &.sort-view-3 {
- width: 5% !important;
- }
- //ram
- &.sort-view-4 {
- width: 7% !important;
- }
- }
}
.set-rack-id {
@@ -3066,30 +3052,30 @@ table.graphs {
.col6,
td:first-child + td + td + td + td + td + td,
th:first-child + th + th + th + th + th + th {
- width: 10%!important;
+ width: 15%!important;
}
.col7,
td:first-child + td + td + td + td + td + td + td,
th:first-child + th + th + th + th + th + th + th{
- width: 8%!important;
+ width: 5%!important;
}
.col8,
td:first-child + td + td + td + td + td + td + td + td,
th:first-child + th + th + th + th + th + th + th + th{
- width: 9%!important;
+ width: 7%!important;
}
.col9,
td:first-child + td + td + td + td + td + td + td + td + td,
th:first-child + th + th + th + th + th + th + th + th + th{
- width: 9%!important;
+ width: 11%!important;
}
.col10,
td:first-child + td + td + td + td + td + td + td + td + td + td,
th:first-child + th + th + th + th + th + th + th + th + th + th{
- width: 16%!important;
+ width: 10%!important;
}
.col11,
@@ -3098,6 +3084,12 @@ table.graphs {
width: 13%!important;
}
+ .col12,
+ td:first-child + td + td + td + td + td + td + td + td + td + td + td + td,
+ th:first-child + th + th + th + th + th + th + th + th + th + th + th +th{
+ width: 13%!important;
+ }
+
td.name {
overflow: inherit;
overflow-wrap: break-word;
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/templates/main/charts/heatmap/heatmap_host_detail.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/charts/heatmap/heatmap_host_detail.hbs b/ambari-web/app/templates/main/charts/heatmap/heatmap_host_detail.hbs
index 8a5be4e..b94c8c2 100644
--- a/ambari-web/app/templates/main/charts/heatmap/heatmap_host_detail.hbs
+++ b/ambari-web/app/templates/main/charts/heatmap/heatmap_host_detail.hbs
@@ -19,9 +19,7 @@
<b>{{view.details.publicHostName}}</b><br/>
{{t common.os}}: {{view.details.osType}}<br/>
{{t common.ipAddress}}: {{view.details.ip}}<br/>
-{{#if App.supports.setRackId}}
- {{t common.rack}}: {{view.details.rack}}<br/>
-{{/if}}
+{{t common.rack}}: {{view.details.rack}}<br/>
{{#if view.details.metricName}}
{{view.details.metricName}}: {{view.details.metricValue}}<br/>
{{/if}}
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/templates/main/host.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host.hbs b/ambari-web/app/templates/main/host.hbs
index 9f3654f..de7b454 100644
--- a/ambari-web/app/templates/main/host.hbs
+++ b/ambari-web/app/templates/main/host.hbs
@@ -64,9 +64,7 @@
<th> </th>
<th> </th>
{{view view.parentView.ipSort}}
- {{#if App.supports.setRackId}}
- {{view view.parentView.rackSort}}
- {{/if}}
+ {{view view.parentView.rackSort}}
{{view view.parentView.cpuSort}}
{{view view.parentView.memorySort}}
{{view view.parentView.diskUsageSort}}
@@ -83,9 +81,7 @@
<th> </th>
<th> </th>
<th>{{view view.ipFilterView}}</th>
- {{#if App.supports.setRackId}}
- <th>{{view view.rackFilterView}}</th>
- {{/if}}
+ <th>{{view view.rackFilterView}}</th>
<th>{{view view.cpuFilterView}}</th>
<th>{{view view.ramFilterView}}</th>
<th> </th>
@@ -128,11 +124,9 @@
<span rel="ComponentsTooltip" {{bindAttr data-original-title="view.componentsInPassiveStateMessage" class="host.componentsInPassiveStateCount:icon-medkit"}}></span>
</td>
<td class="host-ip">{{host.ip}}</td>
- {{#if App.supports.setRackId}}
- <td rel="UsageTooltip" {{bindAttr title="host.rack"}} class="rack-id">
- {{host.rack}}
- </td>
- {{/if}}
+ <td rel="UsageTooltip" {{bindAttr title="host.rack"}} class="rack-id">
+ {{host.rack}}
+ </td>
<td class="cores-formatted">{{host.coresFormatted}}</td>
<td class="memory-formatted">{{host.memoryFormatted}}</td>
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/templates/main/host/summary.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host/summary.hbs b/ambari-web/app/templates/main/host/summary.hbs
index 31df85d..abb67ba 100644
--- a/ambari-web/app/templates/main/host/summary.hbs
+++ b/ambari-web/app/templates/main/host/summary.hbs
@@ -134,10 +134,8 @@
<dt class="summary-ipaddress-label">{{t common.ipAddress}}:</dt>
<dd class="summary-ipaddress-value"> {{view.content.ip}}</dd>
- {{#if App.supports.setRackId}}
- <dt>{{t common.rack}}:</dt>
- <dd> {{view.content.rack}} <a class="set-rack-id" {{action setRackId view.content target="controller"}}><i class="icon-pencil"></i></a></dd>
- {{/if}}
+ <dt>{{t common.rack}}:</dt>
+ <dd> {{view.content.rack}} <a class="set-rack-id" {{action setRackId view.content target="controller"}}><i class="icon-pencil"></i></a></dd>
<dt class="summary-os-label">{{t common.os}}:</dt>
<dd class="summary-os-value"> {{view.content.osType}} ({{view.content.osArch}})</dd>
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/views/main/host.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js
index 1fee16a..d28a5d8 100644
--- a/ambari-web/app/views/main/host.js
+++ b/ambari-web/app/views/main/host.js
@@ -45,8 +45,8 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, {
requestError: null,
colspan: function () {
- return 10 + +App.get('supports.stackUpgrade') + +App.get('supports.setRackId');
- }.property("App.supports.stackUpgrade", 'App.supports.setRackId'),
+ return 11 + +App.get('supports.stackUpgrade');
+ }.property("App.supports.stackUpgrade"),
/**
* List of hosts in cluster
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/views/main/host/details.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/host/details.js b/ambari-web/app/views/main/host/details.js
index 1f84c0b..efe4827 100644
--- a/ambari-web/app/views/main/host/details.js
+++ b/ambari-web/app/views/main/host/details.js
@@ -47,16 +47,14 @@ App.MainHostDetailsView = Em.View.extend({
maintenance: function(){
var onOff = this.get('isActive') ? "On" : "Off";
- var options = [
+ return [
{action: 'startAllComponents', liClass: (this.get('controller.content.isNotHeartBeating')?'disabled':'enabled'), cssClass: 'icon-play', 'label': this.t('hosts.host.details.startAllComponents')},
{action: 'stopAllComponents', liClass: (this.get('controller.content.isNotHeartBeating')?'disabled':'enabled'), cssClass: 'icon-stop', 'label': this.t('hosts.host.details.stopAllComponents')},
{action: 'restartAllComponents', liClass: (this.get('controller.content.isNotHeartBeating')?'disabled':'enabled'), cssClass: 'icon-repeat', 'label': this.t('hosts.host.details.restartAllComponents')},
{action: 'onOffPassiveModeForHost', liClass:'', cssClass: 'icon-medkit', active:this.get('isActive'), 'label': this.t('passiveState.turn' + onOff)},
- {action: 'deleteHost', liClass:'', cssClass: 'icon-remove', 'label': this.t('hosts.host.details.deleteHost')}];
- if(App.get('supports.setRackId')) {
- options.push({action: 'setRackId', liClass:'', cssClass: 'icon-gear', 'label': this.t('hosts.host.details.setRackId')});
- }
- return options;
+ {action: 'deleteHost', liClass:'', cssClass: 'icon-remove', 'label': this.t('hosts.host.details.deleteHost')},
+ {action: 'setRackId', liClass:'', cssClass: 'icon-gear', 'label': this.t('hosts.host.details.setRackId')}
+ ];
}.property('controller.content','isActive', 'controller.content.isNotHeartBeating'),
didInsertElement: function() {
var self = this;
http://git-wip-us.apache.org/repos/asf/ambari/blob/1de06bbe/ambari-web/app/views/main/host/hosts_table_menu_view.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/host/hosts_table_menu_view.js b/ambari-web/app/views/main/host/hosts_table_menu_view.js
index 127ade3..58bcc46 100644
--- a/ambari-web/app/views/main/host/hosts_table_menu_view.js
+++ b/ambari-web/app/views/main/host/hosts_table_menu_view.js
@@ -237,7 +237,7 @@ App.HostTableMenuView = Em.View.extend({
* @returns {Array}
*/
operationsInfo: function () {
- var options = [
+ return [
Em.Object.create({
label: Em.I18n.t('hosts.host.details.startAllComponents'),
operationData: Em.Object.create({
@@ -276,20 +276,15 @@ App.HostTableMenuView = Em.View.extend({
action: 'PASSIVE_STATE',
message: Em.I18n.t('passiveState.turnOffFor').format('hosts')
})
+ }),
+ Em.Object.create({
+ label: Em.I18n.t('hosts.host.details.setRackId'),
+ operationData: Em.Object.create({
+ action: 'SET_RACK_INFO',
+ message: Em.I18n.t('hosts.host.details.setRackId').format('hosts')
+ })
})
];
- if(App.get('supports.setRackId')) {
- options.push(
- Em.Object.create({
- label: Em.I18n.t('hosts.host.details.setRackId'),
- operationData: Em.Object.create({
- action: 'SET_RACK_INFO',
- message: Em.I18n.t('hosts.host.details.setRackId').format('hosts')
- })
- })
- );
- }
- return options;
}.property(),
/**