ambari git commit: AMBARI-10756. Combobox items on the right column should be aligned right (onechiporenko)

2015-04-27 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk efb923547 - fdf2e2ab1


AMBARI-10756. Combobox items on the right column should be aligned right 
(onechiporenko)


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

Branch: refs/heads/trunk
Commit: fdf2e2ab13a1ce9724f26dcaa9c16adb20982dcc
Parents: efb9235
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Mon Apr 27 12:47:43 2015 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Mon Apr 27 12:47:43 2015 +0300

--
 ambari-web/app/models/configs/section.js| 72 ++--
 ambari-web/app/models/configs/sub_section.js| 71 +--
 .../configs/widgets/combo_config_widget.hbs |  2 +-
 .../configs/widget_popover_support_test.js  | 62 -
 4 files changed, 132 insertions(+), 75 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fdf2e2ab/ambari-web/app/models/configs/section.js
--
diff --git a/ambari-web/app/models/configs/section.js 
b/ambari-web/app/models/configs/section.js
index 56bcf58..92909fb 100644
--- a/ambari-web/app/models/configs/section.js
+++ b/ambari-web/app/models/configs/section.js
@@ -19,16 +19,57 @@
 var App = require('app');
 
 App.Section = DS.Model.extend({
+
   id: DS.attr('string'),
+
+  /**
+   * @type {string}
+   */
   name: DS.attr('string'),
+
+  /**
+   * @type {string}
+   */
   displayName: DS.attr('string'),
+
+  /**
+   * @type {number}
+   */
   rowIndex: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   rowSpan: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   columnIndex: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   columnSpan: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   sectionColumns: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   sectionRows: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {App.SubSection[]}
+   */
   subSections: DS.hasMany('App.SubSection'),
+
+  /**
+   * @type {App.Tab}
+   */
   tab: DS.belongsTo('App.Tab'),
 
   /**
@@ -40,29 +81,48 @@ App.Section = DS.Model.extend({
 return errors.length ? errors.reduce(Em.sum) : 0;
   }.property('subSections.@each.errorsCount'),
 
+  /**
+   * @type {boolean}
+   */
   isFirstRow: function () {
 return this.get('rowIndex') == 0;
-  }.property(),
+  }.property('rowIndex'),
 
+  /**
+   * @type {boolean}
+   */
   isMiddleRow: function () {
 return this.get('rowIndex') != 0  (this.get('rowIndex') + 
this.get('rowSpan')  this.get('tab.rows'));
-  }.property(),
+  }.property('rowIndex', 'rowSpan', 'tab.rows'),
 
+  /**
+   * @type {boolean}
+   */
   isLastRow: function () {
 return this.get('rowIndex') + this.get('rowSpan') == this.get('tab.rows');
-  }.property(),
+  }.property('rowIndex', 'rowSpan', 'tab.rows'),
 
+  /**
+   * @type {boolean}
+   */
   isFirstColumn: function () {
 return this.get('columnIndex') == 0;
-  }.property(),
+  }.property('columnIndex'),
 
+  /**
+   * @type {boolean}
+   */
   isMiddleColumn: function () {
 return this.get('columnIndex') != 0  (this.get('columnIndex') + 
this.get('columnSpan')  this.get('tab.columns'));
-  }.property(),
+  }.property('columnIndex', 'columnSpan', 'tab.columns'),
 
+  /**
+   * @type {boolean}
+   */
   isLastColumn: function () {
 return this.get('columnIndex') + this.get('columnSpan') == 
this.get('tab.columns');
-  }.property()
+  }.property('columnIndex', 'columnSpan', 'tab.columns')
+
 });
 
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/fdf2e2ab/ambari-web/app/models/configs/sub_section.js
--
diff --git a/ambari-web/app/models/configs/sub_section.js 
b/ambari-web/app/models/configs/sub_section.js
index 1767b5d..54d3559 100644
--- a/ambari-web/app/models/configs/sub_section.js
+++ b/ambari-web/app/models/configs/sub_section.js
@@ -19,16 +19,57 @@
 var App = require('app');
 
 App.SubSection = DS.Model.extend({
+
   id: DS.attr('string'),
+
+  /**
+   * @type {string}
+   */
   name: DS.attr('string'),
+
+  /**
+   * @type {string}
+   */
   displayName: DS.attr('string'),
+
+  /**
+   * @type {boolean}
+   */
   border: DS.attr('boolean', {defaultValue: false}),
+
+  /**
+   * @type {number}
+   */
   rowIndex: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   columnIndex: DS.attr('number', {defaultValue: 1}),
+
+  /**
+   * @type {number}
+   */
   rowSpan: DS.attr('number', {defaultValue: 1}),

ambari git commit: AMBARI-10755 NodeManager Disk and Network widget appears blank. (atkach)

2015-04-27 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk 9077a9d30 - efb923547


AMBARI-10755 NodeManager Disk and Network widget appears blank. (atkach)


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

Branch: refs/heads/trunk
Commit: efb92354748c29a13f8dbcd7ca12e092ee42f013
Parents: 9077a9d
Author: Andrii Tkach atk...@hortonworks.com
Authored: Mon Apr 27 11:50:24 2015 +0300
Committer: Andrii Tkach atk...@hortonworks.com
Committed: Mon Apr 27 12:25:52 2015 +0300

--
 ambari-web/app/assets/test/tests.js |   2 +
 .../service/widgets/create/step1_controller.js  |   4 +
 .../service/widgets/create/step2_controller.js  |   7 +
 .../main/service/widgets/create/step2.hbs   |   4 +-
 .../views/common/widget/graph_widget_view.js|  39 +-
 .../widgets/create/step1_controller_test.js |  89 +
 .../common/widget/graph_widget_view_test.js | 129 +++
 7 files changed, 270 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/efb92354/ambari-web/app/assets/test/tests.js
--
diff --git a/ambari-web/app/assets/test/tests.js 
b/ambari-web/app/assets/test/tests.js
index 14a0ea8..055f447 100644
--- a/ambari-web/app/assets/test/tests.js
+++ b/ambari-web/app/assets/test/tests.js
@@ -86,6 +86,7 @@ var files = ['test/init_model_test',
   'test/controllers/main/service/reassign/step4_controller_test',
   'test/controllers/main/service/reassign/step6_controller_test',
   'test/controllers/main/service/reassign/step7_controller_test',
+  'test/controllers/main/service/widgets/create/step1_controller_test',
   'test/controllers/main/dashboard_test',
   'test/controllers/main/host_test',
   'test/controllers/main/service/item_test',
@@ -176,6 +177,7 @@ var files = ['test/init_model_test',
   'test/views/common/sort_view_test',
   'test/views/common/custom_date_popup_test',
   'test/views/common/progress_bar_view_test',
+  'test/views/common/widget/graph_widget_view_test',
   'test/views/main/admin_test',
   'test/views/main/dashboard_test',
   'test/views/main/menu_test',

http://git-wip-us.apache.org/repos/asf/ambari/blob/efb92354/ambari-web/app/controllers/main/service/widgets/create/step1_controller.js
--
diff --git 
a/ambari-web/app/controllers/main/service/widgets/create/step1_controller.js 
b/ambari-web/app/controllers/main/service/widgets/create/step1_controller.js
index 92e9615..5bc6b2f 100644
--- a/ambari-web/app/controllers/main/service/widgets/create/step1_controller.js
+++ b/ambari-web/app/controllers/main/service/widgets/create/step1_controller.js
@@ -54,6 +54,10 @@ App.WidgetWizardStep1Controller = Em.Controller.extend({
 });
   }.property('widgetType'),
 
+  /**
+   * choose widget type and proceed to the next step
+   * @param {object} event
+   */
   chooseOption: function (event) {
 this.set('widgetType', event.context);
 this.next();

http://git-wip-us.apache.org/repos/asf/ambari/blob/efb92354/ambari-web/app/controllers/main/service/widgets/create/step2_controller.js
--
diff --git 
a/ambari-web/app/controllers/main/service/widgets/create/step2_controller.js 
b/ambari-web/app/controllers/main/service/widgets/create/step2_controller.js
index 3051ffd..0d5f414 100644
--- a/ambari-web/app/controllers/main/service/widgets/create/step2_controller.js
+++ b/ambari-web/app/controllers/main/service/widgets/create/step2_controller.js
@@ -76,6 +76,13 @@ App.WidgetWizardStep2Controller = Em.Controller.extend({
   widgetPropertiesViews: [],
 
   /**
+   * @type {boolean}
+   */
+  isEditWidget: function () {
+return this.get('content.controllerName') === 'widgetEditController';
+  }.property('content.controllerName'),
+
+  /**
* metrics filtered by type
* @type {Array}
*/

http://git-wip-us.apache.org/repos/asf/ambari/blob/efb92354/ambari-web/app/templates/main/service/widgets/create/step2.hbs
--
diff --git a/ambari-web/app/templates/main/service/widgets/create/step2.hbs 
b/ambari-web/app/templates/main/service/widgets/create/step2.hbs
index 7723995..47d206e 100644
--- a/ambari-web/app/templates/main/service/widgets/create/step2.hbs
+++ b/ambari-web/app/templates/main/service/widgets/create/step2.hbs
@@ -49,7 +49,9 @@
 
 
   div class=btn-area
-button id=add-widget-step2-back class=btn {{action back}}larr; {{t 
common.back}}/button
+{{#unless isEditWidget}}
+  button id=add-widget-step2-back 

ambari git commit: AMBARI-10758. JS error appears on scroll host configs page (onechiporenko)

2015-04-27 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk fdf2e2ab1 - 85e595b14


AMBARI-10758. JS error appears on scroll host configs page (onechiporenko)


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

Branch: refs/heads/trunk
Commit: 85e595b149e21002d3e3abbe0e234e983bda2713
Parents: fdf2e2a
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Mon Apr 27 13:20:42 2015 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Mon Apr 27 13:20:42 2015 +0300

--
 ambari-web/app/utils/pages/scroll_manager.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/85e595b1/ambari-web/app/utils/pages/scroll_manager.js
--
diff --git a/ambari-web/app/utils/pages/scroll_manager.js 
b/ambari-web/app/utils/pages/scroll_manager.js
index 16b08f6..9f9f48b8 100644
--- a/ambari-web/app/utils/pages/scroll_manager.js
+++ b/ambari-web/app/utils/pages/scroll_manager.js
@@ -73,7 +73,7 @@ App.ScrollManager = Em.Object.create({
   self.get('elements').forEach(function (element) {
 var defaultTop, defaultLeft;
 var infoBar = $(Em.get(element, 'updatedElementSelector'));
-var versionSlider = $(Em.get(element, 'elementForLeftOffsetSelector'));
+var elementForLeftOffset = $(Em.get(element, 
'elementForLeftOffsetSelector'));
 var scrollTop = $(window).scrollTop();
 var scrollLeft = $(window).scrollLeft();
 if (!infoBar.length) {
@@ -81,7 +81,7 @@ App.ScrollManager = Em.Object.create({
 }
 defaultTop = (infoBar.get(0).getBoundingClientRect()  
infoBar.get(0).getBoundingClientRect().top) || Em.get(element, 'defaultTop');
 // keep the version info bar always aligned to version slider
-defaultLeft = (versionSlider.get(0).getBoundingClientRect()  
versionSlider.get(0).getBoundingClientRect().left);
+defaultLeft = elementForLeftOffset.get(0)  
elementForLeftOffset.get(0).getBoundingClientRect()  
elementForLeftOffset.get(0).getBoundingClientRect().left;
 infoBar.css(calculatePosition(Em.get(element, 'movedTop'), defaultTop, 
scrollTop, defaultLeft, scrollLeft));
   });
 });



ambari git commit: AMBARI-10759 Remove space between tab name and configs section. (ababiichuk)

2015-04-27 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 85e595b14 - ebea5413f


AMBARI-10759 Remove space between tab name and configs section. (ababiichuk)


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

Branch: refs/heads/trunk
Commit: ebea5413f93eb63e545d12fffd7f8cc1c3a1191b
Parents: 85e595b
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Mon Apr 27 13:27:45 2015 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Mon Apr 27 13:45:36 2015 +0300

--
 ambari-web/app/styles/application.less| 3 ++-
 ambari-web/app/templates/common/configs/service_config.hbs| 2 +-
 ambari-web/app/templates/common/configs/service_config_wizard.hbs | 2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ebea5413/ambari-web/app/styles/application.less
--
diff --git a/ambari-web/app/styles/application.less 
b/ambari-web/app/styles/application.less
index 761b930..cf0ceee 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -5622,6 +5622,7 @@ input[type=radio].align-checkbox, 
input[type=checkbox].align-checkbox {
   .section-layout-container {
 width: 104%; // fallback option
 width: ~calc(100% + 40px);
+margin-top: -20px;
 .config-section-table {
   width: 100%;
   border-spacing: 20px;
@@ -5630,7 +5631,7 @@ input[type=radio].align-checkbox, 
input[type=checkbox].align-checkbox {
   margin: 0 -20px;
   .config-section {
 height: 100%;
-padding: 30px;
+padding: 0 30px 20px 30px;
 border: 1px solid #aaa;
 vertical-align: top;
 h4 {

http://git-wip-us.apache.org/repos/asf/ambari/blob/ebea5413/ambari-web/app/templates/common/configs/service_config.hbs
--
diff --git a/ambari-web/app/templates/common/configs/service_config.hbs 
b/ambari-web/app/templates/common/configs/service_config.hbs
index e516dc4..8b7ccbe 100644
--- a/ambari-web/app/templates/common/configs/service_config.hbs
+++ b/ambari-web/app/templates/common/configs/service_config.hbs
@@ -92,7 +92,7 @@
 /div
   /div
   {{#if view.supportsConfigLayout}}
-ul class=nav nav-tabs
+ul class=nav nav-tabs mbm
   {{#each tab in view.tabs}}
 {{#unless tab.isHiddenByFilter}}
   li {{bindAttr class=tab.isActive:active }}

http://git-wip-us.apache.org/repos/asf/ambari/blob/ebea5413/ambari-web/app/templates/common/configs/service_config_wizard.hbs
--
diff --git a/ambari-web/app/templates/common/configs/service_config_wizard.hbs 
b/ambari-web/app/templates/common/configs/service_config_wizard.hbs
index cba158b..6d51e7f 100644
--- a/ambari-web/app/templates/common/configs/service_config_wizard.hbs
+++ b/ambari-web/app/templates/common/configs/service_config_wizard.hbs
@@ -49,7 +49,7 @@
 {{/if}}
 
 {{#if view.supportsConfigLayout}}
-  ul class=nav nav-tabs
+  ul class=nav nav-tabs mbm
 {{#each tab in view.tabs}}
   li {{bindAttr class=tab.isActive:active }}
 a href=# {{bindAttr data-target=tab.headingClass}} 
data-toggle=tab



ambari git commit: AMBARI-10775. Some configs have duplicated labels on enhanced tab.

2015-04-27 Thread srimanth
Repository: ambari
Updated Branches:
  refs/heads/trunk ea080a259 - 35a99761e


AMBARI-10775. Some configs have duplicated labels on enhanced tab.


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

Branch: refs/heads/trunk
Commit: 35a99761ef38c13054c677fe7156f56ed47d4931
Parents: ea080a2
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Mon Apr 27 12:40:18 2015 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Mon Apr 27 12:40:24 2015 -0700

--
 .../common/configs/widgets/directory_config_widget.hbs  | 5 +
 1 file changed, 1 insertion(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/35a99761/ambari-web/app/templates/common/configs/widgets/directory_config_widget.hbs
--
diff --git 
a/ambari-web/app/templates/common/configs/widgets/directory_config_widget.hbs 
b/ambari-web/app/templates/common/configs/widgets/directory_config_widget.hbs
index 346330a..d8d1483 100644
--- 
a/ambari-web/app/templates/common/configs/widgets/directory_config_widget.hbs
+++ 
b/ambari-web/app/templates/common/configs/widgets/directory_config_widget.hbs
@@ -21,13 +21,10 @@
 div class=clearfix/div
 span class=widget-config-label{{view.config.displayName}}/span
   {{/if}}
-{{#if view.isOriginalSCP}}
-  span class=widget-config-label{{view.config.displayName}}/span
-{{/if}}
div class=directory-textarea-wrapper
  {{view view.configView}}
/div
div class=right
  {{template templates/common/configs/widgets/controls}}
/div
-/div
\ No newline at end of file
+/div



ambari git commit: AMBARI-10742 - RU: HiveServer2 Cannot Deregister During Upgrade Due To Config Path Missing (jonathanhurley)

2015-04-27 Thread jonathanhurley
Repository: ambari
Updated Branches:
  refs/heads/trunk 14395f9b4 - ea080a259


AMBARI-10742 - RU: HiveServer2 Cannot Deregister During Upgrade Due To Config 
Path Missing (jonathanhurley)


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

Branch: refs/heads/trunk
Commit: ea080a25966e5b18cd31a9c52bfd669d0dbae6b2
Parents: 14395f9
Author: Jonathan Hurley jhur...@hortonworks.com
Authored: Fri Apr 24 19:20:59 2015 -0400
Committer: Jonathan Hurley jhur...@hortonworks.com
Committed: Mon Apr 27 15:38:16 2015 -0400

--
 .../HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py | 2 +-
 .../src/test/python/stacks/2.0.6/HIVE/test_hive_server.py  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ea080a25/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
--
diff --git 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
index 4db3df6..0b29d6f 100644
--- 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
+++ 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
@@ -50,7 +50,7 @@ def pre_upgrade_deregister():
 raise Fail('Unable to determine the current HiveServer2 version to 
deregister.')
 
   # deregister
-  command = 'hive --service hiveserver2 --deregister ' + 
current_hiveserver_version
+  command = format('hive --config {hive_server_conf_dir} --service hiveserver2 
--deregister ' + current_hiveserver_version)
   Execute(command, user=params.hive_user, path=params.execute_path, tries=1 )
 
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/ea080a25/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
--
diff --git 
a/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py 
b/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
index cb67bd1..fc9ba66 100644
--- a/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
+++ b/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
@@ -559,7 +559,7 @@ class TestHiveServer(RMFTestCase):
  call_mocks = [(0,hive-server2 - 2.2.0.0-2041), (0,hive-server2 - 
2.2.0.0-2041)]
 )
 
-self.assertResourceCalled('Execute', 'hive --service hiveserver2 
--deregister 2.2.0.0-2041',
+self.assertResourceCalled('Execute', 'hive --config /etc/hive/conf.server 
--service hiveserver2 --deregister 2.2.0.0-2041',
   
path=['/bin:/usr/hdp/current/hive-server2/bin:/usr/hdp/current/hadoop-client/bin'],
   tries=1, user='hive')
 



ambari git commit: AMBARI-10742 - RU: HiveServer2 Cannot Deregister During Upgrade Due To Config Path Missing (jonathanhurley)

2015-04-27 Thread jonathanhurley
Repository: ambari
Updated Branches:
  refs/heads/branch-2.0.maint c32403f90 - 020d8d300


AMBARI-10742 - RU: HiveServer2 Cannot Deregister During Upgrade Due To Config 
Path Missing (jonathanhurley)


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

Branch: refs/heads/branch-2.0.maint
Commit: 020d8d3003b064814913b4e897dede11b1b9b65b
Parents: c32403f
Author: Jonathan Hurley jhur...@hortonworks.com
Authored: Fri Apr 24 19:20:59 2015 -0400
Committer: Jonathan Hurley jhur...@hortonworks.com
Committed: Mon Apr 27 15:39:55 2015 -0400

--
 .../HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py | 2 +-
 .../src/test/python/stacks/2.0.6/HIVE/test_hive_server.py  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/020d8d30/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
--
diff --git 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
index 4db3df6..0b29d6f 100644
--- 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
+++ 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server_upgrade.py
@@ -50,7 +50,7 @@ def pre_upgrade_deregister():
 raise Fail('Unable to determine the current HiveServer2 version to 
deregister.')
 
   # deregister
-  command = 'hive --service hiveserver2 --deregister ' + 
current_hiveserver_version
+  command = format('hive --config {hive_server_conf_dir} --service hiveserver2 
--deregister ' + current_hiveserver_version)
   Execute(command, user=params.hive_user, path=params.execute_path, tries=1 )
 
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/020d8d30/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
--
diff --git 
a/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py 
b/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
index 287713a..ac2eba1 100644
--- a/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
+++ b/ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
@@ -513,7 +513,7 @@ class TestHiveServer(RMFTestCase):
  hdp_stack_version = self.UPGRADE_STACK_VERSION,
  target = RMFTestCase.TARGET_COMMON_SERVICES )
 
-self.assertResourceCalled('Execute', 'hive --service hiveserver2 
--deregister 2.2.0.0-2041',
+self.assertResourceCalled('Execute', 'hive --config /etc/hive/conf.server 
--service hiveserver2 --deregister 2.2.0.0-2041',
   
path=['/bin:/usr/hdp/current/hive-server2/bin:/usr/hdp/current/hadoop-client/bin'],
   tries=1, user='hive')
 



ambari git commit: AMBARI-10715. Rightmost column widget hover interferes with widget control usability (Richard Zang via srimanth)

2015-04-27 Thread srimanth
Repository: ambari
Updated Branches:
  refs/heads/trunk fa6194265 - 14395f9b4


AMBARI-10715. Rightmost column widget hover interferes with widget control 
usability (Richard Zang via srimanth)


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

Branch: refs/heads/trunk
Commit: 14395f9b4ad3720804505922304734537070cf4a
Parents: fa61942
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Mon Apr 27 12:35:03 2015 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Mon Apr 27 12:35:09 2015 -0700

--
 .../app/mixins/main/service/configs/widget_popover_support.js| 2 ++
 ambari-web/app/styles/application.less   | 4 
 2 files changed, 6 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/14395f9b/ambari-web/app/mixins/main/service/configs/widget_popover_support.js
--
diff --git 
a/ambari-web/app/mixins/main/service/configs/widget_popover_support.js 
b/ambari-web/app/mixins/main/service/configs/widget_popover_support.js
index 5a1a4cb..98b6f50 100644
--- a/ambari-web/app/mixins/main/service/configs/widget_popover_support.js
+++ b/ambari-web/app/mixins/main/service/configs/widget_popover_support.js
@@ -48,7 +48,9 @@ App.WidgetPopoverSupport = Em.Mixin.create({
 
   initPopover: function () {
 if (this.get('isPopoverEnabled') !== false) {
+  var leftPopoverTemplate = 'div class=popover 
config-widget-left-popoverdiv class=arrow/divdiv 
class=popover-innerh3 class=popover-title/h3div 
class=popover-contentp/p/div/div/div';
   App.popover(this.$('.original-widget'), {
+template: this.get('popoverPlacement') == 'left'? leftPopoverTemplate 
: undefined,
 title: 
Em.I18n.t('installer.controls.serviceConfigPopover.title').format(
   this.get('configLabel'),
   (this.get('configLabel') == this.get('config.name')) ? '' : 
this.get('config.name')

http://git-wip-us.apache.org/repos/asf/ambari/blob/14395f9b/ambari-web/app/styles/application.less
--
diff --git a/ambari-web/app/styles/application.less 
b/ambari-web/app/styles/application.less
index ae7ba07..fdea9e5 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -5685,3 +5685,7 @@ input[type=radio].align-checkbox, 
input[type=checkbox].align-checkbox {
 }
   }
 }
+
+.config-widget-left-popover {
+  margin-left: -10px;
+}
\ No newline at end of file



ambari git commit: AMBARI-10754 Final buttons are not present for Custom core-site properties. (ababiichk)

2015-04-27 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 623929f58 - 9077a9d30


AMBARI-10754 Final buttons are not present for Custom core-site properties. 
(ababiichk)


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

Branch: refs/heads/trunk
Commit: 9077a9d3044302860d543907e23542c25603f79f
Parents: 623929f
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Mon Apr 27 11:50:08 2015 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Mon Apr 27 11:50:08 2015 +0300

--
 ambari-web/app/utils/config.js  | 21 ++-
 .../configs/service_configs_by_category_view.js | 11 +---
 ambari-web/test/utils/config_test.js| 59 
 3 files changed, 80 insertions(+), 11 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/9077a9d3/ambari-web/app/utils/config.js
--
diff --git a/ambari-web/app/utils/config.js b/ambari-web/app/utils/config.js
index 54a4609..874c7e9 100644
--- a/ambari-web/app/utils/config.js
+++ b/ambari-web/app/utils/config.js
@@ -332,7 +332,7 @@ App.config = Em.Object.create({
   showLabel: true,
   serviceName: serviceName,
   belongsToService: [],
-  supportsFinal: advancedConfig ? Em.get(advancedConfig, 
'supportsFinal') : false
+  supportsFinal: advancedConfig ? Em.get(advancedConfig, 
'supportsFinal') : this.shouldSupportFinal(serviceName, _tag.siteName)
 
 });
 
@@ -1552,6 +1552,25 @@ App.config = Em.Object.create({
*/
   saveConfigsToModel: function (data) {
 App.stackConfigPropertiesMapper.map(data);
+  },
+
+  /**
+   * Check if config filename supports final attribute
+   * @param serviceName
+   * @param filename
+   * @returns {boolean}
+   */
+  shouldSupportFinal: function (serviceName, filename) {
+if (!serviceName || serviceName == 'MISC' || !filename) {
+  return false;
+} else {
+  var stackService = App.StackService.find().findProperty('serviceName', 
serviceName);
+  var supportsFinal = 
this.getConfigTypesInfoFromService(stackService).supportsFinal;
+  var matchingConfigType = supportsFinal.find(function (configType) {
+return filename.startsWith(configType);
+  });
+  return !!matchingConfigType;
+}
   }
 
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/9077a9d3/ambari-web/app/views/common/configs/service_configs_by_category_view.js
--
diff --git 
a/ambari-web/app/views/common/configs/service_configs_by_category_view.js 
b/ambari-web/app/views/common/configs/service_configs_by_category_view.js
index 1187a4d..d9fb8f2 100644
--- a/ambari-web/app/views/common/configs/service_configs_by_category_view.js
+++ b/ambari-web/app/views/common/configs/service_configs_by_category_view.js
@@ -378,16 +378,7 @@ App.ServiceConfigsByCategoryView = 
Em.View.extend(App.UserPref, App.ConfigOverri
 var configsOfFile = service.get('configs').filterProperty('filename', 
siteFileName);
 var siteFileProperties = 
App.config.get('configMapping').all().filterProperty('filename', siteFileName);
 
-function shouldSupportFinal(filename) {
-  var stackService = 
App.StackService.find().findProperty('serviceName', serviceName);
-  var supportsFinal = 
App.config.getConfigTypesInfoFromService(stackService).supportsFinal;
-  var matchingConfigType = supportsFinal.find(function (configType) {
-return filename.startsWith(configType);
-  });
-  return !!matchingConfigType;
-}
-
-var supportsFinal = (serviceName == 'MISC') ? false: (siteFileName ? 
shouldSupportFinal(siteFileName) : false);
+var supportsFinal = App.config.shouldSupportFinal(serviceName, 
siteFileName);
 
 function isDuplicatedConfigKey(name) {
   return siteFileProperties.findProperty('name', name) || 
configsOfFile.findProperty('name', name);

http://git-wip-us.apache.org/repos/asf/ambari/blob/9077a9d3/ambari-web/test/utils/config_test.js
--
diff --git a/ambari-web/test/utils/config_test.js 
b/ambari-web/test/utils/config_test.js
index bd97b1c..bbfdc6b 100644
--- a/ambari-web/test/utils/config_test.js
+++ b/ambari-web/test/utils/config_test.js
@@ -632,6 +632,9 @@ describe('App.config', function () {
 
 before(function() {
   sinon.stub(App.config, 'parseValue', function(value) {return value});
+  sinon.stub(App.config, 'getConfigTypesInfoFromService').returns({
+supportsFinal: 

ambari git commit: AMBARI-10751. Multiple changes to YARN enhanced configs (srimanth)

2015-04-27 Thread srimanth
Repository: ambari
Updated Branches:
  refs/heads/trunk c9f0dd0b8 - 623929f58


AMBARI-10751. Multiple changes to YARN enhanced configs (srimanth)


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

Branch: refs/heads/trunk
Commit: 623929f58e40a04429d696879205a955f7cceb41
Parents: c9f0dd0
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Sun Apr 26 13:16:23 2015 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Sun Apr 26 23:26:39 2015 -0700

--
 .../YARN/2.1.0.2.0/configuration/yarn-site.xml  |  2 +-
 .../YARN/configuration/capacity-scheduler.xml   | 16 -
 .../services/YARN/configuration/yarn-env.xml| 33 ++
 .../services/YARN/configuration/yarn-site.xml   | 53 +++-
 .../HDP/2.2/services/YARN/themes/theme.json | 65 +++-
 .../stacks/HDP/2.2/services/stack_advisor.py| 14 +
 .../services/YARN/configuration/yarn-env.xml| 33 --
 .../services/YARN/configuration/yarn-site.xml   | 64 ---
 .../stacks/HDP/2.3/services/YARN/metainfo.xml   |  7 ---
 .../HDP/2.3/services/YARN/themes/theme.json | 33 --
 .../stacks/2.2/common/test_stack_advisor.py | 43 +
 11 files changed, 191 insertions(+), 172 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/623929f5/ambari-server/src/main/resources/common-services/YARN/2.1.0.2.0/configuration/yarn-site.xml
--
diff --git 
a/ambari-server/src/main/resources/common-services/YARN/2.1.0.2.0/configuration/yarn-site.xml
 
b/ambari-server/src/main/resources/common-services/YARN/2.1.0.2.0/configuration/yarn-site.xml
index ed59973..2efddb8 100644
--- 
a/ambari-server/src/main/resources/common-services/YARN/2.1.0.2.0/configuration/yarn-site.xml
+++ 
b/ambari-server/src/main/resources/common-services/YARN/2.1.0.2.0/configuration/yarn-site.xml
@@ -135,7 +135,7 @@
 value5120/value
 descriptionAmount of physical memory, in MB, that can be allocated
   for containers./description
-display-nameTotal NM Physical Memory Available to 
Containers/display-name
+display-nameTotal RAM per NM/display-name
 value-attributes
   typeint/type
   minimum0/minimum

http://git-wip-us.apache.org/repos/asf/ambari/blob/623929f5/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/capacity-scheduler.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/capacity-scheduler.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/capacity-scheduler.xml
index 63d56b0..870983b 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/capacity-scheduler.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/capacity-scheduler.xml
@@ -19,7 +19,21 @@
   property
 nameyarn.scheduler.capacity.resource-calculator/name
 
valueorg.apache.hadoop.yarn.util.resource.DefaultResourceCalculator/value
-description/description
+display-nameEnable CPU Scheduling/display-name
+value-attributes
+  typevalue-list/type
+  entries
+entry
+  
valueorg.apache.hadoop.yarn.util.resource.DominantResourceCalculator/value
+  labelEnabled/label
+/entry
+entry
+  
valueorg.apache.hadoop.yarn.util.resource.DefaultResourceCalculator/value
+  labelDisabled/label
+/entry
+  /entries
+  selection-cardinality1/selection-cardinality
+/value-attributes
   /property
   property
 nameyarn.scheduler.capacity.root.accessible-node-labels/name

http://git-wip-us.apache.org/repos/asf/ambari/blob/623929f5/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/yarn-env.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/yarn-env.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/yarn-env.xml
new file mode 100644
index 000..6920386
--- /dev/null
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/configuration/yarn-env.xml
@@ -0,0 +1,33 @@
+?xml version=1.0?
+?xml-stylesheet type=text/xsl href=configuration.xsl?
+!--
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this 

[2/2] ambari git commit: AMBARI-10762. Ambari Upgrade fails if existing properties file has content as attached in here. Ambari 1.7 to 2.0 Upgrade (dlysnichenko)

2015-04-27 Thread dmitriusan
AMBARI-10762. Ambari Upgrade fails if existing properties file has content as 
attached in here. Ambari 1.7 to 2.0 Upgrade (dlysnichenko)


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

Branch: refs/heads/branch-2.0.maint
Commit: c32403f90f2c13a5ed7cf45eb245be71adaee2e0
Parents: 97f91e7
Author: Lisnichenko Dmitro dlysniche...@hortonworks.com
Authored: Mon Apr 27 15:40:04 2015 +0300
Committer: Lisnichenko Dmitro dlysniche...@hortonworks.com
Committed: Mon Apr 27 15:41:22 2015 +0300

--
 .../src/main/python/ambari_server/serverConfiguration.py  | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/c32403f9/ambari-server/src/main/python/ambari_server/serverConfiguration.py
--
diff --git a/ambari-server/src/main/python/ambari_server/serverConfiguration.py 
b/ambari-server/src/main/python/ambari_server/serverConfiguration.py
index f73e75c..66e5c09 100644
--- a/ambari-server/src/main/python/ambari_server/serverConfiguration.py
+++ b/ambari-server/src/main/python/ambari_server/serverConfiguration.py
@@ -782,9 +782,14 @@ def update_ambari_properties():
 
   # Previous config file does not exist
   if (not prev_conf_file) or (prev_conf_file is None):
-print_warning_msg(Can not find ambari.properties.backup file from 
previous version, skipping import of settings)
+print_warning_msg(Can not find %s file from previous version, skipping 
import of settings % configDefaults.AMBARI_PROPERTIES_BACKUP_FILE)
 return 0
 
+  # ambari.properties file does not exists
+  if conf_file is None:
+print_error_msg(Can't find %s file % AMBARI_PROPERTIES_FILE)
+return -1
+
   try:
 old_properties = Properties()
 old_properties.load(open(prev_conf_file))



ambari git commit: AMBARI-10631. Add logic for handling configuration for tez acls in Ambari (aonishuk)

2015-04-27 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 43e792cfc - 4bef8d076


AMBARI-10631. Add logic for handling configuration for tez acls in Ambari  
(aonishuk)


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

Branch: refs/heads/trunk
Commit: 4bef8d076399cc42eadb4374d01868c16b2bb6fd
Parents: 43e792c
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Mon Apr 27 16:24:18 2015 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Mon Apr 27 16:24:18 2015 +0300

--
 .../stacks/HDP/2.3/services/TEZ/kerberos.json   | 19 ++
 ambari-web/app/data/HDP2.3/site_properties.js   | 69 
 2 files changed, 59 insertions(+), 29 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/4bef8d07/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/kerberos.json
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/kerberos.json 
b/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/kerberos.json
new file mode 100644
index 000..3662ed8
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/kerberos.json
@@ -0,0 +1,19 @@
+{
+  services: [
+{
+  name: TEZ,
+  components: [
+{
+  name: TEZ_CLIENT,
+  configurations: [
+{
+  tez-site: {
+tez.am.view-acls: 
+  }
+}
+  ]
+}
+  ]
+}
+  ]
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/4bef8d07/ambari-web/app/data/HDP2.3/site_properties.js
--
diff --git a/ambari-web/app/data/HDP2.3/site_properties.js 
b/ambari-web/app/data/HDP2.3/site_properties.js
index 4665b2e..90f2aba 100644
--- a/ambari-web/app/data/HDP2.3/site_properties.js
+++ b/ambari-web/app/data/HDP2.3/site_properties.js
@@ -28,35 +28,46 @@ var hdp23properties = hdp22properties.filter(function 
(item) {
   return !excludedConfigs.contains(item.name);
 });
 
-hdp23properties.push({
-  id: site property,
-  name: DB_FLAVOR,
-  displayName: DB FLAVOR,
-  value: MYSQL,
-  defaultValue: MYSQL,
-  isReconfigurable: true,
-  options: [
-{
-  displayName: 'MYSQL'
-},
-{
-  displayName: 'ORACLE'
-},
-{
-  displayName: 'POSTGRES'
-},
-{
-  displayName: 'SQLSERVER'
-}
-  ],
-  displayType: radio button,
-  radioName: RANGER DB_FLAVOR,
-  isOverridable: false,
-  isVisible: true,
-  serviceName: RANGER,
-  filename: admin-properties.xml,
-  category: DBSettings
-});
+hdp23properties.push(
+  {
+id: site property,
+name: DB_FLAVOR,
+displayName: DB FLAVOR,
+value: MYSQL,
+defaultValue: MYSQL,
+isReconfigurable: true,
+options: [
+  {
+displayName: 'MYSQL'
+  },
+  {
+displayName: 'ORACLE'
+  },
+  {
+displayName: 'POSTGRES'
+  },
+  {
+displayName: 'SQLSERVER'
+  }
+],
+displayType: radio button,
+radioName: RANGER DB_FLAVOR,
+isOverridable: false,
+isVisible: true,
+serviceName: RANGER,
+filename: admin-properties.xml,
+category: DBSettings
+  },
+  {
+id: site property,
+name: tez.am.view-acls,
+displayName: tez.am.view-acls,
+isRequired: false,
+serviceName: TEZ,
+filename: tez-site.xml,
+category: Advanced tez-site
+  }
+);
 
 module.exports =
 {



ambari git commit: AMBARI-10761. Validation isn't executed after override is created (onechiporenko)

2015-04-27 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk ebea5413f - 57ba7014a


AMBARI-10761. Validation isn't executed after override is created 
(onechiporenko)


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

Branch: refs/heads/trunk
Commit: 57ba7014abcecca9c766253545104640ce77202e
Parents: ebea541
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Mon Apr 27 15:33:11 2015 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Mon Apr 27 15:33:11 2015 +0300

--
 .../app/controllers/main/service/info/configs.js   |  2 ++
 .../app/controllers/wizard/step7_controller.js |  1 +
 ambari-web/app/messages.js |  2 ++
 ambari-web/app/models/service_config.js|  6 +++---
 .../widgets/overrides/config_widget_override.hbs   |  5 -
 .../configs/widgets/list_config_widget_view.js |  1 +
 .../widgets/list_config_widget_view_test.js| 17 +
 7 files changed, 26 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/57ba7014/ambari-web/app/controllers/main/service/info/configs.js
--
diff --git a/ambari-web/app/controllers/main/service/info/configs.js 
b/ambari-web/app/controllers/main/service/info/configs.js
index 5f22112..e39b1a2 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -1037,6 +1037,7 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
 if (defaultGroupSelected) {
   newSCP.set('isEditable', false);
 }
+newSCP.validate();
 return newSCP;
   },
 
@@ -1352,6 +1353,7 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
 isNotSaved: isNotSaved
   });
   console.debug(createOverrideProperty(): Added:, newSCP,  to 
main-property:, serviceConfigProperty);
+  newSCP.validate();
   overrides.pushObject(newSCP);
 }
   },

http://git-wip-us.apache.org/repos/asf/ambari/blob/57ba7014/ambari-web/app/controllers/wizard/step7_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step7_controller.js 
b/ambari-web/app/controllers/wizard/step7_controller.js
index ede0579..86a3a39 100644
--- a/ambari-web/app/controllers/wizard/step7_controller.js
+++ b/ambari-web/app/controllers/wizard/step7_controller.js
@@ -1097,6 +1097,7 @@ App.WizardStep7Controller = 
Em.Controller.extend(App.ServerValidatorMixin, App.E
 newSCP.set('isEditable', true);
 group.get('properties').pushObject(newSCP);
 overrides.pushObject(newSCP);
+newSCP.validate();
 return newSCP;
   },
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/57ba7014/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 6404f5e..0a0ed35 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -384,6 +384,8 @@ Em.I18n.translations = {
   'users.userName.validationFail': 'Only lowercase letters and numbers are 
recommended; must start with a letter',
   'host.spacesValidation': 'Cannot contain whitespace',
   'host.trimspacesValidation': 'Cannot contain leading or trailing whitespace',
+  'config.override.valueEqualToParentConfig': 'Configuration overrides must 
have different value',
+  'config.override.valueEqualToAnotherOverrideConfig': 'Multiple configuration 
overrides cannot have same value',
 
   'services.hdfs.rebalance.title' : 'HDFS Rebalance',
   'services.ganglia.description':'Ganglia Metrics Collection system',

http://git-wip-us.apache.org/repos/asf/ambari/blob/57ba7014/ambari-web/app/models/service_config.js
--
diff --git a/ambari-web/app/models/service_config.js 
b/ambari-web/app/models/service_config.js
index c47812c..b45cb0d 100644
--- a/ambari-web/app/models/service_config.js
+++ b/ambari-web/app/models/service_config.js
@@ -1071,16 +1071,16 @@ App.ServiceConfigProperty = Em.Object.extend({
   var isOriginalSCP = this.get('isOriginalSCP');
   var parentSCP = this.get('parentSCP');
   if (!isOriginalSCP) {
-if (!isError  parentSCP != null) {
+if (!Em.isNone(parentSCP)) {
   if (value === parentSCP.get('value')  supportsFinal  isFinal === 
parentSCP.get('isFinal')) {
-this.set('errorMessage', 'Configuration overrides must have 
different value');
+this.set('errorMessage', 

[1/2] ambari git commit: AMBARI-10762. Ambari Upgrade fails if existing properties file has content as attached in here. Ambari 1.7 to 2.0 Upgrade (dlysnichenko)

2015-04-27 Thread dmitriusan
Repository: ambari
Updated Branches:
  refs/heads/branch-2.0.maint 97f91e7f5 - c32403f90
  refs/heads/trunk 57ba7014a - 43e792cfc


AMBARI-10762. Ambari Upgrade fails if existing properties file has content as 
attached in here. Ambari 1.7 to 2.0 Upgrade (dlysnichenko)


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

Branch: refs/heads/trunk
Commit: 43e792cfc710f0f699b854771090cb11e20abc31
Parents: 57ba701
Author: Lisnichenko Dmitro dlysniche...@hortonworks.com
Authored: Mon Apr 27 15:40:04 2015 +0300
Committer: Lisnichenko Dmitro dlysniche...@hortonworks.com
Committed: Mon Apr 27 15:40:30 2015 +0300

--
 .../src/main/python/ambari_server/serverConfiguration.py  | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/43e792cf/ambari-server/src/main/python/ambari_server/serverConfiguration.py
--
diff --git a/ambari-server/src/main/python/ambari_server/serverConfiguration.py 
b/ambari-server/src/main/python/ambari_server/serverConfiguration.py
index 26ee4b0..fec54e9 100644
--- a/ambari-server/src/main/python/ambari_server/serverConfiguration.py
+++ b/ambari-server/src/main/python/ambari_server/serverConfiguration.py
@@ -774,9 +774,14 @@ def update_ambari_properties():
 
   # Previous config file does not exist
   if (not prev_conf_file) or (prev_conf_file is None):
-print_warning_msg(Can not find ambari.properties.backup file from 
previous version, skipping import of settings)
+print_warning_msg(Can not find %s file from previous version, skipping 
import of settings % configDefaults.AMBARI_PROPERTIES_BACKUP_FILE)
 return 0
 
+  # ambari.properties file does not exists
+  if conf_file is None:
+print_error_msg(Can't find %s file % AMBARI_PROPERTIES_FILE)
+return -1
+
   try:
 old_properties = Properties()
 old_properties.load(open(prev_conf_file))



ambari git commit: AMBARI-10664. Add new config for tez for HDP 2.3 (aonishuk)

2015-04-27 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 4bef8d076 - 289a14474


AMBARI-10664. Add new config for tez for HDP 2.3  (aonishuk)


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

Branch: refs/heads/trunk
Commit: 289a1447487b49cdc1f6a03ef8a01d9eb0e6c735
Parents: 4bef8d0
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Mon Apr 27 16:36:53 2015 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Mon Apr 27 16:36:53 2015 +0300

--
 .../2.3/services/TEZ/configuration/tez-site.xml   | 18 ++
 1 file changed, 18 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/289a1447/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/configuration/tez-site.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/configuration/tez-site.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/configuration/tez-site.xml
index b39cd93..be534f1 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/configuration/tez-site.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.3/services/TEZ/configuration/tez-site.xml
@@ -27,6 +27,24 @@
   /property
 
   property
+nametez.runtime.optimize.local.fetch/name
+valuetrue/value
+descriptionIf the shuffle input is on the local host bypass the http 
fetch and access the files directly./description
+value-attributes
+  typeboolean/type
+/value-attributes
+  /property
+
+  property
+nametez.task.generate.counters.per.io/name
+valuetrue/value
+descriptionWhether to generate counters on a per-edge basis for a Tez 
DAG. Helpful for in-depth analysis./description
+value-attributes
+  typeboolean/type
+/value-attributes
+  /property
+
+  property
 nametez.runtime.sorter.class/name
 valuePIPELINED/value
 descriptionWhich sorter implementation to use/description



ambari git commit: AMBARI-10763 Subsection borders not shown correctly in enhanced configs. (ababiichuk)

2015-04-27 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 289a14474 - 21d911316


AMBARI-10763 Subsection borders not shown correctly in enhanced configs. 
(ababiichuk)


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

Branch: refs/heads/trunk
Commit: 21d911316e56af1c91641af8ab648dd9cb3beb2a
Parents: 289a144
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Mon Apr 27 17:37:12 2015 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Mon Apr 27 17:37:28 2015 +0300

--
 ambari-web/app/models/configs/sub_section.js| 21 
 ambari-web/app/styles/application.less  | 25 
 .../configs/service_config_layout_tab.hbs   | 22 ++---
 3 files changed, 54 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/21d91131/ambari-web/app/models/configs/sub_section.js
--
diff --git a/ambari-web/app/models/configs/sub_section.js 
b/ambari-web/app/models/configs/sub_section.js
index 54d3559..84f26bc 100644
--- a/ambari-web/app/models/configs/sub_section.js
+++ b/ambari-web/app/models/configs/sub_section.js
@@ -83,6 +83,27 @@ App.SubSection = DS.Model.extend({
   /**
* @type {boolean}
*/
+  addLeftVerticalSplitter: function() {
+return !this.get('isFirstColumn');
+  }.property('isFirstColumn'),
+
+  /**
+   * @type {boolean}
+   */
+  addRightVerticalSplitter: function() {
+return !this.get('isLastColumn');
+  }.property('isLastColumn'),
+
+  /**
+   * @type {boolean}
+   */
+  showTopSplitter: function() {
+return !this.get('isFirstRow')  !this.get('border');
+  }.property('isFirstRow', 'border'),
+
+  /**
+   * @type {boolean}
+   */
   isFirstRow: function () {
 return this.get('rowIndex') == 0;
   }.property('rowIndex'),

http://git-wip-us.apache.org/repos/asf/ambari/blob/21d91131/ambari-web/app/styles/application.less
--
diff --git a/ambari-web/app/styles/application.less 
b/ambari-web/app/styles/application.less
index cf0ceee..ae7ba07 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -5638,16 +5638,27 @@ input[type=radio].align-checkbox, 
input[type=checkbox].align-checkbox {
   font-size: 22px;
   font-weight: 400;
 }
-
 h5 {
   font-size: 18px;
   font-weight: 400;
 }
-.vertical-splitter {
+.vertical-splitter-r {
+  border-right: 2px solid #ccc; // vertical splitter
+  padding-right: 20px;
+  padding-left: 0px;
+}
+
+.vertical-splitter-l {
   border-left: 2px solid #ccc; // vertical splitter
+  margin-left: -2px;
   padding-left: 20px;
+  padding-right: 0px;
+}
+div.with-border {
+  border: 1px solid #aaa;
+  padding: 10px;
+  margin-bottom: 20px;
 }
-
 .config-subsection-table {
   width: 100%;
   height: 90%; // fallback option
@@ -5655,12 +5666,16 @@ input[type=radio].align-checkbox, 
input[type=checkbox].align-checkbox {
   border-collapse: separate;
   table-layout: fixed;
   .config-subsection {
+padding: 0px;
 vertical-align: top;
 .no-horizontal-splitter {
   border-bottom: none; // no horizontal splitter for subsection on 
the last row
 }
-border-bottom: 2px solid #ccc; // horizontal splitter
-
+.top-horizontal-splitter {
+  border-top: 2px solid #ccc; // horizontal splitter
+  padding-top: 15px;
+  padding-bottom: 15px;
+}
 .directories {
   min-width: 0px !important;
 }

http://git-wip-us.apache.org/repos/asf/ambari/blob/21d91131/ambari-web/app/templates/common/configs/service_config_layout_tab.hbs
--
diff --git 
a/ambari-web/app/templates/common/configs/service_config_layout_tab.hbs 
b/ambari-web/app/templates/common/configs/service_config_layout_tab.hbs
index 20d4ea8..44f0abc 100644
--- a/ambari-web/app/templates/common/configs/service_config_layout_tab.hbs
+++ b/ambari-web/app/templates/common/configs/service_config_layout_tab.hbs
@@ -27,15 +27,19 @@
   {{#each subRow in section.subsectionRows}}
 tr
   {{#each subsection in subRow}}
-td {{bindAttr 
class=subsection.isHiddenByFilter:invisible 

ambari git commit: AMBARI-10748 - Views: IllegalAccessError: tried to access class (tbeerbower)

2015-04-27 Thread tbeerbower
Repository: ambari
Updated Branches:
  refs/heads/branch-2.0.maint 020d8d300 - f82ed9213


AMBARI-10748 - Views: IllegalAccessError: tried to access class (tbeerbower)


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

Branch: refs/heads/branch-2.0.maint
Commit: f82ed9213f1117ff6faf986bfcb181ff60aa77dd
Parents: 020d8d3
Author: tbeerbower tbeerbo...@hortonworks.com
Authored: Mon Apr 27 11:44:49 2015 -0400
Committer: tbeerbower tbeerbo...@hortonworks.com
Committed: Mon Apr 27 17:03:17 2015 -0400

--
 ambari-project/pom.xml  |  22 +++
 ambari-server/pom.xml   |  18 +++
 .../server/controller/AmbariHandlerList.java|  56 ---
 .../ambari/server/controller/AmbariServer.java  |   1 -
 .../server/controller/FailsafeHandlerList.java  | 154 ---
 .../controller/FailsafeServletResponse.java |  77 --
 .../ambari/server/view/ViewArchiveUtility.java  |  11 +-
 .../ambari/server/view/ViewClassLoader.java | 118 ++
 .../ambari/server/view/ViewExtractor.java   |   3 +-
 .../controller/AmbariHandlerListTest.java   |  13 +-
 .../controller/FailsafeHandlerListTest.java |  71 -
 .../controller/FailsafeServletResponseTest.java |  54 ---
 .../ambari/server/view/ViewClassLoaderTest.java | 101 
 13 files changed, 302 insertions(+), 397 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f82ed921/ambari-project/pom.xml
--
diff --git a/ambari-project/pom.xml b/ambari-project/pom.xml
index 466c4c4..10380a1 100644
--- a/ambari-project/pom.xml
+++ b/ambari-project/pom.xml
@@ -321,6 +321,28 @@ instead of a SNAPSHOT. --
 artifactIdjetty-webapp/artifactId
 version7.6.7.v20120910/version
   /dependency
+  !--jsp support for jetty --
+  dependency
+groupIdorg.mortbay.jetty/groupId
+artifactIdjsp-api-2.1-glassfish/artifactId
+version2.1.v20100127/version
+  /dependency
+  dependency
+groupIdorg.mortbay.jetty/groupId
+artifactIdjsp-2.1-glassfish/artifactId
+version2.1.v20100127/version
+  /dependency
+  dependency
+groupIdorg.apache.ant/groupId
+artifactIdant/artifactId
+version1.7.1/version
+  /dependency
+  dependency
+groupIdorg.apache.ant/groupId
+artifactIdant-launcher/artifactId
+version1.7.1/version
+  /dependency
+
   dependency
 groupIdcommons-logging/groupId
 artifactIdcommons-logging/artifactId

http://git-wip-us.apache.org/repos/asf/ambari/blob/f82ed921/ambari-server/pom.xml
--
diff --git a/ambari-server/pom.xml b/ambari-server/pom.xml
index 11e2790..f75d05a 100644
--- a/ambari-server/pom.xml
+++ b/ambari-server/pom.xml
@@ -1564,6 +1564,24 @@
   groupIdorg.eclipse.jetty/groupId
   artifactIdjetty-webapp/artifactId
 /dependency
+!--jsp support for jetty --
+dependency
+  groupIdorg.mortbay.jetty/groupId
+  artifactIdjsp-api-2.1-glassfish/artifactId
+/dependency
+dependency
+  groupIdorg.mortbay.jetty/groupId
+  artifactIdjsp-2.1-glassfish/artifactId
+/dependency
+dependency
+  groupIdorg.apache.ant/groupId
+  artifactIdant/artifactId
+/dependency
+dependency
+  groupIdorg.apache.ant/groupId
+  artifactIdant-launcher/artifactId
+/dependency
+
 dependency
   groupIdorg.eclipse.jetty/groupId
   artifactIdjetty-server/artifactId

http://git-wip-us.apache.org/repos/asf/ambari/blob/f82ed921/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
index 7c68311..c6aac1d 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
@@ -19,7 +19,6 @@ package org.apache.ambari.server.controller;
 
 import java.io.IOException;
 import java.util.HashMap;
-import java.util.List;
 import java.util.Map;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
@@ -40,13 +39,12 @@ import org.apache.ambari.view.ViewContext;
 import org.eclipse.jetty.server.Handler;
 import org.eclipse.jetty.server.Request;
 import 

ambari git commit: AMBARI-10799. Ambari API should support querying metric values with aggregation type (max, min, avg and sum). (swagle)

2015-04-27 Thread swagle
Repository: ambari
Updated Branches:
  refs/heads/trunk 35a99761e - 6a054b35a


AMBARI-10799. Ambari API should support querying metric values with aggregation 
type (max, min, avg and sum). (swagle)


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

Branch: refs/heads/trunk
Commit: 6a054b35a3a4034788d83455a124d9ece0d72811
Parents: 35a9976
Author: Siddharth Wagle swa...@hortonworks.com
Authored: Mon Apr 27 16:17:21 2015 -0700
Committer: Siddharth Wagle swa...@hortonworks.com
Committed: Mon Apr 27 16:17:21 2015 -0700

--
 .../metrics/MetricsPropertyProviderProxy.java   |3 -
 .../timeline/AMSComponentPropertyProvider.java  |   52 +-
 .../metrics/timeline/AMSPropertyProvider.java   |   52 +-
 .../timeline/AMSPropertyProviderTest.java   |   44 +-
 .../ams/aggregate_component_metric.json |   42 +
 .../ams/multiple_component_metrics.json | 1274 --
 6 files changed, 177 insertions(+), 1290 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6a054b35/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/MetricsPropertyProviderProxy.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/MetricsPropertyProviderProxy.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/MetricsPropertyProviderProxy.java
index d2cd959..24f1851 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/MetricsPropertyProviderProxy.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/MetricsPropertyProviderProxy.java
@@ -24,12 +24,10 @@ import 
org.apache.ambari.server.controller.metrics.ganglia.GangliaComponentPrope
 import 
org.apache.ambari.server.controller.metrics.ganglia.GangliaHostComponentPropertyProvider;
 import 
org.apache.ambari.server.controller.metrics.ganglia.GangliaHostPropertyProvider;
 import 
org.apache.ambari.server.controller.metrics.ganglia.GangliaPropertyProvider;
-import 
org.apache.ambari.server.controller.metrics.ganglia.GangliaReportPropertyProvider;
 import 
org.apache.ambari.server.controller.metrics.timeline.AMSComponentPropertyProvider;
 import 
org.apache.ambari.server.controller.metrics.timeline.AMSHostComponentPropertyProvider;
 import 
org.apache.ambari.server.controller.metrics.timeline.AMSHostPropertyProvider;
 import 
org.apache.ambari.server.controller.metrics.timeline.AMSPropertyProvider;
-import 
org.apache.ambari.server.controller.metrics.timeline.AMSReportPropertyProvider;
 import org.apache.ambari.server.controller.spi.Predicate;
 import org.apache.ambari.server.controller.spi.Request;
 import org.apache.ambari.server.controller.spi.Resource;
@@ -37,7 +35,6 @@ import 
org.apache.ambari.server.controller.spi.SystemException;
 import org.apache.ambari.server.controller.utilities.StreamProvider;
 import java.util.Map;
 import java.util.Set;
-
 import static 
org.apache.ambari.server.controller.metrics.MetricsServiceProvider.MetricsService;
 import static 
org.apache.ambari.server.controller.metrics.MetricsServiceProvider.MetricsService.GANGLIA;
 import static 
org.apache.ambari.server.controller.metrics.MetricsServiceProvider.MetricsService.TIMELINE_METRICS;

http://git-wip-us.apache.org/repos/asf/ambari/blob/6a054b35/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/timeline/AMSComponentPropertyProvider.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/timeline/AMSComponentPropertyProvider.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/timeline/AMSComponentPropertyProvider.java
index 1fb0869..3e32326 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/timeline/AMSComponentPropertyProvider.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/metrics/timeline/AMSComponentPropertyProvider.java
@@ -20,9 +20,16 @@ package org.apache.ambari.server.controller.metrics.timeline;
 import org.apache.ambari.server.configuration.ComponentSSLConfiguration;
 import org.apache.ambari.server.controller.internal.PropertyInfo;
 import org.apache.ambari.server.controller.metrics.MetricHostProvider;
+import org.apache.ambari.server.controller.spi.Predicate;
+import org.apache.ambari.server.controller.spi.Request;
 import org.apache.ambari.server.controller.spi.Resource;
+import org.apache.ambari.server.controller.utilities.PredicateHelper;
 import 

ambari git commit: AMBARI-10766. New configs layout : autogenerated xPathes are not readable (onechiporenko)

2015-04-27 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk 21d911316 - 763480134


AMBARI-10766. New configs layout : autogenerated xPathes are not readable 
(onechiporenko)


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

Branch: refs/heads/trunk
Commit: 76348013473e9b4c9ebe2e1bb5ebb5dd9ed07e87
Parents: 21d9113
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Mon Apr 27 18:19:11 2015 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Mon Apr 27 18:22:20 2015 +0300

--
 .../app/templates/common/configs/widgets/controls.hbs   | 2 +-
 .../app/views/common/configs/widgets/config_widget_view.js  | 2 +-
 ambari-web/app/views/common/controls_view.js| 9 +
 3 files changed, 7 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/76348013/ambari-web/app/templates/common/configs/widgets/controls.hbs
--
diff --git a/ambari-web/app/templates/common/configs/widgets/controls.hbs 
b/ambari-web/app/templates/common/configs/widgets/controls.hbs
index c3b7e88..e2ec89c 100644
--- a/ambari-web/app/templates/common/configs/widgets/controls.hbs
+++ b/ambari-web/app/templates/common/configs/widgets/controls.hbs
@@ -76,7 +76,7 @@
   div class=widget-config-controls
 {{#if controller.selectedConfigGroup.isDefault}}
   span
-class=label label-info pull-right{{t 
dashboard.configHistory.table.version.prefix}}{{controller.selectedVersion}}/span
+class=label label-info{{t 
dashboard.configHistory.table.version.prefix}}{{controller.selectedVersion}}/span
   {{#if controller.isCurrentSelected}}
 span class=label label-success{{t common.current}}/span
   {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/76348013/ambari-web/app/views/common/configs/widgets/config_widget_view.js
--
diff --git a/ambari-web/app/views/common/configs/widgets/config_widget_view.js 
b/ambari-web/app/views/common/configs/widgets/config_widget_view.js
index 1251837..86ec19f 100644
--- a/ambari-web/app/views/common/configs/widgets/config_widget_view.js
+++ b/ambari-web/app/views/common/configs/widgets/config_widget_view.js
@@ -22,7 +22,7 @@ require('views/common/controls_view');
  * Common view for config widgets
  * @type {Em.View}
  */
-App.ConfigWidgetView = Em.View.extend(App.SupportsDependentConfigs, 
App.WidgetPopoverSupport, App.ConvertUnitWidgetViewMixin, {
+App.ConfigWidgetView = Em.View.extend(App.SupportsDependentConfigs, 
App.WidgetPopoverSupport, App.ConvertUnitWidgetViewMixin, 
App.ServiceConfigCalculateId, {
 
   /**
* @type {App.ConfigProperty}

http://git-wip-us.apache.org/repos/asf/ambari/blob/76348013/ambari-web/app/views/common/controls_view.js
--
diff --git a/ambari-web/app/views/common/controls_view.js 
b/ambari-web/app/views/common/controls_view.js
index e6ce369..4ec1c74 100644
--- a/ambari-web/app/views/common/controls_view.js
+++ b/ambari-web/app/views/common/controls_view.js
@@ -132,10 +132,11 @@ App.SupportsDependentConfigs = Ember.Mixin.create({
  */
 App.ServiceConfigCalculateId = Ember.Mixin.create({
   idClass: Ember.computed(function () {
-var label = Em.get(this, 'serviceConfig.name') ? Em.get(this, 
'serviceConfig.name').toLowerCase().replace(/\./g, '-') : '',
-fileName = Em.get(this, 'serviceConfig.filename') ? Em.get(this, 
'serviceConfig.filename').toLowerCase().replace(/\./g, '-') : '',
-group = Em.get(this, 'serviceConfig.group.name') || 'default';
-isOrigin = Em.get(this, 'serviceConfig.compareConfigs.length')  0 ? 
'-origin' : '';
+var config = this.get('config')  this.get('config.widget') ? 
this.get('config') : this.get('serviceConfig') || {};
+var label = Em.get(config, 'name') ? Em.get(config, 
'name').toLowerCase().replace(/\./g, '-') : '',
+fileName = Em.get(config, 'filename') ? Em.get(config, 
'filename').toLowerCase().replace(/\./g, '-') : '',
+group = Em.get(config, 'group.name') || 'default',
+isOrigin = Em.getWithDefault(config, 'compareConfigs.length', 0)  0 ? 
'-origin' : '';
 return 'service-config-' + label + '-' + fileName + '-' + group + isOrigin;
   }),
   classNameBindings: 'idClass'



ambari git commit: AMBARI-10748 - Views: IllegalAccessError: tried to access class (tbeerbower)

2015-04-27 Thread tbeerbower
Repository: ambari
Updated Branches:
  refs/heads/trunk 763480134 - 71f729034


AMBARI-10748 - Views: IllegalAccessError: tried to access class (tbeerbower)


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

Branch: refs/heads/trunk
Commit: 71f72903430949a4b153846ee448be24e1e9b98d
Parents: 7634801
Author: tbeerbower tbeerbo...@hortonworks.com
Authored: Mon Apr 27 11:44:49 2015 -0400
Committer: tbeerbower tbeerbo...@hortonworks.com
Committed: Mon Apr 27 11:44:49 2015 -0400

--
 ambari-project/pom.xml  |  22 +++
 ambari-server/pom.xml   |  18 +++
 .../server/controller/AmbariHandlerList.java|  56 ---
 .../ambari/server/controller/AmbariServer.java  |   1 -
 .../server/controller/FailsafeHandlerList.java  | 154 ---
 .../controller/FailsafeServletResponse.java |  77 --
 .../ambari/server/view/ViewArchiveUtility.java  |  11 +-
 .../ambari/server/view/ViewClassLoader.java | 118 ++
 .../ambari/server/view/ViewExtractor.java   |   3 +-
 .../controller/AmbariHandlerListTest.java   |  13 +-
 .../controller/FailsafeHandlerListTest.java |  71 -
 .../controller/FailsafeServletResponseTest.java |  54 ---
 .../ambari/server/view/ViewClassLoaderTest.java | 101 
 13 files changed, 302 insertions(+), 397 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/71f72903/ambari-project/pom.xml
--
diff --git a/ambari-project/pom.xml b/ambari-project/pom.xml
index 12ae96c..378a998 100644
--- a/ambari-project/pom.xml
+++ b/ambari-project/pom.xml
@@ -251,6 +251,28 @@
 artifactIdjetty-webapp/artifactId
 version7.6.7.v20120910/version
   /dependency
+  !--jsp support for jetty --
+  dependency
+groupIdorg.mortbay.jetty/groupId
+artifactIdjsp-api-2.1-glassfish/artifactId
+version2.1.v20100127/version
+  /dependency
+  dependency
+groupIdorg.mortbay.jetty/groupId
+artifactIdjsp-2.1-glassfish/artifactId
+version2.1.v20100127/version
+  /dependency
+  dependency
+groupIdorg.apache.ant/groupId
+artifactIdant/artifactId
+version1.7.1/version
+  /dependency
+  dependency
+groupIdorg.apache.ant/groupId
+artifactIdant-launcher/artifactId
+version1.7.1/version
+  /dependency
+
   dependency
 groupIdcommons-logging/groupId
 artifactIdcommons-logging/artifactId

http://git-wip-us.apache.org/repos/asf/ambari/blob/71f72903/ambari-server/pom.xml
--
diff --git a/ambari-server/pom.xml b/ambari-server/pom.xml
index 896a202..626a364 100644
--- a/ambari-server/pom.xml
+++ b/ambari-server/pom.xml
@@ -1606,6 +1606,24 @@
   groupIdorg.eclipse.jetty/groupId
   artifactIdjetty-webapp/artifactId
 /dependency
+!--jsp support for jetty --
+dependency
+  groupIdorg.mortbay.jetty/groupId
+  artifactIdjsp-api-2.1-glassfish/artifactId
+/dependency
+dependency
+  groupIdorg.mortbay.jetty/groupId
+  artifactIdjsp-2.1-glassfish/artifactId
+/dependency
+dependency
+  groupIdorg.apache.ant/groupId
+  artifactIdant/artifactId
+/dependency
+dependency
+  groupIdorg.apache.ant/groupId
+  artifactIdant-launcher/artifactId
+/dependency
+
 dependency
   groupIdorg.eclipse.jetty/groupId
   artifactIdjetty-server/artifactId

http://git-wip-us.apache.org/repos/asf/ambari/blob/71f72903/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
index 7c68311..c6aac1d 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariHandlerList.java
@@ -19,7 +19,6 @@ package org.apache.ambari.server.controller;
 
 import java.io.IOException;
 import java.util.HashMap;
-import java.util.List;
 import java.util.Map;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
@@ -40,13 +39,12 @@ import org.apache.ambari.view.ViewContext;
 import org.eclipse.jetty.server.Handler;
 import org.eclipse.jetty.server.Request;
 import org.eclipse.jetty.server.SessionManager;
+import 

[1/2] ambari git commit: AMBARI-10769. Configs saving failure message appears even in case of success. (akovalenko)

2015-04-27 Thread akovalenko
Repository: ambari
Updated Branches:
  refs/heads/trunk 71f729034 - 4bad90667


AMBARI-10769. Configs saving failure message appears even in case of success. 
(akovalenko)


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

Branch: refs/heads/trunk
Commit: 4bad90667bb9d41faf61456be6e6fa4215ff6be2
Parents: e9430b1
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Mon Apr 27 18:47:57 2015 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Mon Apr 27 19:16:29 2015 +0300

--
 .../views/common/configs/config_history_flow.js | 17 +-
 .../common/configs/config_history_flow_test.js  | 33 +++-
 2 files changed, 42 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/4bad9066/ambari-web/app/views/common/configs/config_history_flow.js
--
diff --git a/ambari-web/app/views/common/configs/config_history_flow.js 
b/ambari-web/app/views/common/configs/config_history_flow.js
index 3554f00..7e407e5 100644
--- a/ambari-web/app/views/common/configs/config_history_flow.js
+++ b/ambari-web/app/views/common/configs/config_history_flow.js
@@ -450,14 +450,17 @@ App.ConfigHistoryFlowView = Em.View.extend({
   primary: Em.I18n.t('common.save'),
   secondary: Em.I18n.t('common.cancel'),
   onSave: function () {
-self.get('controller').set('serviceConfigVersionNote', 
this.get('serviceConfigNote'));
-self.get('controller').set('serviceConfigNote', 
this.get('serviceConfigNote'))
 var newVersionToBeCreated = 
App.ServiceConfigVersion.find().filterProperty('serviceName', 
self.get('serviceName')).get('length') + 1;
-self.get('controller').set('preSelectedConfigVersion', 
Em.Object.create({
-  version: newVersionToBeCreated,
-  serviceName: self.get('displayedServiceVersion.serviceName'),
-  groupName: self.get('controller.selectedConfigGroup.name')
-}));
+self.get('controller').setProperties({
+  saveConfigsFlag: true,
+  serviceConfigVersionNote: this.get('serviceConfigNote'),
+  serviceConfigNote: this.get('serviceConfigNote'),
+  preSelectedConfigVersion: Em.Object.create({
+version: newVersionToBeCreated,
+serviceName: self.get('displayedServiceVersion.serviceName'),
+groupName: self.get('controller.selectedConfigGroup.name')
+  })
+});
 self.get('controller').saveStepConfigs();
 this.hide();
   },

http://git-wip-us.apache.org/repos/asf/ambari/blob/4bad9066/ambari-web/test/views/common/configs/config_history_flow_test.js
--
diff --git a/ambari-web/test/views/common/configs/config_history_flow_test.js 
b/ambari-web/test/views/common/configs/config_history_flow_test.js
index 33f3cc4..edde670 100644
--- a/ambari-web/test/views/common/configs/config_history_flow_test.js
+++ b/ambari-web/test/views/common/configs/config_history_flow_test.js
@@ -583,13 +583,44 @@ describe.skip('App.ConfigHistoryFlowView', function () {
   });
 
   describe('#save()', function () {
-it('', function () {
+it('modal popup should be displayed', function () {
   sinon.stub(App.ModalPopup, 'show', Em.K);
   view.save();
 
   expect(App.ModalPopup.show.calledOnce).to.be.true;
   App.ModalPopup.show.restore();
 });
+
+it('controller properties should be modified on save', function () {
+  sinon.stub(App.ServiceConfigVersion, 'find').returns([
+{
+  serviceName: 'service'
+}
+  ]);
+  view.setProperties({
+'serviceName': 'service',
+'controller.saveConfigsFlag': false,
+'controller.serviceConfigVersionNote': '',
+'controller.serviceConfigNote': '',
+'controller.preSelectedConfigVersion': null,
+'serviceConfigNote': 'note',
+'displayedServiceVersion.serviceName': 'service',
+'controller.selectedConfigGroup.name': 'group'
+  });
+  var popup = view.save();
+  popup.onSave();
+  expect(view.get('controller.saveConfigsFlag')).to.be.true;
+  expect(view.get('controller').getProperties(['saveConfigsFlag', 
'serviceConfigVersionNote', 'serviceConfigNote', 
'preSelectedConfigVersion'])).to.eql({
+saveConfigsFlag: true,
+serviceConfigVersionNote: 'note',
+serviceConfigNote: this.get('serviceConfigNote'),
+preSelectedConfigVersion: Em.Object.create({
+  version: 2,
+  serviceName: 'service',
+  groupName: 'group'

ambari git commit: AMBARI-10765 HIVE Configs page. Discard/Save buttons are enabled when user navigate on this page. (ababiichuk)

2015-04-27 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 4bad90667 - 52705c266


AMBARI-10765 HIVE Configs page. Discard/Save buttons are enabled when user 
navigate on this page. (ababiichuk)


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

Branch: refs/heads/trunk
Commit: 52705c2668d29dcec126e0c60a6b457250355084
Parents: 4bad906
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Mon Apr 27 18:10:36 2015 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Mon Apr 27 19:20:13 2015 +0300

--
 ambari-web/app/models/service_config.js | 7 ---
 ambari-web/app/utils/config.js  | 1 +
 2 files changed, 5 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/52705c26/ambari-web/app/models/service_config.js
--
diff --git a/ambari-web/app/models/service_config.js 
b/ambari-web/app/models/service_config.js
index b45cb0d..6d5007e 100644
--- a/ambari-web/app/models/service_config.js
+++ b/ambari-web/app/models/service_config.js
@@ -59,9 +59,10 @@ App.ServiceConfig = Ember.Object.extend({
   }.property('configs.@each.isValid', 'configs.@each.isVisible', 
'configCategories.@each.slaveErrorCount', 'configs.@each.overrideErrorTrigger'),
 
   isPropertiesChanged: function() {
-return this.get('configs').someProperty('isNotSaved') ||
-   this.get('configs').someProperty('isNotDefaultValue') ||
-   this.get('configs').someProperty('isOverrideChanged') ||
+var requiredByAgent = 
this.get('configs').filterProperty('isRequiredByAgent');
+return requiredByAgent.someProperty('isNotSaved') ||
+   requiredByAgent.someProperty('isNotDefaultValue') ||
+   requiredByAgent.someProperty('isOverrideChanged') ||
this.get('configs.length') !== this.get('initConfigsLength') ||
(this.get('configs.length') === this.get('initConfigsLength')  
this.get('configs').someProperty('defaultValue', null));
   }.property('configs.@each.isNotDefaultValue', 
'configs.@each.isOverrideChanged', 'configs.length', 'configs.@each.isNotSaved')

http://git-wip-us.apache.org/repos/asf/ambari/blob/52705c26/ambari-web/app/utils/config.js
--
diff --git a/ambari-web/app/utils/config.js b/ambari-web/app/utils/config.js
index 874c7e9..c298fb3 100644
--- a/ambari-web/app/utils/config.js
+++ b/ambari-web/app/utils/config.js
@@ -351,6 +351,7 @@ App.config = Em.Object.create({
 if 
(!this.getBySiteName(serviceConfigObj.get('filename')).someProperty('name', 
index)) {
   if (configsPropertyDef) {
 if (Em.get(configsPropertyDef, 'isRequiredByAgent') === false) {
+  configs.push(serviceConfigObj);
   continue;
 }
 this.handleSpecialProperties(serviceConfigObj);



ambari git commit: AMBARI-10773. Hive Ranger plugin fails to install with non-root agent (aonishuk)

2015-04-27 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 52705c266 - f13d983dd


AMBARI-10773. Hive Ranger plugin fails to install with non-root agent (aonishuk)


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

Branch: refs/heads/trunk
Commit: f13d983dd0d27ce1c9e25447c9eea11ea72eceff
Parents: 52705c2
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Mon Apr 27 20:12:19 2015 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Mon Apr 27 20:12:19 2015 +0300

--
 .../libraries/functions/__init__.py |   1 +
 .../libraries/functions/ranger_functions.py |   4 +-
 .../libraries/functions/setup_ranger_plugin.py  |  76 
 .../0.96.0.2.0/package/scripts/params_linux.py  |  15 +-
 .../package/scripts/setup_ranger_hbase.py   |  54 +-
 .../2.1.0.2.0/package/scripts/params_linux.py   |  17 +-
 .../package/scripts/setup_ranger_hdfs.py|  54 +-
 .../0.12.0.2.0/package/scripts/params_linux.py  | 123 ++--
 .../package/scripts/setup_ranger_hive.py| 192 +--
 .../ranger-hive-plugin-properties.xml   |  48 +
 .../python/stacks/2.0.6/configs/default.json|  61 +-
 .../stacks/2.0.6/configs/default_client.json|  33 +++-
 .../2.0.6/configs/default_no_install.json   |  29 ++-
 .../python/stacks/2.0.6/configs/secured.json|  60 +-
 .../stacks/2.0.6/configs/secured_client.json|  33 +++-
 .../test/python/stacks/2.1/configs/default.json |  30 +++
 .../test/python/stacks/2.1/configs/secured.json |  30 +++
 .../python/stacks/2.2/configs/hive-upgrade.json |  31 ++-
 18 files changed, 506 insertions(+), 385 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f13d983d/ambari-common/src/main/python/resource_management/libraries/functions/__init__.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/functions/__init__.py
 
b/ambari-common/src/main/python/resource_management/libraries/functions/__init__.py
index f4822ce..e06d246 100644
--- 
a/ambari-common/src/main/python/resource_management/libraries/functions/__init__.py
+++ 
b/ambari-common/src/main/python/resource_management/libraries/functions/__init__.py
@@ -41,6 +41,7 @@ from resource_management.libraries.functions.constants import 
*
 from resource_management.libraries.functions.get_hdp_version import *
 from resource_management.libraries.functions.get_lzo_packages import *
 from resource_management.libraries.functions.dynamic_variable_interpretation 
import *
+from resource_management.libraries.functions.setup_ranger_plugin import *
 
 IS_WINDOWS = platform.system() == Windows
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/f13d983d/ambari-common/src/main/python/resource_management/libraries/functions/ranger_functions.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/functions/ranger_functions.py
 
b/ambari-common/src/main/python/resource_management/libraries/functions/ranger_functions.py
index e47f1dc..63e5df1 100644
--- 
a/ambari-common/src/main/python/resource_management/libraries/functions/ranger_functions.py
+++ 
b/ambari-common/src/main/python/resource_management/libraries/functions/ranger_functions.py
@@ -23,8 +23,8 @@ from StringIO import StringIO as BytesIO
 import json
 from resource_management.core.logger import Logger
 import urllib2, base64, httplib
-from resource_management import *
-
+from resource_management.core.exceptions import Fail
+from resource_management.libraries.functions.format import format
 
 class Rangeradmin:
   sInstance = None

http://git-wip-us.apache.org/repos/asf/ambari/blob/f13d983d/ambari-common/src/main/python/resource_management/libraries/functions/setup_ranger_plugin.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/functions/setup_ranger_plugin.py
 
b/ambari-common/src/main/python/resource_management/libraries/functions/setup_ranger_plugin.py
new file mode 100644
index 000..da5c559
--- /dev/null
+++ 
b/ambari-common/src/main/python/resource_management/libraries/functions/setup_ranger_plugin.py
@@ -0,0 +1,76 @@
+#!/usr/bin/env python
+
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+License); you may not use this file 

[2/2] ambari git commit: AMBARI-10714 - Separate memory configuration for Hive CLI vs HiveServer2

2015-04-27 Thread abaranchuk
AMBARI-10714 - Separate memory configuration for Hive CLI vs HiveServer2


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

Branch: refs/heads/trunk
Commit: 930b3e4ee567006d2611d1dcb4a694726e984899
Parents: 5e2f6b8
Author: Artem Baranchuk abaranc...@hortonworks.con
Authored: Tue Apr 28 02:26:48 2015 +0300
Committer: Artem Baranchuk abaranc...@hortonworks.con
Committed: Tue Apr 28 02:27:04 2015 +0300

--
 .../HIVE/0.12.0.2.0/configuration/hive-env.xml| 6 ++
 .../HIVE/0.12.0.2.0/package/scripts/params_linux.py   | 7 ++-
 .../stacks/HDP/2.2/services/HIVE/configuration/hive-env.xml   | 5 +
 3 files changed, 17 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/930b3e4e/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
--
diff --git 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
index 52cfa10..92373ad 100644
--- 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
+++ 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
@@ -22,6 +22,12 @@
 
 configuration
   property
+namehive.client.heapsize/name
+value512/value
+descriptionHive Client Java heap size/description
+  /property
+
+  property
 namehive_database_type/name
 valuemysql/value
 descriptionDefault HIVE DB type./description

http://git-wip-us.apache.org/repos/asf/ambari/blob/930b3e4e/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
--
diff --git 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
index dae198e..62d1a8a 100644
--- 
a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
+++ 
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
@@ -214,7 +214,12 @@ start_hiveserver2_path = 
format({tmp_dir}/start_hiveserver2_script)
 start_metastore_path = format({tmp_dir}/start_metastore_script)
 
 hadoop_heapsize = config['configurations']['hadoop-env']['hadoop_heapsize']
-hive_heapsize = config['configurations']['hive-site']['hive.heapsize']
+
+if 'role' in config and config['role'] in [HIVE_SERVER, HIVE_METASTORE]:
+  hive_heapsize = config['configurations']['hive-site']['hive.heapsize']
+else:
+  hive_heapsize = config['configurations']['hive-env']['hive.client.heapsize']
+
 java64_home = config['hostLevelParams']['java_home']
 
 # MYSQL

http://git-wip-us.apache.org/repos/asf/ambari/blob/930b3e4e/ambari-server/src/main/resources/stacks/HDP/2.2/services/HIVE/configuration/hive-env.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/HIVE/configuration/hive-env.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/HIVE/configuration/hive-env.xml
index 1e0feb2..ce60563 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/HIVE/configuration/hive-env.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/HIVE/configuration/hive-env.xml
@@ -21,6 +21,11 @@
 --
 
 configuration
+  property
+namehive.client.heapsize/name
+deletedtrue/deleted
+  /property
+
   !-- hive-env.sh --
   property
 namecontent/name



[1/2] ambari git commit: AMBARI-10753 - [WinTP2] sql exception during server setup

2015-04-27 Thread abaranchuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 6a054b35a - 930b3e4ee


AMBARI-10753 - [WinTP2] sql exception during server setup


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

Branch: refs/heads/trunk
Commit: 5e2f6b85a25e7a87fee7054c71289c6cebd8d4b7
Parents: 6a054b3
Author: Artem Baranchuk abaranc...@hortonworks.con
Authored: Tue Apr 28 02:24:16 2015 +0300
Committer: Artem Baranchuk abaranc...@hortonworks.con
Committed: Tue Apr 28 02:27:03 2015 +0300

--
 ambari-server/src/main/resources/Ambari-DDL-SQLServer-DROP.sql | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/5e2f6b85/ambari-server/src/main/resources/Ambari-DDL-SQLServer-DROP.sql
--
diff --git a/ambari-server/src/main/resources/Ambari-DDL-SQLServer-DROP.sql 
b/ambari-server/src/main/resources/Ambari-DDL-SQLServer-DROP.sql
index 8cb3132..f972edc 100644
--- a/ambari-server/src/main/resources/Ambari-DDL-SQLServer-DROP.sql
+++ b/ambari-server/src/main/resources/Ambari-DDL-SQLServer-DROP.sql
@@ -147,6 +147,8 @@ IF OBJECT_ID('request', 'U') IS NOT NULL DROP TABLE request
 GO
 IF OBJECT_ID('requestschedule', 'U') IS NOT NULL DROP TABLE requestschedule
 GO
+IF OBJECT_ID('serviceconfighosts', 'U') IS NOT NULL DROP TABLE 
serviceconfighosts
+GO
 IF OBJECT_ID('hoststate', 'U') IS NOT NULL DROP TABLE hoststate
 GO
 IF OBJECT_ID('hostcomponentdesiredstate', 'U') IS NOT NULL DROP TABLE 
hostcomponentdesiredstate
@@ -185,8 +187,6 @@ IF OBJECT_ID('alert_history', 'U') IS NOT NULL DROP TABLE 
alert_history
 GO
 IF OBJECT_ID('alert_definition', 'U') IS NOT NULL DROP TABLE alert_definition
 GO
-IF OBJECT_ID('serviceconfighosts', 'U') IS NOT NULL DROP TABLE 
serviceconfighosts
-GO
 IF OBJECT_ID('serviceconfigmapping', 'U') IS NOT NULL DROP TABLE 
serviceconfigmapping
 GO
 IF OBJECT_ID('serviceconfig', 'U') IS NOT NULL DROP TABLE serviceconfig



ambari git commit: AMBARI-10772 Create widget - Add metric popup: Aggregator Function dropdown for component metrics. (atkach)

2015-04-27 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk e8f315cea - 1c46571f9


AMBARI-10772 Create widget - Add metric popup: Aggregator Function dropdown 
for component metrics. (atkach)


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

Branch: refs/heads/trunk
Commit: 1c46571f95bf0c2034163349a58b6417d0271984
Parents: e8f315c
Author: Andrii Tkach atk...@hortonworks.com
Authored: Mon Apr 27 19:52:34 2015 +0300
Committer: Andrii Tkach atk...@hortonworks.com
Committed: Mon Apr 27 20:54:24 2015 +0300

--
 ambari-web/app/messages.js  |  2 +
 .../app/styles/enhanced_service_dashboard.less  |  1 +
 .../service/widgets/create/step2_add_metric.hbs | 15 ++
 .../service/widgets/create/expression_view.js   | 48 ++--
 4 files changed, 62 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/1c46571f/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 1d5077e..7dd8a57 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -2534,6 +2534,8 @@ Em.I18n.translations = {
   'dashboard.widgets.wizard.step2.selectComponent': 'Select a Component',
   'dashboard.widgets.wizard.step2.selectMetric': 'Select a Metric',
   'dashboard.widgets.wizard.step2.addMetric': 'Add Metric',
+  'dashboard.widgets.wizard.step2.aggregateFunction': 'Aggregator Function',
+  'dashboard.widgets.wizard.step2.aggregateTooltip': 'This mathematical 
function will be applied to compute single value for selected metric across all 
host components',
 
   'restart.service.all': 'Restart All',
   'restart.service.all.affected': 'Restart All Affected',

http://git-wip-us.apache.org/repos/asf/ambari/blob/1c46571f/ambari-web/app/styles/enhanced_service_dashboard.less
--
diff --git a/ambari-web/app/styles/enhanced_service_dashboard.less 
b/ambari-web/app/styles/enhanced_service_dashboard.less
index 852eccb..2f9a190 100644
--- a/ambari-web/app/styles/enhanced_service_dashboard.less
+++ b/ambari-web/app/styles/enhanced_service_dashboard.less
@@ -423,6 +423,7 @@
   line-height: 30px;
 }
   }
+  .aggregator-select,
   .component-select {
 .btn.dropdown-toggle {
   border-radius: 4px;

http://git-wip-us.apache.org/repos/asf/ambari/blob/1c46571f/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
--
diff --git 
a/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs 
b/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
index 2b9c184..9492d8b 100644
--- a/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
+++ b/ambari-web/app/templates/main/service/widgets/create/step2_add_metric.hbs
@@ -61,3 +61,18 @@
 /select
   /div
 /div
+
+div class=row-fluid {{bindAttr class=:row-fluid 
view.showAggregateSelect::hidden}}
+  div class=span3{{t 
dashboard.widgets.wizard.step2.aggregateFunction}}/div
+  div class=btn-group aggregator-select span5 {{translateAttr 
data-original-title=dashboard.widgets.wizard.step2.aggregateTooltip}}
+button class=btn dropdown-toggle data-toggle=dropdown
+  {{view.parentView.aggregateFunction}}
+  span class=caret pull-right/span
+/button
+ul class=dropdown-menu
+  {{#each aggregation in view.parentView.AGGREGATE_FUNCTIONS}}
+lia href=# {{action selectAggregation aggregation 
target=view}}{{aggregation}}/a/li
+  {{/each}}
+/ul
+  /div
+/div

http://git-wip-us.apache.org/repos/asf/ambari/blob/1c46571f/ambari-web/app/views/main/service/widgets/create/expression_view.js
--
diff --git 
a/ambari-web/app/views/main/service/widgets/create/expression_view.js 
b/ambari-web/app/views/main/service/widgets/create/expression_view.js
index 0b4e1f2..7c20276 100644
--- a/ambari-web/app/views/main/service/widgets/create/expression_view.js
+++ b/ambari-web/app/views/main/service/widgets/create/expression_view.js
@@ -165,11 +165,22 @@ App.WidgetWizardExpressionView = Em.View.extend({
   expression: this.get('expression'),
 
   /**
+   * @type {Array}
+   * @const
+   */
+  AGGREGATE_FUNCTIONS: ['avg', 'sum', 'min', 'max'],
+
+  /**
* @type {object|null}
*/
   selectedMetric: null,
 
   /**
+   * @type {string|null}
+   */
+  aggregateFunction: null,
+
+  /**
* @type {Ember.View}
* 

ambari git commit: AMBARI-10771. Agent upgrade loses custom hostname config (aonishuk)

2015-04-27 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk f13d983dd - e8f315cea


AMBARI-10771. Agent upgrade loses custom hostname config (aonishuk)


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

Branch: refs/heads/trunk
Commit: e8f315cea72f95a8de5011eefd6c298cf47b14c5
Parents: f13d983
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Mon Apr 27 20:24:32 2015 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Mon Apr 27 20:24:32 2015 +0300

--
 ambari-agent/conf/unix/upgrade_agent_configs.py | 51 
 ambari-agent/pom.xml| 22 +
 .../src/main/package/deb/control/postinst   |  7 +--
 .../src/main/package/rpm/postinstall.sh |  7 +--
 4 files changed, 81 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e8f315ce/ambari-agent/conf/unix/upgrade_agent_configs.py
--
diff --git a/ambari-agent/conf/unix/upgrade_agent_configs.py 
b/ambari-agent/conf/unix/upgrade_agent_configs.py
new file mode 100644
index 000..8b7be7a
--- /dev/null
+++ b/ambari-agent/conf/unix/upgrade_agent_configs.py
@@ -0,0 +1,51 @@
+#!/usr/bin/ambari-python-wrap
+'''
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+License); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an AS IS BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+'''
+
+import os
+import ConfigParser
+
+PROPERTIES_TO_REWRITE = [
+  ('heartbeat', 'dirs')
+]
+
+CONFIG_FILE_BACKUP = '/etc/ambari-agent/conf/ambari-agent.ini.old'
+CONFIG_FILE = '/etc/ambari-agent/conf/ambari-agent.ini'
+
+if os.path.isfile(CONFIG_FILE_BACKUP):
+  if os.path.isfile(CONFIG_FILE):
+print Upgrading configs in {0}.format(CONFIG_FILE)
+print Values will be updated from {0} except the following list: 
{1}.format(CONFIG_FILE_BACKUP, PROPERTIES_TO_REWRITE)
+
+agent_config_backup = ConfigParser.ConfigParser()
+agent_config_backup.read(CONFIG_FILE_BACKUP)
+
+agent_config = ConfigParser.ConfigParser()
+agent_config.read(CONFIG_FILE)
+
+for section in agent_config_backup.sections():
+  for (property_name, property_val) in agent_config_backup.items(section):
+if (section, property_name) not in PROPERTIES_TO_REWRITE:
+  agent_config.set(section, property_name, property_val)
+
+with (open(CONFIG_FILE, wb)) as new_agent_config:
+  agent_config.write(new_agent_config)
+  else:
+print Values are not updated, configs {0} is not 
found.format(CONFIG_FILE)
+else:
+  print Values are not updated, backup {0} is not 
found.format(CONFIG_FILE_BACKUP)
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/e8f315ce/ambari-agent/pom.xml
--
diff --git a/ambari-agent/pom.xml b/ambari-agent/pom.xml
index 4476011..a57e760 100644
--- a/ambari-agent/pom.xml
+++ b/ambari-agent/pom.xml
@@ -341,6 +341,17 @@
   /sources
 /mapping
 mapping
+  directory/var/lib/ambari-agent/directory
+  filemode700/filemode
+  usernameroot/username
+  groupnameroot/groupname
+  sources
+source
+  locationconf/unix/upgrade_agent_configs.py/location
+/source
+  /sources
+/mapping
+mapping
   directory${package.pid.dir}/directory
   filemode755/filemode
   usernameroot/username
@@ -522,6 +533,17 @@
   /mapper
 /data
 data
+  srcconf/unix/upgrade_agent_configs.py/src
+  typefile/type
+  mapper
+typeperm/type
+prefix/var/lib/ambari-agent/prefix
+userroot/user
+grouproot/group
+filemode700/filemode
+  /mapper
+/data
+data
   typetemplate/type
   paths
 

ambari git commit: AMBARI-10767 - Views : create Spring app example (tbeerbower)

2015-04-27 Thread tbeerbower
Repository: ambari
Updated Branches:
  refs/heads/trunk 1c46571f9 - 6d737ddc6


AMBARI-10767 - Views : create Spring app example (tbeerbower)


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

Branch: refs/heads/trunk
Commit: 6d737ddc6daa9cae302fe79c4063cf1a0a975d6f
Parents: 1c46571
Author: tbeerbower tbeerbo...@hortonworks.com
Authored: Mon Apr 27 14:18:56 2015 -0400
Committer: tbeerbower tbeerbo...@hortonworks.com
Committed: Mon Apr 27 14:19:08 2015 -0400

--
 .../examples/hello-spring-view/docs/index.md| 154 +++
 ambari-views/examples/hello-spring-view/pom.xml | 130 
 .../ambari/view/hello/HelloController.java  |  50 ++
 .../src/main/resources/view.xml |  24 +++
 .../src/main/webapp/WEB-INF/Hello-servlet.xml   |  33 
 .../src/main/webapp/WEB-INF/jsp/hello.jsp   |  26 
 .../src/main/webapp/WEB-INF/web.xml |  37 +
 ambari-views/examples/pom.xml   |   1 +
 8 files changed, 455 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6d737ddc/ambari-views/examples/hello-spring-view/docs/index.md
--
diff --git a/ambari-views/examples/hello-spring-view/docs/index.md 
b/ambari-views/examples/hello-spring-view/docs/index.md
new file mode 100644
index 000..b621db2
--- /dev/null
+++ b/ambari-views/examples/hello-spring-view/docs/index.md
@@ -0,0 +1,154 @@
+!---
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the License); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at 
[http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0)
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an AS IS BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+--
+
+Hello Spring View Example
+
+Description
+-
+The Hello Spring view is a very simple view example that uses Spring MVC.  
Like the HelloWorld view example, it demonstrates the basics of how to write 
and deploy a view in Ambari but also shows a simple web application using the 
Spring MVC framework.  The Hello Spring view displays a Hello message that is 
customized based on the currently logged in user.
+
+Package
+-
+
+All views are packaged as a view archive.  The view archive contains the 
configuration file and various optional components of the view.
+
+#view.xml
+
+The view.xml file is the only required file for a view archive.  The view.xml 
is the configuration that describes the view and view instances for Ambari.
+
+  view
+nameHELLO_SPRING/name
+labelThe Hello Spring View/label
+version1.0.0/version
+instance
+  nameINSTANCE/name
+/instance
+  /view
+
+The configuration in this case defines a view named HELLO_SPRING that has a 
single instance.
+
+
+#HelloController.java
+
+The HelloController class is the controller for the Spring MVC app.
+
+Notice that we can access the view context through the servlet context.
+
+// get the view context from the servlet context
+ViewContext viewContext = (ViewContext) 
request.getSession().getServletContext().getAttribute(ViewContext.CONTEXT_ATTRIBUTE);
+
+// get the current user name from the view context
+String userName = viewContext.getUsername();
+
+
+For this app, the controller saves a customized greeting to a model attribute.
+
+// add the greeting message attribute
+model.addAttribute(greeting, Hello  + (userName == null ? unknown 
user : userName) + !);
+
+
+
+#WEB-INF/web.xml
+The web.xml is the deployment descriptor used to deploy the view as a web app. 
 The Java EE standards apply for the descriptor.  We can see that for this 
example a single servlet is mapped to the root context path.  The class for the 
servlet is the Spring DispatcherServlet.
+
+servlet
+  servlet-nameHello/servlet-name
+  
servlet-classorg.springframework.web.servlet.DispatcherServlet/servlet-class
+  load-on-startup0/load-on-startup
+/servlet
+servlet-mapping
+  servlet-nameHello/servlet-name
+  url-pattern//url-pattern
+   

ambari git commit: AMBARI-10770. Fix blueprint configuration validation regarding password properties.

2015-04-27 Thread jspeidel
Repository: ambari
Updated Branches:
  refs/heads/trunk 3a42dfa77 - fa6194265


AMBARI-10770.  Fix blueprint configuration validation regarding password 
properties.


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

Branch: refs/heads/trunk
Commit: fa6194265f8ae0ba98806b50f88497bf659cdead
Parents: 3a42dfa
Author: John Speidel jspei...@hortonworks.com
Authored: Mon Apr 27 12:46:40 2015 -0400
Committer: John Speidel jspei...@hortonworks.com
Committed: Mon Apr 27 15:09:21 2015 -0400

--
 .../server/controller/internal/Stack.java   |  35 +++---
 .../server/controller/internal/StackTest.java   | 117 +++
 2 files changed, 137 insertions(+), 15 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fa619426/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/Stack.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/Stack.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/Stack.java
index 82d03fd..7167449 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/Stack.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/Stack.java
@@ -634,25 +634,23 @@ public class Stack {
 
 // shouldn't have any required properties in stack level configuration
 for (StackConfigurationResponse config : serviceConfigs) {
-  String type = config.getType();
-  //strip .xml from type
-  if (type.endsWith(.xml)) {
-type = type.substring(0, type.length() - 4);
-  }
+  ConfigProperty configProperty = new ConfigProperty(config);
+  String type = configProperty.getType();
+
   MapString, ConfigProperty mapTypeConfig = mapServiceConfig.get(type);
   if (mapTypeConfig == null) {
 mapTypeConfig = new HashMapString, ConfigProperty();
 mapServiceConfig.put(type, mapTypeConfig);
   }
-  ConfigProperty property = new ConfigProperty(config);
-  mapTypeConfig.put(config.getPropertyName(), property);
+
+  mapTypeConfig.put(config.getPropertyName(), configProperty);
   if (config.isRequired()) {
 MapString, ConfigProperty requiredTypeConfig = 
mapRequiredServiceConfig.get(type);
 if (requiredTypeConfig == null) {
   requiredTypeConfig = new HashMapString, ConfigProperty();
   mapRequiredServiceConfig.put(type, requiredTypeConfig);
 }
-requiredTypeConfig.put(config.getPropertyName(), property);
+requiredTypeConfig.put(config.getPropertyName(), configProperty);
   }
 }
   }
@@ -663,18 +661,17 @@ public class Stack {
 Collections.singleton(new StackLevelConfigurationRequest(name, 
version, null)));
 
 for (StackConfigurationResponse config : stackLevelConfigs) {
-  String type = config.getType();
-  //strip .xml from type
-  if (type.endsWith(.xml)) {
-type = type.substring(0, type.length() - 4);
-  }
+  ConfigProperty configProperty = new ConfigProperty(config);
+  String type = configProperty.getType();
+
   MapString, ConfigProperty mapTypeConfig = 
stackConfigurations.get(type);
   if (mapTypeConfig == null) {
 mapTypeConfig = new HashMapString, ConfigProperty();
 stackConfigurations.put(type, mapTypeConfig);
   }
+
   mapTypeConfig.put(config.getPropertyName(),
-  new ConfigProperty(config));
+  configProperty);
 }
   }
 
@@ -710,7 +707,7 @@ public class Stack {
   this.value = config.getPropertyValue();
   this.attributes = config.getPropertyAttributes();
   this.propertyTypes = config.getPropertyType();
-  this.type = config.getType();
+  this.type = normalizeType(config.getType());
 }
 
 public ConfigProperty(String type, String name, String value) {
@@ -750,5 +747,13 @@ public class Stack {
 public void setAttributes(MapString, String attributes) {
   this.attributes = attributes;
 }
+
+private String normalizeType(String type) {
+  //strip .xml from type
+  if (type.endsWith(.xml)) {
+type = type.substring(0, type.length() - 4);
+  }
+  return type;
+}
   }
 }

http://git-wip-us.apache.org/repos/asf/ambari/blob/fa619426/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/StackTest.java
--
diff --git 
a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/StackTest.java