git commit: AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster Dashboard, or Views Landing page). (yusaku)

2014-08-28 Thread yusaku
Repository: ambari
Updated Branches:
  refs/heads/trunk 2051c64e7 - e1634809f


AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster 
Dashboard, or Views Landing page). (yusaku)


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

Branch: refs/heads/trunk
Commit: e1634809f0c4c6a6acfe1b2672b4ddfcaf2d5e92
Parents: 2051c64
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 23:09:59 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 23:09:59 2014 -0700

--
 .../controllers/global/cluster_controller.js| 44 
 1 file changed, 44 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e1634809/ambari-web/app/controllers/global/cluster_controller.js
--
diff --git a/ambari-web/app/controllers/global/cluster_controller.js 
b/ambari-web/app/controllers/global/cluster_controller.js
index 246ad8b..bc09b0a 100644
--- a/ambari-web/app/controllers/global/cluster_controller.js
+++ b/ambari-web/app/controllers/global/cluster_controller.js
@@ -347,50 +347,6 @@ App.ClusterController = Em.Controller.extend({
 }, callback)
   },
 
-  loadAmbariViews: function () {
-App.ajax.send({
-  name: 'views.info',
-  sender: this,
-  success: 'loadAmbariViewsSuccess'
-});
-  },
-
-  loadAmbariViewsSuccess: function (data) {
-if (data.items.length) {
-  App.ajax.send({
-name: 'views.instances',
-sender: this,
-success: 'loadViewInstancesSuccess'
-  });
-} else {
-  this.set('ambariViews', []);
-}
-  },
-
-  loadViewInstancesSuccess: function (data) {
-this.set('ambariViews', []);
-var self = this;
-data.items.forEach(function (view) {
-  view.versions.forEach(function (version) {
-version.instances.forEach(function (instance) {
-  var current_instance = Em.Object.create({
-iconPath: instance.ViewInstanceInfo.icon_path || 
/img/ambari-view-default.png,
-label: instance.ViewInstanceInfo.label || 
version.ViewVersionInfo.label || instance.ViewInstanceInfo.view_name,
-visible: instance.ViewInstanceInfo.visible || false,
-version: instance.ViewInstanceInfo.version,
-description: instance.ViewInstanceInfo.description || 
Em.I18n.t('views.main.instance.noDescription'),
-viewName: instance.ViewInstanceInfo.view_name,
-instanceName: instance.ViewInstanceInfo.instance_name,
-href: instance.ViewInstanceInfo.context_path
-  });
-  if( current_instance.visible){
-self.get('ambariViews').pushObject(current_instance);
-  }
-}, this);
-  }, this);
-}, this);
-  },
-
   /**
*
* @param callback



git commit: Revert AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster Dashboard, or Views Landing page). (yusaku)

2014-08-28 Thread yusaku
Repository: ambari
Updated Branches:
  refs/heads/trunk e1634809f - af67390b9


Revert AMBARI-6967. Admin View: default login behavior (route to Admin View, 
Cluster Dashboard, or Views Landing page). (yusaku)

This reverts commit e1634809f0c4c6a6acfe1b2672b4ddfcaf2d5e92.


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

Branch: refs/heads/trunk
Commit: af67390b9ca47bd6b34a54638c9f5cc8323017fd
Parents: e163480
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 23:56:32 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 23:56:32 2014 -0700

--
 .../controllers/global/cluster_controller.js| 44 
 1 file changed, 44 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/af67390b/ambari-web/app/controllers/global/cluster_controller.js
--
diff --git a/ambari-web/app/controllers/global/cluster_controller.js 
b/ambari-web/app/controllers/global/cluster_controller.js
index bc09b0a..246ad8b 100644
--- a/ambari-web/app/controllers/global/cluster_controller.js
+++ b/ambari-web/app/controllers/global/cluster_controller.js
@@ -347,6 +347,50 @@ App.ClusterController = Em.Controller.extend({
 }, callback)
   },
 
+  loadAmbariViews: function () {
+App.ajax.send({
+  name: 'views.info',
+  sender: this,
+  success: 'loadAmbariViewsSuccess'
+});
+  },
+
+  loadAmbariViewsSuccess: function (data) {
+if (data.items.length) {
+  App.ajax.send({
+name: 'views.instances',
+sender: this,
+success: 'loadViewInstancesSuccess'
+  });
+} else {
+  this.set('ambariViews', []);
+}
+  },
+
+  loadViewInstancesSuccess: function (data) {
+this.set('ambariViews', []);
+var self = this;
+data.items.forEach(function (view) {
+  view.versions.forEach(function (version) {
+version.instances.forEach(function (instance) {
+  var current_instance = Em.Object.create({
+iconPath: instance.ViewInstanceInfo.icon_path || 
/img/ambari-view-default.png,
+label: instance.ViewInstanceInfo.label || 
version.ViewVersionInfo.label || instance.ViewInstanceInfo.view_name,
+visible: instance.ViewInstanceInfo.visible || false,
+version: instance.ViewInstanceInfo.version,
+description: instance.ViewInstanceInfo.description || 
Em.I18n.t('views.main.instance.noDescription'),
+viewName: instance.ViewInstanceInfo.view_name,
+instanceName: instance.ViewInstanceInfo.instance_name,
+href: instance.ViewInstanceInfo.context_path
+  });
+  if( current_instance.visible){
+self.get('ambariViews').pushObject(current_instance);
+  }
+}, this);
+  }, this);
+}, this);
+  },
+
   /**
*
* @param callback



git commit: AMBARI-7052 Unable to load step 1 of Add Service Wizard. (Max Shepel via ababiichuk)

2014-08-28 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk cd0081c55 - b35b87d6f


AMBARI-7052 Unable to load step 1 of Add Service Wizard.  (Max Shepel via 
ababiichuk)


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

Branch: refs/heads/trunk
Commit: b35b87d6f70d5b2cca7501826096f5840b9fc9eb
Parents: cd0081c
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Thu Aug 28 12:50:15 2014 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Thu Aug 28 12:50:15 2014 +0300

--
 ambari-web/app/mappers/stack_service_mapper.js | 1 -
 1 file changed, 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/b35b87d6/ambari-web/app/mappers/stack_service_mapper.js
--
diff --git a/ambari-web/app/mappers/stack_service_mapper.js 
b/ambari-web/app/mappers/stack_service_mapper.js
index 1f3d0c2..e74308d 100644
--- a/ambari-web/app/mappers/stack_service_mapper.js
+++ b/ambari-web/app/mappers/stack_service_mapper.js
@@ -103,7 +103,6 @@ App.stackServiceMapper = App.QuickDataMapper.create({
 Ember.run(this, function () {
   rec.deleteRecord();
   App.store.commit();
-  rec.get('stateManager').transitionTo('loading');
 });
   }, this);
 }, this);



git commit: AMBARI-7053 Config History: Compare UI tweaks. (atkach)

2014-08-28 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk b35b87d6f - 6bcd6d55c


AMBARI-7053 Config History: Compare UI tweaks. (atkach)


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

Branch: refs/heads/trunk
Commit: 6bcd6d55c980f13e56ae9ddc8d4ab15371893d98
Parents: b35b87d
Author: atkach atk...@hortonworks.com
Authored: Thu Aug 28 14:17:32 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Thu Aug 28 14:17:32 2014 +0300

--
 .../controllers/main/service/info/configs.js|   7 +
 ambari-web/app/messages.js  |   1 +
 ambari-web/app/styles/application.less  |  14 +-
 .../common/configs/compare_property.hbs |   8 ++
 .../common/configs/config_history_flow.hbs  | 128 +++
 .../common/configs/service_config_category.hbs  |  30 +++--
 .../views/common/configs/config_history_flow.js |   9 +-
 7 files changed, 131 insertions(+), 66 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6bcd6d55/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 78c9b53..22e3aac 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -572,6 +572,11 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   allConfigs.push(this.getMockConfig(prop, serviceName, 
App.config.getOriginalFileName(configuration.type)));
 }
   }
+  if (configuration.properties_attributes  
configuration.properties_attributes.final) {
+for (var final in configuration.properties_attributes.final) {
+  serviceVersionMap[final].isFinal = 
(configuration.properties_attributes.final[final] === 'true');
+}
+  }
 }, this);
 
 allConfigs.forEach(function (serviceConfig) {
@@ -587,6 +592,8 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   compareObject.isMock = false;
 }
 serviceConfig.compareConfig = 
App.ServiceConfigProperty.create(compareObject);
+this.setSupportsFinal(serviceConfig.compareConfig);
+serviceConfig.compareConfig.set('isFinal', compareConfig.isFinal);
 serviceConfig.compareConfig.set('value', 
App.config.formatOverrideValue(serviceConfig, compareConfig.value));
 serviceConfig.isComparison = true;
   } else if (serviceConfig.isUserProperty) {

http://git-wip-us.apache.org/repos/asf/ambari/blob/6bcd6d55/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 9579b04..36bfa10 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1993,6 +1993,7 @@ Em.I18n.translations = {
   'dashboard.configHistory.table.created.title' : 'Created',
   'dashboard.configHistory.table.empty' : 'No history to display',
   'dashboard.configHistory.table.version.versionText' : 'V{0}',
+  'dashboard.configHistory.table.version.prefix' : 'V',
   'dashboard.configHistory.table.current.tooltip' : 'Current config for 
{0}:{1}',
   'dashboard.configHistory.table.restart.tooltip' : 'Restart required',
   'dashboard.configHistory.table.filteredHostsInfo': '{0} of {1} versions 
showing',

http://git-wip-us.apache.org/repos/asf/ambari/blob/6bcd6d55/ambari-web/app/styles/application.less
--
diff --git a/ambari-web/app/styles/application.less 
b/ambari-web/app/styles/application.less
index dd0adb9..0570220 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -4953,8 +4953,14 @@ ul.inline li {
   }
 }
 
-#config_history_flow {
+.one-story-bar {
   margin-bottom: 80px;
+}
+.two-stories-bar {
+  margin-bottom: 120px;
+}
+
+#config_history_flow {
   .version-slider {
 width: 100%;
 height: 100px;
@@ -5069,6 +5075,10 @@ ul.inline li {
   }
 }
   }
+  .version-info-bar-wrapper {
+position: fixed;
+z-index: 2;
+  }
   .version-info-bar {
 background-image: -moz-linear-gradient(top, @top-nav-bg-color-from, 
@top-nav-bg-color-to);
 background-image: -webkit-gradient(linear, 0 0, 0 100%, 
from(@top-nav-bg-color-from), to(@top-nav-bg-color-to));
@@ -5081,8 +5091,6 @@ ul.inline li {
 box-shadow: inset 0 0 0 rgba(0, 0, 0, 0.1), 0 1px 10px rgba(0, 0, 0, 0.1);
 margin: 5px 0;
 padding: 5px;
-position: fixed;

git commit: AMBARI-7054. Slider View: Create app wizard should allow adding of custom-configs. (onechiporenko)

2014-08-28 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk 6bcd6d55c - 0fb6e6355


AMBARI-7054. Slider View: Create app wizard should allow adding of 
custom-configs. (onechiporenko)


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

Branch: refs/heads/trunk
Commit: 0fb6e635577aab62157711f1a73c65feb38018c2
Parents: 6bcd6d5
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 16:26:23 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 16:26:23 2014 +0300

--
 .../ui/app/components/configSection.js  | 122 +--
 .../createAppWizard/step1_controller.js |   1 +
 .../createAppWizard/step3_controller.js |  13 +-
 .../controllers/create_app_wizard_controller.js |  27 +++-
 .../app/templates/components/configSection.hbs  |  58 -
 .../ui/app/templates/createAppWizard/step3.hbs  |   6 +-
 .../src/main/resources/ui/app/translations.js   |   6 +
 7 files changed, 207 insertions(+), 26 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/0fb6e635/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/components/configSection.js 
b/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
index 7b2481d..c5858bc 100644
--- a/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
+++ b/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
@@ -17,32 +17,134 @@
  */
 
 App.ConfigSectionComponent = Em.Component.extend({
-  layoutName:'components/configSection',
-  config:null,
-  section:'',
+
+  layoutName: 'components/configSection',
+
+  config: null,
+
+  section: '',
 
   /**
* label for current section
* @return {String}
*/
   sectionLabel: function () {
-return this.get('section').classify();
+return this.get('section').classify().replace(/([A-Z])/g, ' $1');
   }.property(),
 
   /**
* Return True is section name equals 'general'
* @type {Boolean}
*/
-  isGeneral:Ember.computed.equal('section', 'general'),
+  isGeneral: Ember.computed.equal('section', 'general'),
+
+  /**
+   * Return True is section name equals 'custom'
+   * @type {Boolean}
+   */
+  isCustom: Ember.computed.equal('section', 'custom'),
 
   /**
* Filtered configs for current section
*/
-  sectionConfigs: Ember.computed.filter('config', function(item) {
+  sectionConfigs: Ember.computed.filter('config', function (item) {
 if (this.get('isGeneral')) {
-  return !item.name.match('^site.');
-} else {
-  return !!item.name.match('^site.'+this.get('section')) ;
+  return !item.name.match('^site.')  
this.get('predefinedConfigNames').contains(item.name);
+}
+else {
+  if (this.get('isCustom')) {
+return !this.get('predefinedConfigNames').contains(item.name);
+  }
+  else {
+return !!item.name.match('^site.' + this.get('section'));
+  }
+}
+  }),
+
+  /**
+   * Is button Add Property visible
+   * True - yes, false - no (and App Property-form is visible)
+   * @type {bool}
+   */
+  buttonVisible: true,
+
+  /**
+   * Template for new config
+   * @type {Ember.Object}
+   */
+  newConfig: Em.Object.create({
+name: '',
+value: '',
+nameError: '',
+hasError: false
+  }),
+
+  /**
+   * Clear codenewConfig/code
+   * @method cleanNewConfig
+   */
+  cleanNewConfig: function() {
+this.get('newConfig').setProperties({
+  name: '',
+  value: '',
+  messsage: '',
+  hasError: false
+});
+  },
+
+  actions: {
+
+/**
+ * Click on App Property-button
+ * @method addProperty
+ */
+addProperty: function() {
+  this.toggleProperty('buttonVisible');
+},
+
+/**
+ * Delete custom config added by user
+ * @param {{name: string, label: string, value: *}} config
+ * @method deleteConfig
+ */
+deleteConfig: function(config) {
+  this.get('config').removeObject(config);
+},
+
+/**
+ * Validate and save custom config added by user
+ * @method submit
+ */
+submit: function() {
+  var name = this.get('newConfig.name'),
+value = this.get('newConfig.value');
+  if (this.get('config').mapBy('name').contains(name)) {
+this.get('newConfig').setProperties({
+  hasError: true,
+  messsage: Em.I18n.t('configs.add_property.name_exists')
+});
+return;
+  }
+  if (!/^[A-Za-z][A-Za-z0-9_\-\.]*$/.test(name)) {
+

git commit: AMBARI-7055. Slider View: Metric names and quick-links should be human readable. (onechiporenko)

2014-08-28 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk 0fb6e6355 - ff27e56fe


AMBARI-7055. Slider View: Metric names and quick-links should be human 
readable. (onechiporenko)


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

Branch: refs/heads/trunk
Commit: ff27e56fe8a983c76c40951472575197117b5914
Parents: 0fb6e63
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 16:34:13 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 16:34:13 2014 +0300

--
 .../src/main/resources/ui/app/helpers/helper.js | 32 
 .../ui/app/mappers/slider_apps_mapper.js|  2 +-
 .../resources/ui/app/templates/slider_app.hbs   |  2 +-
 .../ui/app/templates/slider_app/summary.hbs |  2 +-
 4 files changed, 35 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
--
diff --git a/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js 
b/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
index 664328c..88dfcb7 100644
--- a/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
+++ b/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
@@ -68,4 +68,36 @@ App.registerBoundHelper('formatWordBreak', Em.View.extend({
 var r = new RegExp('\\'+d,g);
 return this.get('content')  this.get('content').replace(r, d+'wbr /');
   }.property('content')
+}));
+
+/**
+ * Return formatted string with inserted spaces before upper case and replaced 
'_' to spaces
+ * Also capitalize first letter
+ *
+ * @param {String} content
+ *
+ * Examples:
+ *
+ * returns 'apple'
+ * {{humanize 'Apple'}}
+ *
+ * returns 'apple_banana'
+ * {{humanize 'Apple banana'}}
+ *
+ * returns 'apple_bananaUranium'
+ * {{humanize 'Apple banana Uranium'}}
+ */
+App.registerBoundHelper('humanize', Em.View.extend({
+
+  tagName: 'span',
+
+  template: Ember.Handlebars.compile('{{{view.result}}}'),
+
+  /**
+   * @type {string}
+   */
+  result: function() {
+var content = this.get('content');
+return content  (content[0].toUpperCase() + 
content.slice(1)).replace(/([A-Z])/g, ' $1').replace(/_/g, ' ');
+  }.property('content')
 }));
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js 
b/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
index dbe62bf..e5bcb49 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
@@ -141,7 +141,7 @@ App.SliderAppsMapper = 
App.Mapper.createWithMixins(App.RunPeriodically, {
 masterActiveTime.value = new Date(Date.now() - 
masterActiveTime.value).getHours() + h: + new Date(Date.now() - 
masterActiveTime.value).getMinutes() + m;
   }
   if(masterStartTime){
-masterStartTime.value = (new 
Date(masterStartTime.value).toUTCString());
+masterStartTime.value = (new 
Date(parseInt(masterStartTime.value)).toUTCString());
   }
   apps.push(
 Ember.Object.create({

http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs 
b/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
index b8ab969..f435bdf 100644
--- a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
+++ b/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
@@ -33,7 +33,7 @@
   ul class=dropdown-menu
 {{#each option in controller.availableActions}}
   li
-a {{action 'openModal' option 
target='controller'}}{{option.title}}/a
+a {{action 'openModal' option target='controller'}}{{humanize 
option.title}}/a
   /li
 {{/each}}
   /ul

http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
 

git commit: AMBARI-7051 - Alerts: Expose Creation and Updating of Group Targets Definitions (jonathanhurley)

2014-08-28 Thread jonathanhurley
Repository: ambari
Updated Branches:
  refs/heads/branch-alerts-dev ae8f1e77e - 76fc94ec1


AMBARI-7051 - Alerts: Expose Creation and Updating of Group Targets  
Definitions (jonathanhurley)


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

Branch: refs/heads/branch-alerts-dev
Commit: 76fc94ec1ab6ee904e0efa254c19521a201c06d4
Parents: ae8f1e7
Author: Jonathan Hurley jhur...@hortonworks.com
Authored: Wed Aug 27 21:07:43 2014 -0400
Committer: Jonathan Hurley jhur...@hortonworks.com
Committed: Thu Aug 28 09:38:28 2014 -0400

--
 .../python/ambari_agent/alerts/base_alert.py|  45 ++-
 .../python/ambari_agent/alerts/port_alert.py|  42 +--
 .../server/api/services/AlertGroupService.java  |  10 +
 .../controller/AlertDefinitionResponse.java | 143 +
 .../internal/AlertGroupResourceProvider.java| 144 -
 .../server/orm/dao/AlertDefinitionDAO.java  |  16 +
 .../ambari/server/orm/dao/AlertDispatchDAO.java |  18 +-
 .../orm/entities/AlertDefinitionEntity.java |  37 ++-
 .../server/orm/entities/AlertGroupEntity.java   |  56 +++-
 .../server/orm/entities/AlertTargetEntity.java  |   3 +-
 .../ambari/server/state/alert/AlertTarget.java  |  37 ++-
 .../AlertGroupResourceProviderTest.java | 295 +++
 .../AlertTargetResourceProviderTest.java|   2 +-
 .../server/orm/dao/AlertDefinitionDAOTest.java  |  18 +-
 .../server/orm/dao/AlertDispatchDAOTest.java|  53 ++--
 15 files changed, 773 insertions(+), 146 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/76fc94ec/ambari-agent/src/main/python/ambari_agent/alerts/base_alert.py
--
diff --git a/ambari-agent/src/main/python/ambari_agent/alerts/base_alert.py 
b/ambari-agent/src/main/python/ambari_agent/alerts/base_alert.py
index 88c7f92..bf8ada6 100644
--- a/ambari-agent/src/main/python/ambari_agent/alerts/base_alert.py
+++ b/ambari-agent/src/main/python/ambari_agent/alerts/base_alert.py
@@ -34,7 +34,7 @@ class BaseAlert(object):
 self.alert_meta = alert_meta
 self.alert_source_meta = alert_source_meta
 self.cluster = ''
-self.hostName = ''
+self.host_name = ''
 self._lookup_keys = []
 
 
@@ -54,7 +54,7 @@ class BaseAlert(object):
   def set_cluster(self, cluster, host):
 ''' sets cluster information for the alert '''
 self.cluster = cluster
-self.hostName = host
+self.host_name = host
   
   def collect(self):
 ''' method used for collection.  defers to _collect() '''
@@ -123,4 +123,43 @@ class BaseAlert(object):
 res[0] = the result code
 res[1] = the list of arguments supplied to the reporting text for the 
result code
 '''  
-raise NotImplementedError
\ No newline at end of file
+raise NotImplementedError
+
+  '''
+  See RFC3986, Appendix B
+  Tested on the following cases:
+192.168.54.1
+192.168.54.2:7661
+hdfs://192.168.54.3/foo/bar
+ftp://192.168.54.4:7842/foo/bar;
+
+Returns None if only a port is passsed in
+  '''
+  @staticmethod
+  def get_host_from_url(uri):
+# RFC3986, Appendix B
+parts = 
re.findall('^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?', uri)
+
+# index of parts
+# scheme= 1
+# authority = 3
+# path  = 4
+# query = 6
+# fragment  = 8
+
+host_and_port = uri
+if 0 == len(parts[0][1]):
+  host_and_port = parts[0][4]
+elif 0 == len(parts[0][2]):
+  host_and_port = parts[0][1]
+elif parts[0][2].startswith(//):
+  host_and_port = parts[0][3]
+
+if -1 == host_and_port.find(':'):
+  # if no : then it might only be a port; if it's a port, return this host
+  if host_and_port.isdigit():
+return None
+
+  return host_and_port
+else:
+  return host_and_port.split(':')[0]

http://git-wip-us.apache.org/repos/asf/ambari/blob/76fc94ec/ambari-agent/src/main/python/ambari_agent/alerts/port_alert.py
--
diff --git a/ambari-agent/src/main/python/ambari_agent/alerts/port_alert.py 
b/ambari-agent/src/main/python/ambari_agent/alerts/port_alert.py
index eaf744a..1d34410 100644
--- a/ambari-agent/src/main/python/ambari_agent/alerts/port_alert.py
+++ b/ambari-agent/src/main/python/ambari_agent/alerts/port_alert.py
@@ -39,9 +39,11 @@ class PortAlert(BaseAlert):
   def _collect(self):
 urivalue = self._lookup_property_value(self.uri)
 
-host = get_host_from_url(self, urivalue)
 port = self.port
-
+host = BaseAlert.get_host_from_url(urivalue)
+if host is None:
+  host = self.host_name
+

git commit: AMBARI-7046. Missing metainfo.xml - displayName in 2.1.GlusterFS stack(Scott Creeley via subin)

2014-08-28 Thread subin
Repository: ambari
Updated Branches:
  refs/heads/trunk ff27e56fe - fb8367080


AMBARI-7046. Missing metainfo.xml - displayName in 2.1.GlusterFS stack(Scott 
Creeley via subin)


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

Branch: refs/heads/trunk
Commit: fb8367080acd88d311ced9de903bbb1ba9452254
Parents: ff27e56
Author: Subin su...@apache.org
Authored: Thu Aug 28 13:33:48 2014 +
Committer: Subin su...@apache.org
Committed: Thu Aug 28 13:36:24 2014 +

--
 .../services/FALCON/configuration/global.xml|  63 ---
 .../2.1.GlusterFS/services/FALCON/metainfo.xml  |  19 ++-
 .../GLUSTERFS/configuration/core-site.xml   | 169 ---
 .../services/GLUSTERFS/configuration/global.xml |  59 ---
 .../services/GLUSTERFS/metainfo.xml |   1 +
 .../services/STORM/configuration/global.xml |  39 -
 .../2.1.GlusterFS/services/STORM/metainfo.xml   |   1 +
 .../services/TEZ/configuration/global.xml   |  29 
 .../HDP/2.1.GlusterFS/services/TEZ/metainfo.xml |  22 ++-
 ambari-web/app/models/stack_service.js  |   4 +-
 10 files changed, 41 insertions(+), 365 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fb836708/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
deleted file mode 100644
index fadc02d..000
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
+++ /dev/null
@@ -1,63 +0,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 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.
- */
---
-configuration supports_final=false
-  property
-namefalcon_user/name
-valuefalcon/value
-descriptionFalcon user./description
-  /property
-  property
-namefalcon_port/name
-value15000/value
-descriptionPort the Falcon Server listens on./description
-  /property
-  property
-namefalcon_log_dir/name
-value/var/log/falcon/value
-descriptionFalcon log directory./description
-  /property
-  property
-namefalcon_pid_dir/name
-value/var/run/falcon/value
-descriptionFalcon pid-file directory./description
-  /property
-  property
-namefalcon_local_dir/name
-value/hadoop/falcon/value
-descriptionDirectory where Falcon data, such as activemq data, is 
stored./description
-  /property
-  !--embeddedmq properties--
-  property
-namefalcon.embeddedmq.data/name
-value/hadoop/falcon/embeddedmq/data/value
-descriptionDirectory in which embeddedmq data is stored./description
-  /property
-  property
-namefalcon.embeddedmq/name
-valuetrue/value
-descriptionWhether embeddedmq is enabled or not./description
-  /property
-  property
-namefalcon.emeddedmq.port/name
-value61616/value
-descriptionPort that embeddedmq will listen on./description
-  /property
-/configuration

http://git-wip-us.apache.org/repos/asf/ambari/blob/fb836708/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
index f66d99f..2e444b1 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
@@ -20,21 +20,31 @@
   services
 service
   nameFALCON/name
+  

git commit: AMBARI-7013. Fix UI Unit tests. (onechiporenko)

2014-08-28 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk fb8367080 - 6b7e796ab


AMBARI-7013. Fix UI Unit tests. (onechiporenko)


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

Branch: refs/heads/trunk
Commit: 6b7e796ab162aeb7915539b0e37ca740335366f8
Parents: fb83670
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 17:00:08 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 17:00:08 2014 +0300

--
 .../app/controllers/wizard/step3_controller.js  |   1 +
 .../dashboard/config_history_controller_test.js |  38 +--
 .../test/controllers/wizard/step3_test.js   | 325 +++
 .../test/controllers/wizard/step5_test.js   |  19 --
 .../test/controllers/wizard/step6_test.js   |  34 --
 .../test/controllers/wizard/step7_test.js   |  92 +-
 ambari-web/test/models/stack_service_test.js|  52 +--
 7 files changed, 344 insertions(+), 217 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6b7e796a/ambari-web/app/controllers/wizard/step3_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step3_controller.js 
b/ambari-web/app/controllers/wizard/step3_controller.js
index 3510150..e17c06b 100644
--- a/ambari-web/app/controllers/wizard/step3_controller.js
+++ b/ambari-web/app/controllers/wizard/step3_controller.js
@@ -1138,6 +1138,7 @@ App.WizardStep3Controller = Em.Controller.extend({
* @method repoToAgentOsType
*/
   repoToAgentOsType : function (repoType) {
+/* istanbul ignore next */
 switch (repoType) {
   case redhat6:
 return [redhat6, centos6, oraclelinux6, rhel6];

http://git-wip-us.apache.org/repos/asf/ambari/blob/6b7e796a/ambari-web/test/controllers/main/dashboard/config_history_controller_test.js
--
diff --git 
a/ambari-web/test/controllers/main/dashboard/config_history_controller_test.js 
b/ambari-web/test/controllers/main/dashboard/config_history_controller_test.js
index 0692b9e..18ec48f 100644
--- 
a/ambari-web/test/controllers/main/dashboard/config_history_controller_test.js
+++ 
b/ambari-web/test/controllers/main/dashboard/config_history_controller_test.js
@@ -28,26 +28,21 @@ describe('MainConfigHistoryController', function () {
   describe('#realUrl', function () {
 it('cluster name is empty', function () {
   App.set('clusterName', '');
-  
expect(controller.get('realUrl')).to.equal('/api/v1/clusters//configurations/serviceconfigversions?parametersfields=serviceconfigversion,user,group_id,group_name,createtime,service_name,service_config_version_noteminimal_response=true');
+  
expect(controller.get('realUrl')).to.equal('/api/v1/clusters//configurations/service_config_versions?parametersfields=service_config_version,user,group_id,group_name,is_current,createtime,service_name,service_config_version_noteminimal_response=true');
 });
 it('cluster name is mycluster', function () {
   App.set('clusterName', 'mycluster');
-  
expect(controller.get('realUrl')).to.equal('/api/v1/clusters/mycluster/configurations/serviceconfigversions?parametersfields=serviceconfigversion,user,group_id,group_name,createtime,service_name,service_config_version_noteminimal_response=true');
+  
expect(controller.get('realUrl')).to.equal('/api/v1/clusters/mycluster/configurations/service_config_versions?parametersfields=service_config_version,user,group_id,group_name,is_current,createtime,service_name,service_config_version_noteminimal_response=true');
 });
   });
   describe('#load()', function () {
 it('', function () {
   sinon.stub(controller, 'updateTotalCounter', Em.K);
-  sinon.stub(controller, 'loadCurrentVersions', function(){
-return {complete: Em.K};
-  });
 
   controller.load();
   expect(controller.updateTotalCounter.calledOnce).to.be.true;
-  expect(controller.loadCurrentVersions.calledOnce).to.be.true;
 
   controller.updateTotalCounter.restore();
-  controller.loadCurrentVersions.restore();
 });
   });
   describe('#loadConfigVersionsToModel()', function () {
@@ -69,16 +64,7 @@ describe('MainConfigHistoryController', function () {
   App.HttpClient.get.restore();
 });
   });
-  describe('#loadCurrentVersions()', function () {
-it('', function () {
-  sinon.stub(App.ajax, 'send', Em.K);
 
-  controller.loadCurrentVersions();
-  expect(App.ajax.send.calledOnce).to.be.true;
-
-  App.ajax.send.restore();
-});
-  });
   describe('#updateTotalCounter()', function () {
 it('', 

git commit: AMBARI-7058. Improve logging on Ubuntu on package install failure. (aonishuk)

2014-08-28 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 6b7e796ab - 1b017b7cd


AMBARI-7058. Improve logging on Ubuntu on package install failure. (aonishuk)


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

Branch: refs/heads/trunk
Commit: 1b017b7cd4b4f8fbd89beaf7b1adf8bf9eaac3a2
Parents: 6b7e796
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Thu Aug 28 18:05:09 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Thu Aug 28 18:05:09 2014 +0300

--
 .../python/resource_management/TestPackageResource.py|  6 +++---
 .../resource_management/core/providers/package/apt.py| 11 ---
 2 files changed, 11 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/1b017b7c/ambari-agent/src/test/python/resource_management/TestPackageResource.py
--
diff --git 
a/ambari-agent/src/test/python/resource_management/TestPackageResource.py 
b/ambari-agent/src/test/python/resource_management/TestPackageResource.py
index d36c543..1628322 100644
--- a/ambari-agent/src/test/python/resource_management/TestPackageResource.py
+++ b/ambari-agent/src/test/python/resource_management/TestPackageResource.py
@@ -36,11 +36,11 @@ class TestPackageResource(TestCase):
   )
 call_mock.assert_has_calls([call(dpkg --get-selections some_package | 
grep -v deinstall),
 call(DEBIAN_FRONTEND=noninteractive 
/usr/bin/apt-get -q -o Dpkg::Options::='--force-confdef'
-   --allow-unauthenticated --assume-yes 
install some_package)
+   --allow-unauthenticated --assume-yes 
install some_package),
+call(apt-get update -qq)
   ])
 
-shell_mock.assert_has_calls([call(apt-get update -qq),
-call(DEBIAN_FRONTEND=noninteractive 
/usr/bin/apt-get -q -o Dpkg::Options::='--force-confdef' 
--allow-unauthenticated --assume-yes install some_package)
+shell_mock.assert_has_calls([call(DEBIAN_FRONTEND=noninteractive 
/usr/bin/apt-get -q -o Dpkg::Options::='--force-confdef' 
--allow-unauthenticated --assume-yes install some_package)
   ])
   
   @patch.object(shell, call)

http://git-wip-us.apache.org/repos/asf/ambari/blob/1b017b7c/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
 
b/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
index 4c6e2dd..f001f14 100644
--- 
a/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
+++ 
b/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
@@ -33,12 +33,17 @@ class AptProvider(PackageProvider):
 if not self._check_existence(name):
   cmd = INSTALL_CMD % (name)
   Logger.info(Installing package %s ('%s') % (name, cmd))
-  code = shell.call(cmd)[0]
+  code, out = shell.call(cmd)
   
   # apt-get update wasn't done too long
   if code:
-Logger.info(Failed to install package %s. Executing `apt-get update` 
% (name))
-shell.checked_call(REPO_UPDATE_CMD)
+Logger.info(Execution of '%s' returned %d. %s % (cmd, code, out))
+Logger.info(Failed to install package %s. Executing `%s` % (name, 
REPO_UPDATE_CMD))
+code, out = shell.call(REPO_UPDATE_CMD)
+
+if code:
+  Logger.info(Execution of '%s' returned %d. %s % (REPO_UPDATE_CMD, 
code, out))
+  
 Logger.info(Retrying to install package %s % (name))
 shell.checked_call(cmd)
 else:



git commit: AMBARI-7056. Need for a separate config file that comprises of cluster specific properties (aonishuk)

2014-08-28 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 1b017b7cd - 6bd0394a5


AMBARI-7056. Need for a separate config file that comprises of cluster specific 
properties (aonishuk)


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

Branch: refs/heads/trunk
Commit: 6bd0394a5f2254da2421f066473f680dc32772a1
Parents: 1b017b7
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Thu Aug 28 18:05:43 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Thu Aug 28 18:05:43 2014 +0300

--
 .../ambari/server/api/query/QueryImpl.java  |   1 -
 .../resources/ResourceInstanceFactoryImpl.java  |   4 +
 ...ackLevelConfigurationResourceDefinition.java |  53 ++
 .../StackVersionResourceDefinition.java |   1 +
 .../server/api/services/AmbariMetaInfo.java |  34 +++-
 .../server/api/services/StacksService.java  |  35 +++-
 .../server/api/util/StackExtensionHelper.java   | 105 ---
 .../controller/AmbariManagementController.java  |   8 +
 .../AmbariManagementControllerImpl.java |  44 +
 .../StackLevelConfigurationRequest.java |  42 +
 .../StackLevelConfigurationResponse.java|  37 
 .../server/controller/StackVersionResponse.java |  14 +-
 .../AbstractControllerResourceProvider.java |   2 +
 ...StackLevelConfigurationResourceProvider.java | 159 
 .../internal/StackVersionResourceProvider.java  |   6 +
 .../ambari/server/controller/spi/Resource.java  |   4 +-
 .../apache/ambari/server/state/ServiceInfo.java |   1 +
 .../apache/ambari/server/state/StackInfo.java   |  26 ++-
 .../src/main/resources/key_properties.json  |   5 +
 .../src/main/resources/properties.json  |  11 ++
 .../HDP/1.3.2/configuration/cluster-env.xml |  49 +
 .../HDP/2.0.6/configuration/cluster-env.xml |  49 +
 .../ambari/server/api/query/QueryImplTest.java  |   2 +-
 .../api/util/StackExtensionHelperTest.java  |  23 +--
 .../internal/AbstractResourceProviderTest.java  |  45 +
 ...kLevelConfigurationResourceProviderTest.java | 181 +++
 26 files changed, 892 insertions(+), 49 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6bd0394a/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java 
b/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
index 261559a..6dfdb49 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
@@ -895,7 +895,6 @@ public class QueryImpl implements Query, ResourceInstance {
 mapTemporalInfo.put(propertyId, globalTemporalInfo);
   }
 }
-
 return PropertyHelper.getReadRequest(setProperties, requestInfoProperties, 
mapTemporalInfo);
   }
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/6bd0394a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
index 13fff1d..f85c0ea 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
@@ -141,6 +141,10 @@ public class ResourceInstanceFactoryImpl implements 
ResourceInstanceFactory {
   case StackVersion:
 resourceDefinition = new StackVersionResourceDefinition();
 break;
+
+  case StackLevelConfiguration:
+resourceDefinition = new StackLevelConfigurationResourceDefinition();
+break;
 
   case StackService:
 resourceDefinition = new StackServiceResourceDefinition();

http://git-wip-us.apache.org/repos/asf/ambari/blob/6bd0394a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/StackLevelConfigurationResourceDefinition.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/StackLevelConfigurationResourceDefinition.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/api/resources/StackLevelConfigurationResourceDefinition.java
new file mode 100644
index 

git commit: AMBARI-7059. FE: Adding Sqoop service right after install doesnt auto-select Client. (Max Shepel via akovalenko)

2014-08-28 Thread akovalenko
Repository: ambari
Updated Branches:
  refs/heads/trunk 6bd0394a5 - f2f5dff25


AMBARI-7059. FE: Adding Sqoop service right after install doesnt auto-select 
Client. (Max Shepel via akovalenko)


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

Branch: refs/heads/trunk
Commit: f2f5dff25143545c6ab542ab0d62c7fc61ea418a
Parents: 6bd0394
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Thu Aug 28 18:09:43 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Thu Aug 28 18:09:43 2014 +0300

--
 .../controllers/main/service/add_controller.js  | 24 +++-
 .../app/controllers/wizard/step8_controller.js  | 12 ++
 ambari-web/app/routes/add_host_routes.js|  2 ++
 ambari-web/app/routes/add_service_routes.js |  2 ++
 ambari-web/app/routes/installer.js  |  2 ++
 .../main/service/add_controller_test.js | 10 
 6 files changed, 36 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f2f5dff2/ambari-web/app/controllers/main/service/add_controller.js
--
diff --git a/ambari-web/app/controllers/main/service/add_controller.js 
b/ambari-web/app/controllers/main/service/add_controller.js
index 52bd41b..cce1f5f 100644
--- a/ambari-web/app/controllers/main/service/add_controller.js
+++ b/ambari-web/app/controllers/main/service/add_controller.js
@@ -391,18 +391,20 @@ App.AddServiceController = App.WizardController.extend({
*/
   installAdditionalClients: function () {
 this.get('content.additionalClients').forEach(function (c) {
-  var queryStr = 'HostRoles/component_name='+ c.componentName + 
'HostRoles/host_name.in(' + c.hostNames.join() + ')';
-  App.ajax.send({
-name: 'common.host_component.update',
-sender: this,
-data: {
-  query: queryStr,
-  context: 'Install ' + App.format.role(c.componentName),
-  HostRoles: {
-state: 'INSTALLED'
+  if (c.hostNames.length  0) {
+var queryStr = 'HostRoles/component_name='+ c.componentName + 
'HostRoles/host_name.in(' + c.hostNames.join() + ')';
+App.ajax.send({
+  name: 'common.host_component.update',
+  sender: this,
+  data: {
+query: queryStr,
+context: 'Install ' + App.format.role(c.componentName),
+HostRoles: {
+  state: 'INSTALLED'
+}
   }
-}
-  });
+});
+  }
 }, this);
   }
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/f2f5dff2/ambari-web/app/controllers/wizard/step8_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step8_controller.js 
b/ambari-web/app/controllers/wizard/step8_controller.js
index 7eef55e..4396432 100644
--- a/ambari-web/app/controllers/wizard/step8_controller.js
+++ b/ambari-web/app/controllers/wizard/step8_controller.js
@@ -1285,11 +1285,13 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
   }, this);
 }, this);
 hostNames = hostNames.uniq();
-this.get('content.additionalClients').pushObject({hostNames: 
hostNames, componentName: _clientName});
-// If a dependency for being co-hosted is derived between existing 
client and selected new master but that
-// dependency is already satisfied in the cluster then disregard the 
derived dependency
-this.removeClientsFromList(_clientName, hostNames);
-this.registerHostsToComponent(hostNames, _clientName);
+if (hostNames.length  0) {
+  this.get('content.additionalClients').pushObject({hostNames: 
hostNames, componentName: _clientName});
+  // If a dependency for being co-hosted is derived between existing 
client and selected new master but that
+  // dependency is already satisfied in the cluster then disregard the 
derived dependency
+  this.removeClientsFromList(_clientName, hostNames);
+  this.registerHostsToComponent(hostNames, _clientName);
+}
   }
 }, this);
   },

http://git-wip-us.apache.org/repos/asf/ambari/blob/f2f5dff2/ambari-web/app/routes/add_host_routes.js
--
diff --git a/ambari-web/app/routes/add_host_routes.js 
b/ambari-web/app/routes/add_host_routes.js
index e4ae41f..ff281a9 100644
--- a/ambari-web/app/routes/add_host_routes.js
+++ b/ambari-web/app/routes/add_host_routes.js
@@ -154,11 +154,13 @@ module.exports = 

[1/2] git commit: AMBARI-7060. Ambari Falcon config setup issue - localhost must be replaced with the falcon host. (Max Shepel via onechiporenko)

2014-08-28 Thread onechiporenko
Repository: ambari
Updated Branches:
  refs/heads/trunk f2f5dff25 - c4f1e16a7


AMBARI-7060. Ambari Falcon config setup issue - localhost must be replaced with 
the falcon host. (Max Shepel via onechiporenko)


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

Branch: refs/heads/trunk
Commit: 9f6b7b3867bcf6fe6a07404c84846250a56924eb
Parents: 6b7e796
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 19:01:34 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 19:01:34 2014 +0300

--
 ambari-web/app/models/service_config.js | 4 
 1 file changed, 4 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/9f6b7b38/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 2df2ad7..8326dd4 100644
--- a/ambari-web/app/models/service_config.js
+++ b/ambari-web/app/models/service_config.js
@@ -501,6 +501,10 @@ App.ServiceConfigProperty = Ember.Object.extend({
   case 'storm.local.dir':
 this.unionAllMountPoints(isOnlyFirstOneNeeded, localDB);
 break;
+  case '*.broker.url':
+var falconServerHost = 
masterComponentHostsInDB.findProperty('component', 'FALCON_SERVER').hostName;
+this.setDefaultValue('localhost', falconServerHost);
+break;
 }
   },
 



[2/2] git commit: Merge remote-tracking branch 'origin/trunk' into origin-trunk

2014-08-28 Thread onechiporenko
Merge remote-tracking branch 'origin/trunk' into origin-trunk


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

Branch: refs/heads/trunk
Commit: c4f1e16a74f6afb1d5b9fb12f7257ad2bb554edb
Parents: 9f6b7b3 f2f5dff
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 19:05:02 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 19:05:02 2014 +0300

--
 .../resource_management/TestPackageResource.py  |   6 +-
 .../core/providers/package/apt.py   |  11 +-
 .../ambari/server/api/query/QueryImpl.java  |   1 -
 .../resources/ResourceInstanceFactoryImpl.java  |   4 +
 ...ackLevelConfigurationResourceDefinition.java |  53 ++
 .../StackVersionResourceDefinition.java |   1 +
 .../server/api/services/AmbariMetaInfo.java |  34 +++-
 .../server/api/services/StacksService.java  |  35 +++-
 .../server/api/util/StackExtensionHelper.java   | 105 ---
 .../controller/AmbariManagementController.java  |   8 +
 .../AmbariManagementControllerImpl.java |  44 +
 .../StackLevelConfigurationRequest.java |  42 +
 .../StackLevelConfigurationResponse.java|  37 
 .../server/controller/StackVersionResponse.java |  14 +-
 .../AbstractControllerResourceProvider.java |   2 +
 ...StackLevelConfigurationResourceProvider.java | 159 
 .../internal/StackVersionResourceProvider.java  |   6 +
 .../ambari/server/controller/spi/Resource.java  |   4 +-
 .../apache/ambari/server/state/ServiceInfo.java |   1 +
 .../apache/ambari/server/state/StackInfo.java   |  26 ++-
 .../src/main/resources/key_properties.json  |   5 +
 .../src/main/resources/properties.json  |  11 ++
 .../HDP/1.3.2/configuration/cluster-env.xml |  49 +
 .../HDP/2.0.6/configuration/cluster-env.xml |  49 +
 .../ambari/server/api/query/QueryImplTest.java  |   2 +-
 .../api/util/StackExtensionHelperTest.java  |  23 +--
 .../internal/AbstractResourceProviderTest.java  |  45 +
 ...kLevelConfigurationResourceProviderTest.java | 181 +++
 .../controllers/main/service/add_controller.js  |  24 +--
 .../app/controllers/wizard/step8_controller.js  |  12 +-
 ambari-web/app/routes/add_host_routes.js|   2 +
 ambari-web/app/routes/add_service_routes.js |   2 +
 ambari-web/app/routes/installer.js  |   2 +
 .../main/service/add_controller_test.js |  10 +
 34 files changed, 939 insertions(+), 71 deletions(-)
--




git commit: AMBARI-7061 Config History: View, Compare, and Make Current buttons should be disabled in certain cases. (atkach)

2014-08-28 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk c4f1e16a7 - 86d408397


AMBARI-7061 Config History: View, Compare, and Make Current buttons should be 
disabled in certain cases. (atkach)


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

Branch: refs/heads/trunk
Commit: 86d4083972567347c0092288e9a131d4e9a7e705
Parents: c4f1e16
Author: atkach atk...@hortonworks.com
Authored: Thu Aug 28 19:27:32 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Thu Aug 28 19:27:32 2014 +0300

--
 ambari-web/app/messages.js  |  3 +++
 ambari-web/app/models/service_config_version.js | 16 +++-
 ambari-web/app/styles/application.less  |  4 
 .../common/configs/config_history_flow.hbs  | 12 ++--
 4 files changed, 28 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 36bfa10..11c2015 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -2004,6 +2004,9 @@ Em.I18n.translations = {
   'dashboard.configHistory.info-bar.makeCurrent.popup.title': 'Make Current 
Confirmation',
   'dashboard.configHistory.info-bar.save.popup.placeholder': 'What did you 
change?',
   'dashboard.configHistory.info-bar.revert.button': 'Make current',
+  'dashboard.configHistory.info-bar.view.button.disabled': 'You are currently 
viewing this version.',
+  'dashboard.configHistory.info-bar.compare.button.disabled': 'You cannot 
compare against the same version.',
+  'dashboard.configHistory.info-bar.revert.button.disabled': 'This is the 
current version.',
 
 
   'timeRange.presets.1hour':'1h',

http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/models/service_config_version.js
--
diff --git a/ambari-web/app/models/service_config_version.js 
b/ambari-web/app/models/service_config_version.js
index 807d76f..93da4aa 100644
--- a/ambari-web/app/models/service_config_version.js
+++ b/ambari-web/app/models/service_config_version.js
@@ -56,7 +56,21 @@ App.ServiceConfigVersion = DS.Model.extend({
   isRequested: DS.attr('boolean'),
   isRestartRequired: function () {
 return this.get('service.isRestartRequired')  this.get('isCurrent');
-  }.property('service.isRestartRequired', 'isCurrent')
+  }.property('service.isRestartRequired', 'isCurrent'),
+  disabledActionMessages: function () {
+return {
+  view: (this.get('isDisplayed')) ? 
Em.I18n.t('dashboard.configHistory.info-bar.view.button.disabled') : '',
+  compare: (this.get('isDisplayed')) ? 
Em.I18n.t('dashboard.configHistory.info-bar.compare.button.disabled') : '',
+  revert: (this.get('isCurrent')) ? 
Em.I18n.t('dashboard.configHistory.info-bar.revert.button.disabled') : ''
+}
+  }.property('isDisplayed', 'isCurrent'),
+  disabledActionAttr: function () {
+return {
+  view: (this.get('isDisplayed')) ? 'disabled' : false,
+  compare: (this.get('isDisabled') || this.get('isDisplayed')) ? 
'disabled' : false,
+  revert: (this.get('isDisabled') || this.get('isCurrent')) ? 'disabled' : 
false
+}
+  }.property('isDisplayed', 'isCurrent', 'isDisabled')
 });
 
 App.ServiceConfigVersion.FIXTURES = [];

http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/styles/application.less
--
diff --git a/ambari-web/app/styles/application.less 
b/ambari-web/app/styles/application.less
index 0570220..a5843eb 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -6808,6 +6808,10 @@ i.icon-asterisks {
   border: 0;
 }
 
+.not-allowed-cursor {
+  cursor: not-allowed !important;
+}
+
 #flume-summary {
   text-align:left !important;
   max-height: 490px;

http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/templates/common/configs/config_history_flow.hbs
--
diff --git a/ambari-web/app/templates/common/configs/config_history_flow.hbs 
b/ambari-web/app/templates/common/configs/config_history_flow.hbs
index 55e622f..5dabe52 100644
--- a/ambari-web/app/templates/common/configs/config_history_flow.hbs
+++ b/ambari-web/app/templates/common/configs/config_history_flow.hbs
@@ -44,9 +44,9 @@
   div class=notes{{serviceVersion.briefNotes}}/div
 /div
 div
-  button class=btn 

git commit: AMBARI-7062. Client Config Download: log4j properties filenames should be the same as on an installed cluster host. (dlysnichenko)

2014-08-28 Thread dmitriusan
Repository: ambari
Updated Branches:
  refs/heads/trunk 86d408397 - d1bdc818e


AMBARI-7062. Client Config Download: log4j properties filenames should be the 
same as on an installed cluster host. (dlysnichenko)


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

Branch: refs/heads/trunk
Commit: d1bdc818e5d4c481d43955bcd7f4ece253b15eb5
Parents: 86d4083
Author: Lisnichenko Dmitro dlysniche...@hortonworks.com
Authored: Thu Aug 28 20:34:34 2014 +0300
Committer: Lisnichenko Dmitro dlysniche...@hortonworks.com
Committed: Thu Aug 28 20:34:34 2014 +0300

--
 .../python/resource_management/libraries/script/script.py |  9 ++---
 .../stacks/HDP/1.3.2/services/HBASE/metainfo.xml  |  2 +-
 .../resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml |  4 ++--
 .../stacks/HDP/1.3.2/services/MAPREDUCE/metainfo.xml  |  9 ++---
 .../resources/stacks/HDP/1.3.2/services/PIG/metainfo.xml  |  2 +-
 .../stacks/HDP/1.3.2/services/ZOOKEEPER/metainfo.xml  |  2 +-
 .../stacks/HDP/2.0.6/services/HBASE/metainfo.xml  |  2 +-
 .../resources/stacks/HDP/2.0.6/services/HDFS/metainfo.xml |  4 ++--
 .../resources/stacks/HDP/2.0.6/services/PIG/metainfo.xml  | 10 +-
 .../resources/stacks/HDP/2.0.6/services/YARN/metainfo.xml |  4 ++--
 .../stacks/HDP/2.0.6/services/ZOOKEEPER/metainfo.xml  |  2 +-
 .../resources/stacks/HDP/2.1/services/FALCON/metainfo.xml | 10 ++
 .../src/test/python/stacks/2.0.6/HDFS/test_hdfs_client.py |  4 
 .../src/test/python/stacks/2.0.6/configs/default.json |  2 +-
 14 files changed, 35 insertions(+), 31 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/d1bdc818/ambari-common/src/main/python/resource_management/libraries/script/script.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/script/script.py 
b/ambari-common/src/main/python/resource_management/libraries/script/script.py
index 7b7d931..80bfeab 100644
--- 
a/ambari-common/src/main/python/resource_management/libraries/script/script.py
+++ 
b/ambari-common/src/main/python/resource_management/libraries/script/script.py
@@ -258,10 +258,13 @@ class Script(object):
   
configuration_attributes=params.config['configuration_attributes'][dict],
 )
 for file_dict in env_configs_list:
-  for filename,dict in file_dict.iteritems():
+  for filename,dicts in file_dict.iteritems():
+content = ''
+for dict in dicts.split(','):
+  if dict.strip() in params.config['configurations']:
+content += params.config['configurations'][dict.strip()]['content']
 File(os.path.join(conf_tmp_dir, filename),
- 
content=InlineTemplate(params.config['configurations'][dict]['content'])
-)
+ content=InlineTemplate(content))
 with closing(tarfile.open(output_filename, w:gz)) as tar:
   tar.add(conf_tmp_dir, arcname=os.path.basename(.))
   tar.close()

http://git-wip-us.apache.org/repos/asf/ambari/blob/d1bdc818/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
index f209475..090bad8 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
@@ -108,7 +108,7 @@
 /configFile
 configFile
   typeenv/type
-  fileNamehbase-log4j.properties/fileName
+  fileNamelog4j.properties/fileName
   dictionaryNamehbase-log4j/dictionaryName
 /configFile
   /configFiles

http://git-wip-us.apache.org/repos/asf/ambari/blob/d1bdc818/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
index 7112c31..2aa0590 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
@@ -99,8 +99,8 @@
 /configFile  
 configFile
   typeenv/type
-  fileNamehdfs-log4j.properties/fileName
-

git commit: AMBARI-7029. Configs: ui and general.(xiwang)

2014-08-28 Thread xiwang
Repository: ambari
Updated Branches:
  refs/heads/trunk d1bdc818e - 869b00c61


AMBARI-7029. Configs: ui and general.(xiwang)


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

Branch: refs/heads/trunk
Commit: 869b00c61c86037e2514946f288b311b78dbcee8
Parents: d1bdc81
Author: Xi Wang xiw...@apache.org
Authored: Thu Aug 28 10:15:59 2014 -0700
Committer: Xi Wang xiw...@apache.org
Committed: Thu Aug 28 10:41:36 2014 -0700

--
 .../app/controllers/wizard/step8_controller.js| 18 +-
 ambari-web/app/messages.js|  8 ++--
 ambari-web/app/styles/application.less| 11 +++
 .../common/configs/config_history_flow.hbs|  8 +---
 .../views/common/configs/config_history_flow.js   |  3 +++
 5 files changed, 34 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/869b00c6/ambari-web/app/controllers/wizard/step8_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step8_controller.js 
b/ambari-web/app/controllers/wizard/step8_controller.js
index 4396432..2846e8c 100644
--- a/ambari-web/app/controllers/wizard/step8_controller.js
+++ b/ambari-web/app/controllers/wizard/step8_controller.js
@@ -839,7 +839,6 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
 var configurationController = 
App.router.get('mainServiceInfoConfigsController');
 var configs = this.get('configs').slice(0);
 var configsMap = [];
-
 fileNamesToUpdate.forEach(function (fileName) {
   if (!fileName || /^(core)/.test(fileName)) return;
   var tagName = 'version' + (new Date).getTime();
@@ -1434,17 +1433,25 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
 selectedServices.forEach(function (service) {
   Object.keys(service.get('configTypes')).forEach(function (type) {
 if (!this.get('serviceConfigTags').someProperty('type', type)) {
+  var serviceVersionNotes = 
Em.I18n.t('dashboard.configHistory.table.notes.default').format(service.get('serviceName'));
   if (!App.supports.capacitySchedulerUi  service.get('serviceName') 
=== 'MAPREDUCE'  (type === 'capacity-scheduler' || type === 
'mapred-queue-acls')) {
 return;
   } else if (type === 'core-site') {
+coreSiteObject.service_config_version_note = serviceVersionNotes
 this.get('serviceConfigTags').pushObject(coreSiteObject);
   } else if (type === 'storm-site') {
-
this.get('serviceConfigTags').pushObject(this.createStormSiteObj(tag));
+var obj = this.createStormSiteObj(tag);
+obj.service_config_version_note = serviceVersionNotes;
+this.get('serviceConfigTags').pushObject(obj);
   } else if (type === 'zoo.cfg') {
-
this.get('serviceConfigTags').pushObject(this.createZooCfgObj(tag));
+var obj = this.createZooCfgObj(tag);
+obj.service_config_version_note = serviceVersionNotes;
+this.get('serviceConfigTags').pushObject(obj);
   } else {
 var isNonXmlFile = type.endsWith('log4j') || type.endsWith('env') 
|| type.endsWith('properties') || type.endsWith('conf');
-this.get('serviceConfigTags').pushObject(this.createSiteObj(type, 
isNonXmlFile, tag));
+var obj = this.createSiteObj(type, isNonXmlFile, tag);
+obj.service_config_version_note = serviceVersionNotes;
+this.get('serviceConfigTags').pushObject(obj);
   }
 }
   }, this);
@@ -1465,7 +1472,8 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
 type: _serviceConfig.type,
 tag: _serviceConfig.tag,
 properties: _serviceConfig.properties,
-properties_attributes: _serviceConfig.properties_attributes
+properties_attributes: _serviceConfig.properties_attributes,
+service_config_version_note: 
_serviceConfig.service_config_version_note
   }
 }
   });

http://git-wip-us.apache.org/repos/asf/ambari/blob/869b00c6/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 11c2015..4c9abd9 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1409,7 +1409,9 @@ Em.I18n.translations = {
 'bambari-server setup --jdbc-db={0} 
--jdbc-driver=/path/to/{1}/driver.jar/b ' +
 'on the Ambari Server host to make the JDBC driver available and 

[18/45] git commit: Revert AMBARI-7043. BE: Move stack_advisor.py abstract class one folder up

2014-08-28 Thread jonathanhurley
Revert AMBARI-7043. BE: Move stack_advisor.py abstract class one folder up

This reverts commit 40e3f0fc5d34b4d96a95e0e568e8754b042dc6f5.


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

Branch: refs/heads/branch-alerts-dev
Commit: 4c5ed4c0cf7eb305fcdfbfd110476a015afbd5e1
Parents: debf29c
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 15:44:13 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 15:44:18 2014 -0700

--
 .../src/main/resources/scripts/stack_advisor.py |  2 +-
 .../main/resources/stacks/HDP/stack_advisor.py  | 37 
 .../src/main/resources/stacks/stack_advisor.py  | 37 
 .../server/api/services/AmbariMetaInfoTest.java |  4 +-
 .../AmbariManagementControllerTest.java |  2 +-
 .../src/test/python/TestStackAdvisor.py | 93 
 .../stacks/2.0.6/common/test_stack_advisor.py   |  2 +-
 .../stacks/XYZ/1.0.0/services/stack_advisor.py  | 67 --
 .../stacks/XYZ/1.0.1/services/stack_advisor.py  | 30 ---
 9 files changed, 41 insertions(+), 233 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/4c5ed4c0/ambari-server/src/main/resources/scripts/stack_advisor.py
--
diff --git a/ambari-server/src/main/resources/scripts/stack_advisor.py 
b/ambari-server/src/main/resources/scripts/stack_advisor.py
index ed50866..61d1e09 100755
--- a/ambari-server/src/main/resources/scripts/stack_advisor.py
+++ b/ambari-server/src/main/resources/scripts/stack_advisor.py
@@ -33,7 +33,7 @@ ALL_ACTIONS = [ RECOMMEND_COMPONENT_LAYOUT_ACTION, 
VALIDATE_COMPONENT_LAYOUT_ACT
 USAGE = Usage: action hosts_file services_file\nPossible actions are: 
{0}\n.format( str(ALL_ACTIONS) )
 
 SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
-STACK_ADVISOR_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, 
'../stacks/stack_advisor.py')
+STACK_ADVISOR_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, 
'../stacks/{0}/stack_advisor.py')
 STACK_ADVISOR_IMPL_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, 
'./../stacks/{0}/{1}/services/stack_advisor.py')
 STACK_ADVISOR_IMPL_CLASS_TEMPLATE = '{0}{1}StackAdvisor'
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/4c5ed4c0/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py
--
diff --git a/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py
new file mode 100644
index 000..5f66fff
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py
@@ -0,0 +1,37 @@
+#!/usr/bin/env 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.
+
+
+class StackAdvisor(object):
+
+  def recommendComponentLayout(self, services, hosts):
+Returns Services object with hostnames array populated for components
+pass
+
+  def validateComponentLayout(self, services, hosts):
+Returns array of Validation objects about issues with hostnames 
components assigned to
+pass
+
+  def recommendConfigurations(self, services, hosts):
+Returns Services object with configurations object populated
+pass
+
+  def validateConfigurations(self, services, hosts):
+Returns array of Validation objects about issues with configuration 
values provided in services
+pass
+

http://git-wip-us.apache.org/repos/asf/ambari/blob/4c5ed4c0/ambari-server/src/main/resources/stacks/stack_advisor.py
--
diff --git a/ambari-server/src/main/resources/stacks/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/stack_advisor.py
deleted file mode 100644
index 5f66fff..000
--- a/ambari-server/src/main/resources/stacks/stack_advisor.py
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/usr/bin/env ambari-python-wrap
-
-Licensed to the Apache Software 

[02/45] git commit: AMBARI-7036 restrict /#/experimental to only AMBARI.ADMIN (ababiichuk)

2014-08-28 Thread jonathanhurley
AMBARI-7036 restrict /#/experimental to only AMBARI.ADMIN (ababiichuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: c79fad2501a024379d409cb911e6ea72c8574ee5
Parents: 61695fa
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Wed Aug 27 16:03:39 2014 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Wed Aug 27 16:03:39 2014 +0300

--
 ambari-web/app/router.js | 12 
 1 file changed, 8 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/c79fad25/ambari-web/app/router.js
--
diff --git a/ambari-web/app/router.js b/ambari-web/app/router.js
index 04c6385..9e16359 100644
--- a/ambari-web/app/router.js
+++ b/ambari-web/app/router.js
@@ -441,12 +441,16 @@ App.Router = Em.Router.extend({
 experimental: Em.Route.extend({
   route: '/experimental',
   enter: function (router, context) {
-
+if (!App.get('isAdmin')) {
+  router.transitionTo(main);
+}
   },
   connectOutlets: function (router, context) {
-$('title').text(Ambari Experimental);
-console.log('/experimental:connectOutlet');
-router.get('applicationController').connectOutlet('experimental');
+if (App.get('isAdmin')) {
+  $('title').text(Ambari Experimental);
+  console.log('/experimental:connectOutlet');
+  router.get('applicationController').connectOutlet('experimental');
+}
   }
 }),
 



[24/45] git commit: AMBARI-7043. BE: Move stack_advisor.py abstract class one folder up - RPM and DEB package changes.

2014-08-28 Thread jonathanhurley
AMBARI-7043. BE: Move stack_advisor.py abstract class one folder up -
RPM and DEB package changes.


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

Branch: refs/heads/branch-alerts-dev
Commit: d87cf7f8d0fee68210296085954a7a1e6ce484c4
Parents: 39c7ae7
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Aug 27 10:56:25 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Aug 27 18:04:00 2014 -0700

--
 ambari-server/pom.xml   | 22 +
 .../src/main/resources/scripts/stack_advisor.py |  2 +-
 .../main/resources/stacks/HDP/stack_advisor.py  | 37 
 .../src/main/resources/stacks/stack_advisor.py  | 37 
 .../server/api/services/AmbariMetaInfoTest.java |  4 +-
 .../AmbariManagementControllerTest.java |  2 +-
 .../src/test/python/TestStackAdvisor.py | 93 
 .../stacks/2.0.6/common/test_stack_advisor.py   |  2 +-
 .../stacks/XYZ/1.0.0/services/stack_advisor.py  | 67 ++
 .../stacks/XYZ/1.0.1/services/stack_advisor.py  | 30 +++
 10 files changed, 255 insertions(+), 41 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/d87cf7f8/ambari-server/pom.xml
--
diff --git a/ambari-server/pom.xml b/ambari-server/pom.xml
index 2302c62..6279834 100644
--- a/ambari-server/pom.xml
+++ b/ambari-server/pom.xml
@@ -463,6 +463,17 @@
   /sources
 /mapping
 mapping
+  directory/var/lib/ambari-server/resources/stacks/directory
+  filemode755/filemode
+  usernameroot/username
+  groupnameroot/groupname
+  sources
+source
+  locationtarget/classes/stacks/stack_advisor.py/location
+/source
+  /sources
+/mapping
+mapping
   
directory/usr/lib/python2.6/site-packages/ambari_server/directory
   filemode755/filemode
   usernameroot/username
@@ -804,6 +815,17 @@
 /mapper
   /data
   data
+srctarget/classes/stacks/stack_advisor.py/src
+typefile/type
+mapper
+  typeperm/type
+  prefix/var/lib/ambari-server/resources/stacks/prefix
+  userroot/user
+  grouproot/group
+  filemode755/filemode
+/mapper
+  /data
+  data
 srcsrc/main/python/ambari_server/src
 typedirectory/type
 mapper

http://git-wip-us.apache.org/repos/asf/ambari/blob/d87cf7f8/ambari-server/src/main/resources/scripts/stack_advisor.py
--
diff --git a/ambari-server/src/main/resources/scripts/stack_advisor.py 
b/ambari-server/src/main/resources/scripts/stack_advisor.py
index 61d1e09..ed50866 100755
--- a/ambari-server/src/main/resources/scripts/stack_advisor.py
+++ b/ambari-server/src/main/resources/scripts/stack_advisor.py
@@ -33,7 +33,7 @@ ALL_ACTIONS = [ RECOMMEND_COMPONENT_LAYOUT_ACTION, 
VALIDATE_COMPONENT_LAYOUT_ACT
 USAGE = Usage: action hosts_file services_file\nPossible actions are: 
{0}\n.format( str(ALL_ACTIONS) )
 
 SCRIPT_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
-STACK_ADVISOR_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, 
'../stacks/{0}/stack_advisor.py')
+STACK_ADVISOR_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, 
'../stacks/stack_advisor.py')
 STACK_ADVISOR_IMPL_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, 
'./../stacks/{0}/{1}/services/stack_advisor.py')
 STACK_ADVISOR_IMPL_CLASS_TEMPLATE = '{0}{1}StackAdvisor'
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/d87cf7f8/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py
--
diff --git a/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py
deleted file mode 100644
index 5f66fff..000
--- a/ambari-server/src/main/resources/stacks/HDP/stack_advisor.py
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/usr/bin/env 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
-
-

[40/45] git commit: AMBARI-7060. Ambari Falcon config setup issue - localhost must be replaced with the falcon host. (Max Shepel via onechiporenko)

2014-08-28 Thread jonathanhurley
AMBARI-7060. Ambari Falcon config setup issue - localhost must be replaced with 
the falcon host. (Max Shepel via onechiporenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 9f6b7b3867bcf6fe6a07404c84846250a56924eb
Parents: 6b7e796
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 19:01:34 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 19:01:34 2014 +0300

--
 ambari-web/app/models/service_config.js | 4 
 1 file changed, 4 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/9f6b7b38/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 2df2ad7..8326dd4 100644
--- a/ambari-web/app/models/service_config.js
+++ b/ambari-web/app/models/service_config.js
@@ -501,6 +501,10 @@ App.ServiceConfigProperty = Ember.Object.extend({
   case 'storm.local.dir':
 this.unionAllMountPoints(isOnlyFirstOneNeeded, localDB);
 break;
+  case '*.broker.url':
+var falconServerHost = 
masterComponentHostsInDB.findProperty('component', 'FALCON_SERVER').hostName;
+this.setDefaultValue('localhost', falconServerHost);
+break;
 }
   },
 



[15/45] git commit: AMBARI-7048. Change component message from cannot to should not

2014-08-28 Thread jonathanhurley
AMBARI-7048. Change component message from cannot to should not


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

Branch: refs/heads/branch-alerts-dev
Commit: f23e09de6c9aad0523c3fa77e2eaf7bfda72a5cc
Parents: 966fff4
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Aug 27 14:38:06 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Aug 27 14:38:06 2014 -0700

--
 .../main/resources/stacks/HDP/1.3.2/services/stack_advisor.py| 4 ++--
 .../main/resources/stacks/HDP/2.0.6/services/stack_advisor.py| 4 ++--
 .../src/test/python/stacks/2.0.6/common/test_stack_advisor.py| 4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f23e09de/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
index f3c1e1d..17a26e2 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
@@ -192,8 +192,8 @@ class HDP132StackAdvisor(StackAdvisor):
   secondaryNameNodeHosts = secondaryNameNodeHosts[0]
   commonHosts = 
list(set(nameNodeHosts).intersection(secondaryNameNodeHosts))
   for host in commonHosts:
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
 
 # Validating cardinality
 for component in componentsList:

http://git-wip-us.apache.org/repos/asf/ambari/blob/f23e09de/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
index 083286e..4eb8f02 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
@@ -192,8 +192,8 @@ class HDP206StackAdvisor(StackAdvisor):
   secondaryNameNodeHosts = secondaryNameNodeHosts[0]
   commonHosts = 
list(set(nameNodeHosts).intersection(secondaryNameNodeHosts))
   for host in commonHosts:
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
 
 # Validating cardinality
 for component in componentsList:

http://git-wip-us.apache.org/repos/asf/ambari/blob/f23e09de/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
--
diff --git 
a/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py 
b/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
index 898797a..b1b9f7a 100644
--- a/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
+++ b/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
@@ -99,8 +99,8 @@ class TestHDP206StackAdvisor(TestCase):
 result = 

[28/45] git commit: AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster Dashboard, or Views Landing page). (yusaku)

2014-08-28 Thread jonathanhurley
AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster 
Dashboard, or Views Landing page). (yusaku)


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

Branch: refs/heads/branch-alerts-dev
Commit: e1634809f0c4c6a6acfe1b2672b4ddfcaf2d5e92
Parents: 2051c64
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 23:09:59 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 23:09:59 2014 -0700

--
 .../controllers/global/cluster_controller.js| 44 
 1 file changed, 44 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e1634809/ambari-web/app/controllers/global/cluster_controller.js
--
diff --git a/ambari-web/app/controllers/global/cluster_controller.js 
b/ambari-web/app/controllers/global/cluster_controller.js
index 246ad8b..bc09b0a 100644
--- a/ambari-web/app/controllers/global/cluster_controller.js
+++ b/ambari-web/app/controllers/global/cluster_controller.js
@@ -347,50 +347,6 @@ App.ClusterController = Em.Controller.extend({
 }, callback)
   },
 
-  loadAmbariViews: function () {
-App.ajax.send({
-  name: 'views.info',
-  sender: this,
-  success: 'loadAmbariViewsSuccess'
-});
-  },
-
-  loadAmbariViewsSuccess: function (data) {
-if (data.items.length) {
-  App.ajax.send({
-name: 'views.instances',
-sender: this,
-success: 'loadViewInstancesSuccess'
-  });
-} else {
-  this.set('ambariViews', []);
-}
-  },
-
-  loadViewInstancesSuccess: function (data) {
-this.set('ambariViews', []);
-var self = this;
-data.items.forEach(function (view) {
-  view.versions.forEach(function (version) {
-version.instances.forEach(function (instance) {
-  var current_instance = Em.Object.create({
-iconPath: instance.ViewInstanceInfo.icon_path || 
/img/ambari-view-default.png,
-label: instance.ViewInstanceInfo.label || 
version.ViewVersionInfo.label || instance.ViewInstanceInfo.view_name,
-visible: instance.ViewInstanceInfo.visible || false,
-version: instance.ViewInstanceInfo.version,
-description: instance.ViewInstanceInfo.description || 
Em.I18n.t('views.main.instance.noDescription'),
-viewName: instance.ViewInstanceInfo.view_name,
-instanceName: instance.ViewInstanceInfo.instance_name,
-href: instance.ViewInstanceInfo.context_path
-  });
-  if( current_instance.visible){
-self.get('ambariViews').pushObject(current_instance);
-  }
-}, this);
-  }, this);
-}, this);
-  },
-
   /**
*
* @param callback



[26/45] git commit: AMBARI-7031. FE: Next button not enabled when only /validation ERRORs are there. (ababiichuk via srimanth)

2014-08-28 Thread jonathanhurley
AMBARI-7031. FE: Next button not enabled when only /validation ERRORs are 
there. (ababiichuk via srimanth)


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

Branch: refs/heads/branch-alerts-dev
Commit: 94ca14a559ddd9eab59bc2db138dd2005dfffeec
Parents: fa10e3b
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Aug 27 14:14:53 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Aug 27 18:39:43 2014 -0700

--
 ambari-web/app/mixins/common/serverValidator.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/94ca14a5/ambari-web/app/mixins/common/serverValidator.js
--
diff --git a/ambari-web/app/mixins/common/serverValidator.js 
b/ambari-web/app/mixins/common/serverValidator.js
index 3a1dbed..71169c5 100644
--- a/ambari-web/app/mixins/common/serverValidator.js
+++ b/ambari-web/app/mixins/common/serverValidator.js
@@ -236,8 +236,8 @@ App.ServerValidatorMixin = Em.Mixin.create({
   if ((property.get('filename') == item['config-type'] + '.xml') 
 (property.get('name') == item['config-name'])) {
 if (item.level == ERROR) {
   self.set('configValidationError', true);
-  property.set('warnMessage', item.message);
-  property.set('warn', true);
+  property.set('errorMessage', item.message);
+  property.set('error', true);
 } else if (item.level == WARN) {
   self.set('configValidationWarning', true);
   property.set('warnMessage', item.message);



[16/45] git commit: AMBARI-7030. Config History: integrate the current label for each config group.(xiwang)

2014-08-28 Thread jonathanhurley
AMBARI-7030. Config History: integrate the current label for each config 
group.(xiwang)


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

Branch: refs/heads/branch-alerts-dev
Commit: f77e9e818614582d9fbcead4fa781076388b3358
Parents: f23e09d
Author: Xi Wang xiw...@apache.org
Authored: Wed Aug 27 15:01:51 2014 -0700
Committer: Xi Wang xiw...@apache.org
Committed: Wed Aug 27 15:05:57 2014 -0700

--
 .../main/dashboard/config_history_controller.js | 28 +++-
 .../controllers/main/service/info/configs.js| 15 ++-
 .../mappers/service_config_version_mapper.js|  3 +--
 ambari-web/app/utils/ajax/ajax.js   |  2 +-
 .../views/common/configs/config_history_flow.js | 13 ++---
 5 files changed, 24 insertions(+), 37 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f77e9e81/ambari-web/app/controllers/main/dashboard/config_history_controller.js
--
diff --git 
a/ambari-web/app/controllers/main/dashboard/config_history_controller.js 
b/ambari-web/app/controllers/main/dashboard/config_history_controller.js
index d8a4722..a747017 100644
--- a/ambari-web/app/controllers/main/dashboard/config_history_controller.js
+++ b/ambari-web/app/controllers/main/dashboard/config_history_controller.js
@@ -31,7 +31,7 @@ App.MainConfigHistoryController = 
Em.ArrayController.extend(App.TableServerMixin
   filteredCount: 0,
   mockUrl: '/data/configurations/service_versions.json',
   realUrl: function () {
-return App.apiPrefix + '/clusters/' + App.get('clusterName') + 
'/configurations/service_config_versions?parametersfields=service_config_version,user,group_id,group_name,createtime,service_name,service_config_version_noteminimal_response=true';
+return App.apiPrefix + '/clusters/' + App.get('clusterName') + 
'/configurations/service_config_versions?parametersfields=service_config_version,user,group_id,group_name,is_current,createtime,service_name,service_config_version_noteminimal_response=true';
   }.property('App.clusterName'),
 
   /**
@@ -154,13 +154,9 @@ App.MainConfigHistoryController = 
Em.ArrayController.extend(App.TableServerMixin
*/
   load: function () {
 var dfd = $.Deferred();
-var self = this;
-
 this.updateTotalCounter();
-this.loadCurrentVersions().complete(function () {
-  self.loadConfigVersionsToModel().done(function () {
-dfd.resolve();
-  });
+this.loadConfigVersionsToModel().done(function () {
+  dfd.resolve();
 });
 return dfd.promise();
   },
@@ -181,24 +177,6 @@ App.MainConfigHistoryController = 
Em.ArrayController.extend(App.TableServerMixin
 return dfd.promise();
   },
 
-  loadCurrentVersions: function () {
-return App.ajax.send({
-  name: 'service.serviceConfigVersions.get.current',
-  sender: this,
-  data: {},
-  success: 'loadCurrentVersionsSuccess'
-})
-  },
-
-  loadCurrentVersionsSuccess: function (data, opt, params) {
-var currentConfigVersions = {};
-
-for (var service in data.Clusters.desired_service_config_versions) {
-  currentConfigVersions[service + '_' + 
data.Clusters.desired_service_config_versions[service][0].service_config_version]
 = true;
-}
-App.cache['currentConfigVersions'] = currentConfigVersions;
-  },
-
   updateTotalCounter: function () {
 return App.ajax.send({
   name: 'service.serviceConfigVersions.get.total',

http://git-wip-us.apache.org/repos/asf/ambari/blob/f77e9e81/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 ab7afeb..78c9b53 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -288,21 +288,24 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
 
   /**
* load current service config version number
-   * set currentVersion
+   * set currentVersion (current version for default group)
* @param data
* @param opt
* @param params
*/
   loadCurrentVersionsSuccess: function (data, opt, params) {
-var currentConfigVersions = {};
 var self = this;
 for (var service in data.Clusters.desired_service_config_versions) {
-  currentConfigVersions[service + '_' + 
data.Clusters.desired_service_config_versions[service][0].service_config_version]
 = true;
   if (self.get('content.serviceName') == service) {
-self.set('currentVersion', 

[34/45] git commit: AMBARI-7055. Slider View: Metric names and quick-links should be human readable. (onechiporenko)

2014-08-28 Thread jonathanhurley
AMBARI-7055. Slider View: Metric names and quick-links should be human 
readable. (onechiporenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: ff27e56fe8a983c76c40951472575197117b5914
Parents: 0fb6e63
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 16:34:13 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 16:34:13 2014 +0300

--
 .../src/main/resources/ui/app/helpers/helper.js | 32 
 .../ui/app/mappers/slider_apps_mapper.js|  2 +-
 .../resources/ui/app/templates/slider_app.hbs   |  2 +-
 .../ui/app/templates/slider_app/summary.hbs |  2 +-
 4 files changed, 35 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
--
diff --git a/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js 
b/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
index 664328c..88dfcb7 100644
--- a/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
+++ b/contrib/views/slider/src/main/resources/ui/app/helpers/helper.js
@@ -68,4 +68,36 @@ App.registerBoundHelper('formatWordBreak', Em.View.extend({
 var r = new RegExp('\\'+d,g);
 return this.get('content')  this.get('content').replace(r, d+'wbr /');
   }.property('content')
+}));
+
+/**
+ * Return formatted string with inserted spaces before upper case and replaced 
'_' to spaces
+ * Also capitalize first letter
+ *
+ * @param {String} content
+ *
+ * Examples:
+ *
+ * returns 'apple'
+ * {{humanize 'Apple'}}
+ *
+ * returns 'apple_banana'
+ * {{humanize 'Apple banana'}}
+ *
+ * returns 'apple_bananaUranium'
+ * {{humanize 'Apple banana Uranium'}}
+ */
+App.registerBoundHelper('humanize', Em.View.extend({
+
+  tagName: 'span',
+
+  template: Ember.Handlebars.compile('{{{view.result}}}'),
+
+  /**
+   * @type {string}
+   */
+  result: function() {
+var content = this.get('content');
+return content  (content[0].toUpperCase() + 
content.slice(1)).replace(/([A-Z])/g, ' $1').replace(/_/g, ' ');
+  }.property('content')
 }));
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js 
b/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
index dbe62bf..e5bcb49 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/mappers/slider_apps_mapper.js
@@ -141,7 +141,7 @@ App.SliderAppsMapper = 
App.Mapper.createWithMixins(App.RunPeriodically, {
 masterActiveTime.value = new Date(Date.now() - 
masterActiveTime.value).getHours() + h: + new Date(Date.now() - 
masterActiveTime.value).getMinutes() + m;
   }
   if(masterStartTime){
-masterStartTime.value = (new 
Date(masterStartTime.value).toUTCString());
+masterStartTime.value = (new 
Date(parseInt(masterStartTime.value)).toUTCString());
   }
   apps.push(
 Ember.Object.create({

http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs 
b/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
index b8ab969..f435bdf 100644
--- a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
+++ b/contrib/views/slider/src/main/resources/ui/app/templates/slider_app.hbs
@@ -33,7 +33,7 @@
   ul class=dropdown-menu
 {{#each option in controller.availableActions}}
   li
-a {{action 'openModal' option 
target='controller'}}{{option.title}}/a
+a {{action 'openModal' option target='controller'}}{{humanize 
option.title}}/a
   /li
 {{/each}}
   /ul

http://git-wip-us.apache.org/repos/asf/ambari/blob/ff27e56f/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
 

[20/45] git commit: Revert AMBARI-7048. Change component message from cannot to should not

2014-08-28 Thread jonathanhurley
Revert AMBARI-7048. Change component message from cannot to should not

This reverts commit f23e09de6c9aad0523c3fa77e2eaf7bfda72a5cc.


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

Branch: refs/heads/branch-alerts-dev
Commit: fc626c99cf579a37b1e1c8aad4690ceffc02c1e2
Parents: 9dcb434
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 16:00:26 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 16:00:26 2014 -0700

--
 .../main/resources/stacks/HDP/1.3.2/services/stack_advisor.py| 4 ++--
 .../main/resources/stacks/HDP/2.0.6/services/stack_advisor.py| 4 ++--
 .../src/test/python/stacks/2.0.6/common/test_stack_advisor.py| 4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fc626c99/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
index 17a26e2..f3c1e1d 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/stack_advisor.py
@@ -192,8 +192,8 @@ class HDP132StackAdvisor(StackAdvisor):
   secondaryNameNodeHosts = secondaryNameNodeHosts[0]
   commonHosts = 
list(set(nameNodeHosts).intersection(secondaryNameNodeHosts))
   for host in commonHosts:
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
 
 # Validating cardinality
 for component in componentsList:

http://git-wip-us.apache.org/repos/asf/ambari/blob/fc626c99/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
index 4eb8f02..083286e 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
@@ -192,8 +192,8 @@ class HDP206StackAdvisor(StackAdvisor):
   secondaryNameNodeHosts = secondaryNameNodeHosts[0]
   commonHosts = 
list(set(nameNodeHosts).intersection(secondaryNameNodeHosts))
   for host in commonHosts:
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
-items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode should not be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'NAMENODE', host: str(host) } )
+items.append( { type: 'host-component', level: 'WARN', message: 
'NameNode and Secondary NameNode cannot be hosted on same machine', 
component-name: 'SECONDARY_NAMENODE', host: str(host) } )
 
 # Validating cardinality
 for component in componentsList:

http://git-wip-us.apache.org/repos/asf/ambari/blob/fc626c99/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
--
diff --git 
a/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py 
b/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
index 71e329b..b8e0d58 100644
--- a/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
+++ b/ambari-server/src/test/python/stacks/2.0.6/common/test_stack_advisor.py
@@ -99,8 +99,8 

[01/45] git commit: AMBARI-7035. Views: Jobs view support for existing ATS. (akovalenko)

2014-08-28 Thread jonathanhurley
Repository: ambari
Updated Branches:
  refs/heads/branch-alerts-dev 76fc94ec1 - 52d1af763


AMBARI-7035. Views: Jobs view support for existing ATS. (akovalenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 61695fa43735b12a08b15af9504210ac6c9a0bf2
Parents: a826334
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Wed Aug 27 15:55:38 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Wed Aug 27 15:55:38 2014 +0300

--
 .../src/main/resources/ui/app/scripts/app.js|  2 +-
 .../app/scripts/controllers/job_controller.js   |  2 +-
 .../app/scripts/controllers/jobs_controller.js  | 14 ++--
 .../resources/ui/app/scripts/helpers/ajax.js| 17 +++--
 .../resources/ui/app/scripts/helpers/jobs.js| 78 +---
 .../mappers/application_status_mapper.js| 47 
 contrib/views/jobs/src/main/resources/view.xml  | 10 +++
 7 files changed, 111 insertions(+), 59 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/61695fa4/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
--
diff --git a/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
index 3ab2c30..2ae6d20 100644
--- a/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
+++ b/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
@@ -55,7 +55,7 @@ App.initializer({
 
 });
 
-application.ApplicationStatusMapper.getClusterName();
+application.ApplicationStatusMapper.getInstanceParameters();
 
   }
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/61695fa4/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/job_controller.js
--
diff --git 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/job_controller.js
 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/job_controller.js
index f1125d9..dbf3a4f 100644
--- 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/job_controller.js
+++ 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/job_controller.js
@@ -71,7 +71,7 @@ App.JobController = 
Ember.ObjectController.extend(App.RunPeriodically, {
   timeout = this.get('loadTimeout'),
   yarnService = App.HiveJob.store.getById('service', 'YARN'),
   content = this.get('content');
-if (!Em.isNone(yarnService)) {
+if (!Em.isNone(yarnService) || App.get('atsURL')) {
   if (!Em.isNone(content)) {
 App.Helpers.jobs.refreshJobDetails(
   content,

http://git-wip-us.apache.org/repos/asf/ambari/blob/61695fa4/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/jobs_controller.js
--
diff --git 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/jobs_controller.js
 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/jobs_controller.js
index d96f598..16acb56 100644
--- 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/jobs_controller.js
+++ 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/controllers/jobs_controller.js
@@ -557,11 +557,11 @@ App.JobsController = 
Ember.ArrayController.extend(App.RunPeriodically, {
*/
   checkDataLoadingError: function (jqXHR) {
 var atsComponent = App.HiveJob.store.getById('component', 
'APP_TIMELINE_SERVER');
-if (atsComponent  atsComponent.get('workStatus') != STARTED) {
+if (!App.get('atsURL')  atsComponent  atsComponent.get('workStatus') 
!= STARTED) {
   this.set('jobsMessage', Em.I18n.t('jobs.error.ats.down'));
 }
 else {
-  if (jqXHR  jqXHR.status == 400) {
+  if (jqXHR  (jqXHR.status == 400 || jqXHR.status == 404)) {
 this.set('jobsMessage', Em.I18n.t('jobs.error.400'));
   }
   else {
@@ -584,15 +584,14 @@ App.JobsController = 
Ember.ArrayController.extend(App.RunPeriodically, {
   atsComponent = App.HiveJob.store.getById('component', 
'APP_TIMELINE_SERVER'),
   atsInValidState = !!atsComponent  atsComponent.get('workStatus') === 
STARTED;
 this.checkDataLoadingError();
-if (!Em.isNone(yarnService)  atsInValidState) {
+if (App.get('atsURL') || (!Em.isNone(yarnService)  atsInValidState)) {
   this.set('loading', true);
-  var historyServerHostName = atsComponent.get('hostName');
+  var atsURL = App.get('atsURL') || 'http://' + 
atsComponent.get('hostName') + ':' + 

[42/45] git commit: AMBARI-7061 Config History: View, Compare, and Make Current buttons should be disabled in certain cases. (atkach)

2014-08-28 Thread jonathanhurley
AMBARI-7061 Config History: View, Compare, and Make Current buttons should be 
disabled in certain cases. (atkach)


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

Branch: refs/heads/branch-alerts-dev
Commit: 86d4083972567347c0092288e9a131d4e9a7e705
Parents: c4f1e16
Author: atkach atk...@hortonworks.com
Authored: Thu Aug 28 19:27:32 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Thu Aug 28 19:27:32 2014 +0300

--
 ambari-web/app/messages.js  |  3 +++
 ambari-web/app/models/service_config_version.js | 16 +++-
 ambari-web/app/styles/application.less  |  4 
 .../common/configs/config_history_flow.hbs  | 12 ++--
 4 files changed, 28 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 36bfa10..11c2015 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -2004,6 +2004,9 @@ Em.I18n.translations = {
   'dashboard.configHistory.info-bar.makeCurrent.popup.title': 'Make Current 
Confirmation',
   'dashboard.configHistory.info-bar.save.popup.placeholder': 'What did you 
change?',
   'dashboard.configHistory.info-bar.revert.button': 'Make current',
+  'dashboard.configHistory.info-bar.view.button.disabled': 'You are currently 
viewing this version.',
+  'dashboard.configHistory.info-bar.compare.button.disabled': 'You cannot 
compare against the same version.',
+  'dashboard.configHistory.info-bar.revert.button.disabled': 'This is the 
current version.',
 
 
   'timeRange.presets.1hour':'1h',

http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/models/service_config_version.js
--
diff --git a/ambari-web/app/models/service_config_version.js 
b/ambari-web/app/models/service_config_version.js
index 807d76f..93da4aa 100644
--- a/ambari-web/app/models/service_config_version.js
+++ b/ambari-web/app/models/service_config_version.js
@@ -56,7 +56,21 @@ App.ServiceConfigVersion = DS.Model.extend({
   isRequested: DS.attr('boolean'),
   isRestartRequired: function () {
 return this.get('service.isRestartRequired')  this.get('isCurrent');
-  }.property('service.isRestartRequired', 'isCurrent')
+  }.property('service.isRestartRequired', 'isCurrent'),
+  disabledActionMessages: function () {
+return {
+  view: (this.get('isDisplayed')) ? 
Em.I18n.t('dashboard.configHistory.info-bar.view.button.disabled') : '',
+  compare: (this.get('isDisplayed')) ? 
Em.I18n.t('dashboard.configHistory.info-bar.compare.button.disabled') : '',
+  revert: (this.get('isCurrent')) ? 
Em.I18n.t('dashboard.configHistory.info-bar.revert.button.disabled') : ''
+}
+  }.property('isDisplayed', 'isCurrent'),
+  disabledActionAttr: function () {
+return {
+  view: (this.get('isDisplayed')) ? 'disabled' : false,
+  compare: (this.get('isDisabled') || this.get('isDisplayed')) ? 
'disabled' : false,
+  revert: (this.get('isDisabled') || this.get('isCurrent')) ? 'disabled' : 
false
+}
+  }.property('isDisplayed', 'isCurrent', 'isDisabled')
 });
 
 App.ServiceConfigVersion.FIXTURES = [];

http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/styles/application.less
--
diff --git a/ambari-web/app/styles/application.less 
b/ambari-web/app/styles/application.less
index 0570220..a5843eb 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -6808,6 +6808,10 @@ i.icon-asterisks {
   border: 0;
 }
 
+.not-allowed-cursor {
+  cursor: not-allowed !important;
+}
+
 #flume-summary {
   text-align:left !important;
   max-height: 490px;

http://git-wip-us.apache.org/repos/asf/ambari/blob/86d40839/ambari-web/app/templates/common/configs/config_history_flow.hbs
--
diff --git a/ambari-web/app/templates/common/configs/config_history_flow.hbs 
b/ambari-web/app/templates/common/configs/config_history_flow.hbs
index 55e622f..5dabe52 100644
--- a/ambari-web/app/templates/common/configs/config_history_flow.hbs
+++ b/ambari-web/app/templates/common/configs/config_history_flow.hbs
@@ -44,9 +44,9 @@
   div class=notes{{serviceVersion.briefNotes}}/div
 /div
 div
-  button class=btn {{action switchVersion serviceVersion 
target=view}}i 

[13/45] git commit: AMBARI-7047. BE: Config validation type of values less than recommended should be WARNs

2014-08-28 Thread jonathanhurley
AMBARI-7047. BE: Config validation type of values less than recommended should 
be WARNs


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

Branch: refs/heads/branch-alerts-dev
Commit: e007d7f4fac0bbef2e753e7004e368a0f6329212
Parents: 40e3f0f
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Aug 27 13:51:39 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Aug 27 13:51:39 2014 -0700

--
 .../stacks/HDP/2.0.6/services/stack_advisor.py  | 56 +++-
 .../stacks/2.0.6/common/test_stack_advisor.py   | 36 ++---
 2 files changed, 60 insertions(+), 32 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e007d7f4/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
index ad0dcc0..083286e 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
@@ -415,58 +415,66 @@ class HDP206StackAdvisor(StackAdvisor):
   YARN: [yarn-site, self.validateYARNConfigurations]
 }.get(serviceName, None)
 
-  def toConfigurationValidationErrors(self, items, siteName):
+  def toConfigurationValidationProblems(self, validationProblems, siteName):
 result = []
-for item in items:
-  if item[message] is not None:
-error = { type: 'configuration', level: 'ERROR', message: 
item[message], config-type: siteName, config-name: item[config-name] }
-result.append(error)
+for validationProblem in validationProblems:
+  validationItem = validationProblem.get(item, None)
+  if validationItem is not None:
+problem = { type: 'configuration', level: validationItem[level], 
message: validationItem[message],
+  config-type: siteName, config-name: 
validationProblem[config-name] }
+result.append(problem)
 return result
 
+  def getWarnItem(self, message):
+return {level: WARN, message: message}
+
+  def getErrorItem(self, message):
+return {level: ERROR, message: message}
+
   def validatorLessThenDefaultValue(self, properties, recommendedDefaults, 
propertyName):
 if not propertyName in properties:
-  return Value should be set
+  return self.getErrorItem(Value should be set)
 value = to_number(properties[propertyName])
 if value is None:
-  return Value should be integer
+  return self.getErrorItem(Value should be integer)
 defaultValue = to_number(recommendedDefaults[propertyName])
 if defaultValue is None:
   return None
 if value  defaultValue:
-  return Value is less than the recommended default of 
{0}.format(defaultValue)
+  return self.getWarnItem(Value is less than the recommended default of 
{0}.format(defaultValue))
 return None
 
   def validateXmxValue(self, properties, recommendedDefaults, propertyName):
 if not propertyName in properties:
-  return Value should be set
+  return self.getErrorItem(Value should be set)
 value = properties[propertyName]
 defaultValue = recommendedDefaults[propertyName]
 if defaultValue is None:
-  return Config's default value can't be null or undefined
+  return self.getErrorItem(Config's default value can't be null or 
undefined)
 if not checkXmxValueFormat(value):
-  return 'Invalid value format'
+  return self.getErrorItem('Invalid value format')
 valueInt = formatXmxSizeToBytes(getXmxSize(value))
 defaultValueXmx = getXmxSize(defaultValue)
 defaultValueInt = formatXmxSizeToBytes(defaultValueXmx)
 if valueInt  defaultValueInt:
-  return Value is less than the recommended default of -Xmx + 
defaultValueXmx
+  return self.getWarnItem(Value is less than the recommended default of 
-Xmx + defaultValueXmx)
 return None
 
   def validateMapReduce2Configurations(self, properties, recommendedDefaults):
-validationItems = [ {config-name: 'mapreduce.map.java.opts', message: 
self.validateXmxValue(properties, recommendedDefaults, 
'mapreduce.map.java.opts')},
-{config-name: 'mapreduce.reduce.java.opts', 
message: self.validateXmxValue(properties, recommendedDefaults, 
'mapreduce.reduce.java.opts')},
-{config-name: 'mapreduce.task.io.sort.mb', 
message: self.validatorLessThenDefaultValue(properties, recommendedDefaults, 
'mapreduce.task.io.sort.mb')},
- 

[22/45] git commit: Revert AMBARI-7047. BE: Config validation type of values less than recommended should be WARNs

2014-08-28 Thread jonathanhurley
Revert AMBARI-7047. BE: Config validation type of values less than recommended 
should be WARNs

This reverts commit e007d7f4fac0bbef2e753e7004e368a0f6329212.


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

Branch: refs/heads/branch-alerts-dev
Commit: 51215cc36e680b6b0cb1ae318901c7ed78930134
Parents: fdb54a1
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 16:03:09 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 16:03:09 2014 -0700

--
 .../stacks/HDP/2.0.6/services/stack_advisor.py  | 56 +---
 .../stacks/2.0.6/common/test_stack_advisor.py   | 36 +++--
 2 files changed, 32 insertions(+), 60 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/51215cc3/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
index 083286e..ad0dcc0 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
@@ -415,66 +415,58 @@ class HDP206StackAdvisor(StackAdvisor):
   YARN: [yarn-site, self.validateYARNConfigurations]
 }.get(serviceName, None)
 
-  def toConfigurationValidationProblems(self, validationProblems, siteName):
+  def toConfigurationValidationErrors(self, items, siteName):
 result = []
-for validationProblem in validationProblems:
-  validationItem = validationProblem.get(item, None)
-  if validationItem is not None:
-problem = { type: 'configuration', level: validationItem[level], 
message: validationItem[message],
-  config-type: siteName, config-name: 
validationProblem[config-name] }
-result.append(problem)
+for item in items:
+  if item[message] is not None:
+error = { type: 'configuration', level: 'ERROR', message: 
item[message], config-type: siteName, config-name: item[config-name] }
+result.append(error)
 return result
 
-  def getWarnItem(self, message):
-return {level: WARN, message: message}
-
-  def getErrorItem(self, message):
-return {level: ERROR, message: message}
-
   def validatorLessThenDefaultValue(self, properties, recommendedDefaults, 
propertyName):
 if not propertyName in properties:
-  return self.getErrorItem(Value should be set)
+  return Value should be set
 value = to_number(properties[propertyName])
 if value is None:
-  return self.getErrorItem(Value should be integer)
+  return Value should be integer
 defaultValue = to_number(recommendedDefaults[propertyName])
 if defaultValue is None:
   return None
 if value  defaultValue:
-  return self.getWarnItem(Value is less than the recommended default of 
{0}.format(defaultValue))
+  return Value is less than the recommended default of 
{0}.format(defaultValue)
 return None
 
   def validateXmxValue(self, properties, recommendedDefaults, propertyName):
 if not propertyName in properties:
-  return self.getErrorItem(Value should be set)
+  return Value should be set
 value = properties[propertyName]
 defaultValue = recommendedDefaults[propertyName]
 if defaultValue is None:
-  return self.getErrorItem(Config's default value can't be null or 
undefined)
+  return Config's default value can't be null or undefined
 if not checkXmxValueFormat(value):
-  return self.getErrorItem('Invalid value format')
+  return 'Invalid value format'
 valueInt = formatXmxSizeToBytes(getXmxSize(value))
 defaultValueXmx = getXmxSize(defaultValue)
 defaultValueInt = formatXmxSizeToBytes(defaultValueXmx)
 if valueInt  defaultValueInt:
-  return self.getWarnItem(Value is less than the recommended default of 
-Xmx + defaultValueXmx)
+  return Value is less than the recommended default of -Xmx + 
defaultValueXmx
 return None
 
   def validateMapReduce2Configurations(self, properties, recommendedDefaults):
-validationItems = [ {config-name: 'mapreduce.map.java.opts', item: 
self.validateXmxValue(properties, recommendedDefaults, 
'mapreduce.map.java.opts')},
-{config-name: 'mapreduce.reduce.java.opts', item: 
self.validateXmxValue(properties, recommendedDefaults, 
'mapreduce.reduce.java.opts')},
-{config-name: 'mapreduce.task.io.sort.mb', item: 
self.validatorLessThenDefaultValue(properties, 

[35/45] git commit: AMBARI-7046. Missing metainfo.xml - displayName in 2.1.GlusterFS stack(Scott Creeley via subin)

2014-08-28 Thread jonathanhurley
AMBARI-7046. Missing metainfo.xml - displayName in 2.1.GlusterFS stack(Scott 
Creeley via subin)


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

Branch: refs/heads/branch-alerts-dev
Commit: fb8367080acd88d311ced9de903bbb1ba9452254
Parents: ff27e56
Author: Subin su...@apache.org
Authored: Thu Aug 28 13:33:48 2014 +
Committer: Subin su...@apache.org
Committed: Thu Aug 28 13:36:24 2014 +

--
 .../services/FALCON/configuration/global.xml|  63 ---
 .../2.1.GlusterFS/services/FALCON/metainfo.xml  |  19 ++-
 .../GLUSTERFS/configuration/core-site.xml   | 169 ---
 .../services/GLUSTERFS/configuration/global.xml |  59 ---
 .../services/GLUSTERFS/metainfo.xml |   1 +
 .../services/STORM/configuration/global.xml |  39 -
 .../2.1.GlusterFS/services/STORM/metainfo.xml   |   1 +
 .../services/TEZ/configuration/global.xml   |  29 
 .../HDP/2.1.GlusterFS/services/TEZ/metainfo.xml |  22 ++-
 ambari-web/app/models/stack_service.js  |   4 +-
 10 files changed, 41 insertions(+), 365 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fb836708/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
deleted file mode 100644
index fadc02d..000
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/configuration/global.xml
+++ /dev/null
@@ -1,63 +0,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 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.
- */
---
-configuration supports_final=false
-  property
-namefalcon_user/name
-valuefalcon/value
-descriptionFalcon user./description
-  /property
-  property
-namefalcon_port/name
-value15000/value
-descriptionPort the Falcon Server listens on./description
-  /property
-  property
-namefalcon_log_dir/name
-value/var/log/falcon/value
-descriptionFalcon log directory./description
-  /property
-  property
-namefalcon_pid_dir/name
-value/var/run/falcon/value
-descriptionFalcon pid-file directory./description
-  /property
-  property
-namefalcon_local_dir/name
-value/hadoop/falcon/value
-descriptionDirectory where Falcon data, such as activemq data, is 
stored./description
-  /property
-  !--embeddedmq properties--
-  property
-namefalcon.embeddedmq.data/name
-value/hadoop/falcon/embeddedmq/data/value
-descriptionDirectory in which embeddedmq data is stored./description
-  /property
-  property
-namefalcon.embeddedmq/name
-valuetrue/value
-descriptionWhether embeddedmq is enabled or not./description
-  /property
-  property
-namefalcon.emeddedmq.port/name
-value61616/value
-descriptionPort that embeddedmq will listen on./description
-  /property
-/configuration

http://git-wip-us.apache.org/repos/asf/ambari/blob/fb836708/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
index f66d99f..2e444b1 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/FALCON/metainfo.xml
@@ -20,21 +20,31 @@
   services
 service
   nameFALCON/name
+  displayNameFalcon/displayName
   commentData management and processing platform/comment

[21/45] git commit: Revert AMBARI-7031. FE: Next button not enabled when only /validation ERRORs are there. (ababiichuk via srimanth)

2014-08-28 Thread jonathanhurley
Revert AMBARI-7031. FE: Next button not enabled when only /validation ERRORs 
are there. (ababiichuk via srimanth)

This reverts commit 966fff415353beff39a4c4cc72ae38b5974ffaa5.


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

Branch: refs/heads/branch-alerts-dev
Commit: fdb54a10f7f22dac46e3fcd4aaa6deba0c262916
Parents: fc626c9
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 16:00:38 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 16:00:38 2014 -0700

--
 ambari-web/app/mixins/common/serverValidator.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fdb54a10/ambari-web/app/mixins/common/serverValidator.js
--
diff --git a/ambari-web/app/mixins/common/serverValidator.js 
b/ambari-web/app/mixins/common/serverValidator.js
index 71169c5..3a1dbed 100644
--- a/ambari-web/app/mixins/common/serverValidator.js
+++ b/ambari-web/app/mixins/common/serverValidator.js
@@ -236,8 +236,8 @@ App.ServerValidatorMixin = Em.Mixin.create({
   if ((property.get('filename') == item['config-type'] + '.xml') 
 (property.get('name') == item['config-name'])) {
 if (item.level == ERROR) {
   self.set('configValidationError', true);
-  property.set('errorMessage', item.message);
-  property.set('error', true);
+  property.set('warnMessage', item.message);
+  property.set('warn', true);
 } else if (item.level == WARN) {
   self.set('configValidationWarning', true);
   property.set('warnMessage', item.message);



[45/45] git commit: Merge branch 'trunk' into branch-alerts-dev

2014-08-28 Thread jonathanhurley
Merge branch 'trunk' into branch-alerts-dev


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

Branch: refs/heads/branch-alerts-dev
Commit: 52d1af7634e4a13ea4f9b94e34a1734c2bcd416c
Parents: 76fc94e 869b00c
Author: Jonathan Hurley jhur...@hortonworks.com
Authored: Thu Aug 28 13:49:15 2014 -0400
Committer: Jonathan Hurley jhur...@hortonworks.com
Committed: Thu Aug 28 13:49:15 2014 -0400

--
 .../resource_management/TestPackageResource.py  |   6 +-
 .../core/providers/package/apt.py   |  11 +-
 .../libraries/script/script.py  |   9 +-
 ambari-server/pom.xml   |  22 ++
 .../ambari/server/api/query/QueryImpl.java  |   1 -
 .../resources/ResourceInstanceFactoryImpl.java  |   4 +
 ...ackLevelConfigurationResourceDefinition.java |  53 +++
 .../StackVersionResourceDefinition.java |   1 +
 .../server/api/services/AmbariMetaInfo.java |  34 +-
 .../server/api/services/StacksService.java  |  35 +-
 .../server/api/util/StackExtensionHelper.java   | 105 --
 .../controller/AmbariManagementController.java  |   8 +
 .../AmbariManagementControllerImpl.java |  44 +++
 .../StackLevelConfigurationRequest.java |  42 +++
 .../StackLevelConfigurationResponse.java|  37 +++
 .../server/controller/StackVersionResponse.java |  14 +-
 .../AbstractControllerResourceProvider.java |   2 +
 ...StackLevelConfigurationResourceProvider.java | 159 +
 .../internal/StackVersionResourceProvider.java  |   6 +
 .../ambari/server/controller/spi/Resource.java  |   4 +-
 .../apache/ambari/server/state/ServiceInfo.java |   1 +
 .../apache/ambari/server/state/StackInfo.java   |  26 +-
 .../ambari/server/view/ViewContextImpl.java |   9 +
 .../apache/ambari/server/view/ViewRegistry.java |  30 +-
 .../main/resources/custom_actions/check_host.py |   2 +-
 .../src/main/resources/key_properties.json  |   5 +
 .../src/main/resources/properties.json  |  11 +
 .../src/main/resources/scripts/stack_advisor.py |   2 +-
 .../HDP/1.3.2/configuration/cluster-env.xml |  49 +++
 .../1.3.2/hooks/before-START/scripts/params.py  |   4 +-
 .../HDP/1.3.2/services/HBASE/metainfo.xml   |   2 +-
 .../stacks/HDP/1.3.2/services/HDFS/metainfo.xml |   4 +-
 .../HIVE/package/scripts/hive_service.py|   2 +-
 .../HDP/1.3.2/services/MAPREDUCE/metainfo.xml   |   9 +-
 .../OOZIE/package/scripts/oozie_service.py  |   2 +-
 .../stacks/HDP/1.3.2/services/PIG/metainfo.xml  |   2 +-
 .../HDP/1.3.2/services/ZOOKEEPER/metainfo.xml   |   2 +-
 .../stacks/HDP/1.3.2/services/stack_advisor.py  |   4 +-
 .../HDP/2.0.6/configuration/cluster-env.xml |  49 +++
 .../HDP/2.0.6/services/HBASE/metainfo.xml   |   2 +-
 .../stacks/HDP/2.0.6/services/HDFS/metainfo.xml |   4 +-
 .../HIVE/package/scripts/hive_service.py|   2 +-
 .../OOZIE/package/scripts/oozie_service.py  |   2 +-
 .../stacks/HDP/2.0.6/services/PIG/metainfo.xml  |  10 +-
 .../stacks/HDP/2.0.6/services/YARN/metainfo.xml |   4 +-
 .../HDP/2.0.6/services/ZOOKEEPER/metainfo.xml   |   2 +-
 .../stacks/HDP/2.0.6/services/stack_advisor.py  |  60 ++--
 .../services/FALCON/configuration/global.xml|  63 
 .../2.1.GlusterFS/services/FALCON/metainfo.xml  |  19 +-
 .../GLUSTERFS/configuration/core-site.xml   | 169 --
 .../services/GLUSTERFS/configuration/global.xml |  59 
 .../services/GLUSTERFS/metainfo.xml |   1 +
 .../services/STORM/configuration/global.xml |  39 ---
 .../2.1.GlusterFS/services/STORM/metainfo.xml   |   1 +
 .../services/TEZ/configuration/global.xml   |  29 --
 .../HDP/2.1.GlusterFS/services/TEZ/metainfo.xml |  22 +-
 .../stacks/HDP/2.1/services/FALCON/metainfo.xml |  10 +
 .../stacks/HDP/2.1/services/stack_advisor.py|  14 +-
 .../main/resources/stacks/HDP/stack_advisor.py  |  37 ---
 .../src/main/resources/stacks/stack_advisor.py  |  37 +++
 .../ambari/server/api/query/QueryImplTest.java  |   2 +-
 .../server/api/services/AmbariMetaInfoTest.java |   4 +-
 .../api/util/StackExtensionHelperTest.java  |  23 +-
 .../AmbariManagementControllerTest.java |   2 +-
 .../internal/AbstractResourceProviderTest.java  |  45 +++
 ...kLevelConfigurationResourceProviderTest.java | 181 +++
 .../ambari/server/view/ViewRegistryTest.java|  50 +++
 ambari-server/src/test/python/TestCheckHost.py  |   2 +-
 .../src/test/python/TestResourceFilesKeeper.py  |   2 +-
 .../src/test/python/TestStackAdvisor.py |  93 ++
 .../stacks/1.3.2/HIVE/test_hive_metastore.py|   4 +-
 .../stacks/1.3.2/HIVE/test_hive_server.py   |   4 +-
 .../hooks/before-START/test_before_start.py |   2 +-
 .../stacks/2.0.6/HDFS/test_hdfs_client.py   |   4 

[14/45] git commit: AMBARI-7031. FE: Next button not enabled when only /validation ERRORs are there. (ababiichuk via srimanth)

2014-08-28 Thread jonathanhurley
AMBARI-7031. FE: Next button not enabled when only /validation ERRORs are 
there. (ababiichuk via srimanth)


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

Branch: refs/heads/branch-alerts-dev
Commit: 966fff415353beff39a4c4cc72ae38b5974ffaa5
Parents: e007d7f
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Aug 27 14:14:53 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Aug 27 14:14:53 2014 -0700

--
 ambari-web/app/mixins/common/serverValidator.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/966fff41/ambari-web/app/mixins/common/serverValidator.js
--
diff --git a/ambari-web/app/mixins/common/serverValidator.js 
b/ambari-web/app/mixins/common/serverValidator.js
index 3a1dbed..71169c5 100644
--- a/ambari-web/app/mixins/common/serverValidator.js
+++ b/ambari-web/app/mixins/common/serverValidator.js
@@ -236,8 +236,8 @@ App.ServerValidatorMixin = Em.Mixin.create({
   if ((property.get('filename') == item['config-type'] + '.xml') 
 (property.get('name') == item['config-name'])) {
 if (item.level == ERROR) {
   self.set('configValidationError', true);
-  property.set('warnMessage', item.message);
-  property.set('warn', true);
+  property.set('errorMessage', item.message);
+  property.set('error', true);
 } else if (item.level == WARN) {
   self.set('configValidationWarning', true);
   property.set('warnMessage', item.message);



[11/45] git commit: AMBARI-7041. Select Services page: service dependencies should be derived from stack API. (jaimin)

2014-08-28 Thread jonathanhurley
AMBARI-7041. Select Services page: service dependencies should be derived from 
stack API. (jaimin)


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

Branch: refs/heads/branch-alerts-dev
Commit: f6ee0747c1fa2750f0eb5c6822d5023e489d8b91
Parents: b267bd8
Author: Jaimin Jetly jai...@hortonworks.com
Authored: Wed Aug 27 13:37:18 2014 -0700
Committer: Jaimin Jetly jai...@hortonworks.com
Committed: Wed Aug 27 13:37:18 2014 -0700

--
 .../app/controllers/wizard/step4_controller.js  | 35 +++-
 ambari-web/app/mappers/stack_service_mapper.js  |  1 +
 ambari-web/app/models/stack_service.js  | 44 +--
 .../test/controllers/wizard/step4_test.js   | 38 -
 ambari-web/test/service_components.js   | 58 +++-
 5 files changed, 115 insertions(+), 61 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f6ee0747/ambari-web/app/controllers/wizard/step4_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step4_controller.js 
b/ambari-web/app/controllers/wizard/step4_controller.js
index 22774d2..92dbed4 100644
--- a/ambari-web/app/controllers/wizard/step4_controller.js
+++ b/ambari-web/app/controllers/wizard/step4_controller.js
@@ -254,27 +254,34 @@ App.WizardStep4Controller = Em.ArrayController.extend({
* @method serviceDependencyValidation
*/
   serviceDependencyValidation: function() {
-var notSelectedServices = this.filterProperty('isSelected',false);
-notSelectedServices.forEach(function(service){
-  var showWarningPopup;
-  var dependentServices =  service.get('dependentServices');
+var selectedServices = this.filterProperty('isSelected',true);
+var missingDependencies = [];
+var missingDependenciesDisplayName = [];
+selectedServices.forEach(function(service){
+
+  var dependentServices =  service.get('requiredServices');
   if (!!dependentServices) {
-showWarningPopup = false;
 dependentServices.forEach(function(_dependentService){
   var dependentService = this.findProperty('serviceName', 
_dependentService);
-  if (dependentService  dependentService.get('isSelected') === true) 
{
-showWarningPopup = true;
+  if (dependentService  dependentService.get('isSelected') === 
false) {
+if(missingDependencies.indexOf(_dependentService) == -1 ) {
+  missingDependencies.push(_dependentService);
+  
missingDependenciesDisplayName.push(dependentService.get('displayNameOnSelectServicePage'));
+}
   }
 },this);
-if (showWarningPopup) {
-  this.addValidationError({
-id: 'serviceCheck_' + service.get('serviceName'),
-callback: this.needToAddServicePopup,
-callbackParams: [{serviceName: service.get('serviceName'), 
selected: true}, 'serviceCheck', service.get('displayNameOnSelectServicePage')]
-  });
-}
   }
 },this);
+
+if (missingDependencies.length  0) {
+  for(var i = 0; i  missingDependencies.length; i++) {
+this.addValidationError({
+  id: 'serviceCheck_' + missingDependencies[i],
+  callback: this.needToAddServicePopup,
+  callbackParams: [{serviceName: missingDependencies[i], selected: 
true}, 'serviceCheck', missingDependenciesDisplayName[i]]
+});
+  }
+}
   },
 
   /**

http://git-wip-us.apache.org/repos/asf/ambari/blob/f6ee0747/ambari-web/app/mappers/stack_service_mapper.js
--
diff --git a/ambari-web/app/mappers/stack_service_mapper.js 
b/ambari-web/app/mappers/stack_service_mapper.js
index 7609d9d..1f3d0c2 100644
--- a/ambari-web/app/mappers/stack_service_mapper.js
+++ b/ambari-web/app/mappers/stack_service_mapper.js
@@ -32,6 +32,7 @@ App.stackServiceMapper = App.QuickDataMapper.create({
 stack_version: 'stack_version',
 is_selected: 'is_selected',
 is_installed: 'is_installed',
+required_services: 'required_services',
 service_check_supported: 'service_check_supported',
 service_components_key: 'service_components',
 service_components_type: 'array',

http://git-wip-us.apache.org/repos/asf/ambari/blob/f6ee0747/ambari-web/app/models/stack_service.js
--
diff --git a/ambari-web/app/models/stack_service.js 
b/ambari-web/app/models/stack_service.js
index 7c69804..a711936 100644
--- a/ambari-web/app/models/stack_service.js
+++ b/ambari-web/app/models/stack_service.js

[30/45] git commit: AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster Dashboard, or Views Landing page). (yusaku)

2014-08-28 Thread jonathanhurley
AMBARI-6967. Admin View: default login behavior (route to Admin View, Cluster 
Dashboard, or Views Landing page). (yusaku)


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

Branch: refs/heads/branch-alerts-dev
Commit: cd0081c55f53f87076c191f21648f9f6477119e7
Parents: af67390
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Aug 27 23:59:35 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Aug 27 23:59:35 2014 -0700

--
 .../controllers/global/cluster_controller.js| 44 
 1 file changed, 44 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/cd0081c5/ambari-web/app/controllers/global/cluster_controller.js
--
diff --git a/ambari-web/app/controllers/global/cluster_controller.js 
b/ambari-web/app/controllers/global/cluster_controller.js
index 246ad8b..bc09b0a 100644
--- a/ambari-web/app/controllers/global/cluster_controller.js
+++ b/ambari-web/app/controllers/global/cluster_controller.js
@@ -347,50 +347,6 @@ App.ClusterController = Em.Controller.extend({
 }, callback)
   },
 
-  loadAmbariViews: function () {
-App.ajax.send({
-  name: 'views.info',
-  sender: this,
-  success: 'loadAmbariViewsSuccess'
-});
-  },
-
-  loadAmbariViewsSuccess: function (data) {
-if (data.items.length) {
-  App.ajax.send({
-name: 'views.instances',
-sender: this,
-success: 'loadViewInstancesSuccess'
-  });
-} else {
-  this.set('ambariViews', []);
-}
-  },
-
-  loadViewInstancesSuccess: function (data) {
-this.set('ambariViews', []);
-var self = this;
-data.items.forEach(function (view) {
-  view.versions.forEach(function (version) {
-version.instances.forEach(function (instance) {
-  var current_instance = Em.Object.create({
-iconPath: instance.ViewInstanceInfo.icon_path || 
/img/ambari-view-default.png,
-label: instance.ViewInstanceInfo.label || 
version.ViewVersionInfo.label || instance.ViewInstanceInfo.view_name,
-visible: instance.ViewInstanceInfo.visible || false,
-version: instance.ViewInstanceInfo.version,
-description: instance.ViewInstanceInfo.description || 
Em.I18n.t('views.main.instance.noDescription'),
-viewName: instance.ViewInstanceInfo.view_name,
-instanceName: instance.ViewInstanceInfo.instance_name,
-href: instance.ViewInstanceInfo.context_path
-  });
-  if( current_instance.visible){
-self.get('ambariViews').pushObject(current_instance);
-  }
-}, this);
-  }, this);
-}, this);
-  },
-
   /**
*
* @param callback



[41/45] git commit: Merge remote-tracking branch 'origin/trunk' into origin-trunk

2014-08-28 Thread jonathanhurley
Merge remote-tracking branch 'origin/trunk' into origin-trunk


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

Branch: refs/heads/branch-alerts-dev
Commit: c4f1e16a74f6afb1d5b9fb12f7257ad2bb554edb
Parents: 9f6b7b3 f2f5dff
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 19:05:02 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 19:05:02 2014 +0300

--
 .../resource_management/TestPackageResource.py  |   6 +-
 .../core/providers/package/apt.py   |  11 +-
 .../ambari/server/api/query/QueryImpl.java  |   1 -
 .../resources/ResourceInstanceFactoryImpl.java  |   4 +
 ...ackLevelConfigurationResourceDefinition.java |  53 ++
 .../StackVersionResourceDefinition.java |   1 +
 .../server/api/services/AmbariMetaInfo.java |  34 +++-
 .../server/api/services/StacksService.java  |  35 +++-
 .../server/api/util/StackExtensionHelper.java   | 105 ---
 .../controller/AmbariManagementController.java  |   8 +
 .../AmbariManagementControllerImpl.java |  44 +
 .../StackLevelConfigurationRequest.java |  42 +
 .../StackLevelConfigurationResponse.java|  37 
 .../server/controller/StackVersionResponse.java |  14 +-
 .../AbstractControllerResourceProvider.java |   2 +
 ...StackLevelConfigurationResourceProvider.java | 159 
 .../internal/StackVersionResourceProvider.java  |   6 +
 .../ambari/server/controller/spi/Resource.java  |   4 +-
 .../apache/ambari/server/state/ServiceInfo.java |   1 +
 .../apache/ambari/server/state/StackInfo.java   |  26 ++-
 .../src/main/resources/key_properties.json  |   5 +
 .../src/main/resources/properties.json  |  11 ++
 .../HDP/1.3.2/configuration/cluster-env.xml |  49 +
 .../HDP/2.0.6/configuration/cluster-env.xml |  49 +
 .../ambari/server/api/query/QueryImplTest.java  |   2 +-
 .../api/util/StackExtensionHelperTest.java  |  23 +--
 .../internal/AbstractResourceProviderTest.java  |  45 +
 ...kLevelConfigurationResourceProviderTest.java | 181 +++
 .../controllers/main/service/add_controller.js  |  24 +--
 .../app/controllers/wizard/step8_controller.js  |  12 +-
 ambari-web/app/routes/add_host_routes.js|   2 +
 ambari-web/app/routes/add_service_routes.js |   2 +
 ambari-web/app/routes/installer.js  |   2 +
 .../main/service/add_controller_test.js |  10 +
 34 files changed, 939 insertions(+), 71 deletions(-)
--




[19/45] git commit: AMBARI-7045. Slider View: When creating slider app, update Ganglia server host value (alexantonenko)

2014-08-28 Thread jonathanhurley
AMBARI-7045. Slider View: When creating slider app, update Ganglia server host 
value (alexantonenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 9dcb434eab370bafc3410e9fd80d8bef33008cb6
Parents: 4c5ed4c
Author: Alex Antonenko hiv...@gmail.com
Authored: Wed Aug 27 21:34:22 2014 +0300
Committer: Alex Antonenko hiv...@gmail.com
Committed: Thu Aug 28 01:49:20 2014 +0300

--
 .../createAppWizard/step1_controller.js | 30 
 .../createAppWizard/step3_controller.js |  9 --
 .../src/main/resources/ui/app/helpers/ajax.js   | 27 --
 .../src/main/resources/ui/app/initialize.js |  2 ++
 .../ui/app/mappers/application_status.js| 25 
 5 files changed, 89 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/9dcb434e/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step1_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step1_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step1_controller.js
index 9bfe68c..42c0080 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step1_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step1_controller.js
@@ -81,11 +81,41 @@ App.CreateAppWizardStep1Controller = 
Ember.Controller.extend({
* @method loadStep
*/
   loadStep: function () {
+this.loadGangliaHost();
 this.initializeNewApp();
 this.loadAvailableTypes();
   },
 
   /**
+   * Load ganglia server host
+   * @method loadGangliaHost
+   */
+  loadGangliaHost: function () {
+return App.ajax.send({
+  name: 'components_hosts',
+  sender: this,
+  data: {
+componentName: GANGLIA_SERVER,
+urlPrefix: '/api/v1/'
+  },
+  success: 'loadGangliaHostSuccessCallback'
+});
+
+  },
+
+  /**
+   * Success callback for hosts-request
+   * Save host name to gangliaHost
+   * @param {Object} data
+   * @method loadGangliaHostSuccessCallback
+   */
+  loadGangliaHostSuccessCallback: function (data) {
+if(data.items[0]){
+  App.set('gangliaHost', Em.get(data.items[0], 'Hosts.host_name'));
+}
+  },
+
+  /**
* Initialize new App and set it to codenewApp/code
* @method initializeNewApp
*/

http://git-wip-us.apache.org/repos/asf/ambari/blob/9dcb434e/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
index b98afb4..12dd699 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
@@ -65,19 +65,24 @@ App.CreateAppWizardStep3Controller = 
Ember.ObjectController.extend({
*/
   loadStep: function () {
 this.clearStep();
-this.initConfigs();
+this.initConfigs(true);
   },
 
   /**
* Format init value for codeconfigs/code property
+   * @param {bool} setDefaults
* @method initConfigs
*/
-  initConfigs: function() {
+  initConfigs: function(setDefaults) {
+setDefaults = setDefaults === true ? setDefaults : false;
 var configs = this.get('newAppConfigs') || {},
 c = Em.A();
 
 Object.keys(configs).forEach(function (key) {
   var label = (!!key.match('^site.'))?key.substr(5):key;
+  if(key === site.global.ganglia_server_host  setDefaults) {
+configs[key] = App.get('gangliaHost') ? App.get('gangliaHost') : 
configs[key];
+  }
   c.push({name:key,value:configs[key],label:label})
 });
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/9dcb434e/contrib/views/slider/src/main/resources/ui/app/helpers/ajax.js
--
diff --git a/contrib/views/slider/src/main/resources/ui/app/helpers/ajax.js 
b/contrib/views/slider/src/main/resources/ui/app/helpers/ajax.js
index 64c8385..255668f 100644
--- a/contrib/views/slider/src/main/resources/ui/app/helpers/ajax.js
+++ b/contrib/views/slider/src/main/resources/ui/app/helpers/ajax.js
@@ -104,6 +104,22 @@ var urls = {
 }
   },
 
+  'components_hosts': {
+   

[43/45] git commit: AMBARI-7062. Client Config Download: log4j properties filenames should be the same as on an installed cluster host. (dlysnichenko)

2014-08-28 Thread jonathanhurley
AMBARI-7062. Client Config Download: log4j properties filenames should be the 
same as on an installed cluster host. (dlysnichenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: d1bdc818e5d4c481d43955bcd7f4ece253b15eb5
Parents: 86d4083
Author: Lisnichenko Dmitro dlysniche...@hortonworks.com
Authored: Thu Aug 28 20:34:34 2014 +0300
Committer: Lisnichenko Dmitro dlysniche...@hortonworks.com
Committed: Thu Aug 28 20:34:34 2014 +0300

--
 .../python/resource_management/libraries/script/script.py |  9 ++---
 .../stacks/HDP/1.3.2/services/HBASE/metainfo.xml  |  2 +-
 .../resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml |  4 ++--
 .../stacks/HDP/1.3.2/services/MAPREDUCE/metainfo.xml  |  9 ++---
 .../resources/stacks/HDP/1.3.2/services/PIG/metainfo.xml  |  2 +-
 .../stacks/HDP/1.3.2/services/ZOOKEEPER/metainfo.xml  |  2 +-
 .../stacks/HDP/2.0.6/services/HBASE/metainfo.xml  |  2 +-
 .../resources/stacks/HDP/2.0.6/services/HDFS/metainfo.xml |  4 ++--
 .../resources/stacks/HDP/2.0.6/services/PIG/metainfo.xml  | 10 +-
 .../resources/stacks/HDP/2.0.6/services/YARN/metainfo.xml |  4 ++--
 .../stacks/HDP/2.0.6/services/ZOOKEEPER/metainfo.xml  |  2 +-
 .../resources/stacks/HDP/2.1/services/FALCON/metainfo.xml | 10 ++
 .../src/test/python/stacks/2.0.6/HDFS/test_hdfs_client.py |  4 
 .../src/test/python/stacks/2.0.6/configs/default.json |  2 +-
 14 files changed, 35 insertions(+), 31 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/d1bdc818/ambari-common/src/main/python/resource_management/libraries/script/script.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/script/script.py 
b/ambari-common/src/main/python/resource_management/libraries/script/script.py
index 7b7d931..80bfeab 100644
--- 
a/ambari-common/src/main/python/resource_management/libraries/script/script.py
+++ 
b/ambari-common/src/main/python/resource_management/libraries/script/script.py
@@ -258,10 +258,13 @@ class Script(object):
   
configuration_attributes=params.config['configuration_attributes'][dict],
 )
 for file_dict in env_configs_list:
-  for filename,dict in file_dict.iteritems():
+  for filename,dicts in file_dict.iteritems():
+content = ''
+for dict in dicts.split(','):
+  if dict.strip() in params.config['configurations']:
+content += params.config['configurations'][dict.strip()]['content']
 File(os.path.join(conf_tmp_dir, filename),
- 
content=InlineTemplate(params.config['configurations'][dict]['content'])
-)
+ content=InlineTemplate(content))
 with closing(tarfile.open(output_filename, w:gz)) as tar:
   tar.add(conf_tmp_dir, arcname=os.path.basename(.))
   tar.close()

http://git-wip-us.apache.org/repos/asf/ambari/blob/d1bdc818/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
index f209475..090bad8 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/metainfo.xml
@@ -108,7 +108,7 @@
 /configFile
 configFile
   typeenv/type
-  fileNamehbase-log4j.properties/fileName
+  fileNamelog4j.properties/fileName
   dictionaryNamehbase-log4j/dictionaryName
 /configFile
   /configFiles

http://git-wip-us.apache.org/repos/asf/ambari/blob/d1bdc818/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
index 7112c31..2aa0590 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/metainfo.xml
@@ -99,8 +99,8 @@
 /configFile  
 configFile
   typeenv/type
-  fileNamehdfs-log4j.properties/fileName
-  dictionaryNamehdfs-log4j/dictionaryName
+  

[44/45] git commit: AMBARI-7029. Configs: ui and general.(xiwang)

2014-08-28 Thread jonathanhurley
AMBARI-7029. Configs: ui and general.(xiwang)


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

Branch: refs/heads/branch-alerts-dev
Commit: 869b00c61c86037e2514946f288b311b78dbcee8
Parents: d1bdc81
Author: Xi Wang xiw...@apache.org
Authored: Thu Aug 28 10:15:59 2014 -0700
Committer: Xi Wang xiw...@apache.org
Committed: Thu Aug 28 10:41:36 2014 -0700

--
 .../app/controllers/wizard/step8_controller.js| 18 +-
 ambari-web/app/messages.js|  8 ++--
 ambari-web/app/styles/application.less| 11 +++
 .../common/configs/config_history_flow.hbs|  8 +---
 .../views/common/configs/config_history_flow.js   |  3 +++
 5 files changed, 34 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/869b00c6/ambari-web/app/controllers/wizard/step8_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step8_controller.js 
b/ambari-web/app/controllers/wizard/step8_controller.js
index 4396432..2846e8c 100644
--- a/ambari-web/app/controllers/wizard/step8_controller.js
+++ b/ambari-web/app/controllers/wizard/step8_controller.js
@@ -839,7 +839,6 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
 var configurationController = 
App.router.get('mainServiceInfoConfigsController');
 var configs = this.get('configs').slice(0);
 var configsMap = [];
-
 fileNamesToUpdate.forEach(function (fileName) {
   if (!fileName || /^(core)/.test(fileName)) return;
   var tagName = 'version' + (new Date).getTime();
@@ -1434,17 +1433,25 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
 selectedServices.forEach(function (service) {
   Object.keys(service.get('configTypes')).forEach(function (type) {
 if (!this.get('serviceConfigTags').someProperty('type', type)) {
+  var serviceVersionNotes = 
Em.I18n.t('dashboard.configHistory.table.notes.default').format(service.get('serviceName'));
   if (!App.supports.capacitySchedulerUi  service.get('serviceName') 
=== 'MAPREDUCE'  (type === 'capacity-scheduler' || type === 
'mapred-queue-acls')) {
 return;
   } else if (type === 'core-site') {
+coreSiteObject.service_config_version_note = serviceVersionNotes
 this.get('serviceConfigTags').pushObject(coreSiteObject);
   } else if (type === 'storm-site') {
-
this.get('serviceConfigTags').pushObject(this.createStormSiteObj(tag));
+var obj = this.createStormSiteObj(tag);
+obj.service_config_version_note = serviceVersionNotes;
+this.get('serviceConfigTags').pushObject(obj);
   } else if (type === 'zoo.cfg') {
-
this.get('serviceConfigTags').pushObject(this.createZooCfgObj(tag));
+var obj = this.createZooCfgObj(tag);
+obj.service_config_version_note = serviceVersionNotes;
+this.get('serviceConfigTags').pushObject(obj);
   } else {
 var isNonXmlFile = type.endsWith('log4j') || type.endsWith('env') 
|| type.endsWith('properties') || type.endsWith('conf');
-this.get('serviceConfigTags').pushObject(this.createSiteObj(type, 
isNonXmlFile, tag));
+var obj = this.createSiteObj(type, isNonXmlFile, tag);
+obj.service_config_version_note = serviceVersionNotes;
+this.get('serviceConfigTags').pushObject(obj);
   }
 }
   }, this);
@@ -1465,7 +1472,8 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
 type: _serviceConfig.type,
 tag: _serviceConfig.tag,
 properties: _serviceConfig.properties,
-properties_attributes: _serviceConfig.properties_attributes
+properties_attributes: _serviceConfig.properties_attributes,
+service_config_version_note: 
_serviceConfig.service_config_version_note
   }
 }
   });

http://git-wip-us.apache.org/repos/asf/ambari/blob/869b00c6/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 11c2015..4c9abd9 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1409,7 +1409,9 @@ Em.I18n.translations = {
 'bambari-server setup --jdbc-db={0} 
--jdbc-driver=/path/to/{1}/driver.jar/b ' +
 'on the Ambari Server host to make the JDBC driver available and to enable 
testing the database connection.',
 
-  

[03/45] git commit: AMBARI-7037. Slider View: Create Slider app wizard should show configs in sections (alexantonenko)

2014-08-28 Thread jonathanhurley
AMBARI-7037. Slider View: Create Slider app wizard should show configs in 
sections (alexantonenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: eb08925ca4290ad26e90a5f353d97f1aed298422
Parents: c79fad2
Author: Alex Antonenko hiv...@gmail.com
Authored: Wed Aug 27 17:39:02 2014 +0300
Committer: Alex Antonenko hiv...@gmail.com
Committed: Wed Aug 27 17:39:02 2014 +0300

--
 .../ui/app/components/configSection.js  | 48 
 .../createAppWizard/step3_controller.js | 45 ++
 .../src/main/resources/ui/app/helpers/helper.js |  5 +-
 .../app/templates/components/configSection.hbs  | 30 
 .../ui/app/templates/createAppWizard/step3.hbs  |  4 +-
 5 files changed, 122 insertions(+), 10 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/eb08925c/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/components/configSection.js 
b/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
new file mode 100644
index 000..7b2481d
--- /dev/null
+++ b/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
@@ -0,0 +1,48 @@
+/**
+ * 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.
+ */
+
+App.ConfigSectionComponent = Em.Component.extend({
+  layoutName:'components/configSection',
+  config:null,
+  section:'',
+
+  /**
+   * label for current section
+   * @return {String}
+   */
+  sectionLabel: function () {
+return this.get('section').classify();
+  }.property(),
+
+  /**
+   * Return True is section name equals 'general'
+   * @type {Boolean}
+   */
+  isGeneral:Ember.computed.equal('section', 'general'),
+
+  /**
+   * Filtered configs for current section
+   */
+  sectionConfigs: Ember.computed.filter('config', function(item) {
+if (this.get('isGeneral')) {
+  return !item.name.match('^site.');
+} else {
+  return !!item.name.match('^site.'+this.get('section')) ;
+}
+  })
+});

http://git-wip-us.apache.org/repos/asf/ambari/blob/eb08925c/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
index 2c34592..b98afb4 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/createAppWizard/step3_controller.js
@@ -22,11 +22,30 @@ App.CreateAppWizardStep3Controller = 
Ember.ObjectController.extend({
 
   appWizardController: Ember.computed.alias(controllers.createAppWizard),
 
+  newAppConfigs: Ember.computed.alias(appWizardController.newApp.configs),
+
   /**
-   * Configs entered in TextArea
-   * @type {String}
+   * Configs entered in TextFields
+   * @type Array
*/
-  configs: '',
+  configs: Em.A(),
+
+  /**
+   * Convert configs to array of uniq section names
+   * @return {Array}
+   */
+  sectionKeys:function () {
+var configs = this.get('newAppConfigs') || {},
+k = [general];
+
+Object.keys(configs).forEach(function (key) {
+  if (key.split('.')[0] == site) {
+k.push(key.split('.')[1])
+  }
+});
+
+return k.uniq();
+  }.property('newAppConfigs'),
 
   /**
* Defines if codeconfigs/code are properly key-value formatted
@@ -54,10 +73,16 @@ App.CreateAppWizardStep3Controller = 
Ember.ObjectController.extend({
* @method initConfigs
*/
   initConfigs: function() {
-var c = 

[06/45] git commit: AMBARI-7039. Incorrect displaying of Job Id in Job charts window. (Max Shepel via akovalenko)

2014-08-28 Thread jonathanhurley
AMBARI-7039. Incorrect displaying of Job Id in Job charts window. (Max Shepel 
via akovalenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 9385d47ab0f09e61e861f6d00a640c94488d385f
Parents: 940abdc
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Wed Aug 27 18:06:34 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Wed Aug 27 18:06:34 2014 +0300

--
 ambari-web/app/styles/apps.less | 6 ++
 1 file changed, 6 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/9385d47a/ambari-web/app/styles/apps.less
--
diff --git a/ambari-web/app/styles/apps.less b/ambari-web/app/styles/apps.less
index 8426380..9a42efc 100644
--- a/ambari-web/app/styles/apps.less
+++ b/ambari-web/app/styles/apps.less
@@ -391,6 +391,12 @@
 }
   }
 
+  #innerTable {
+td {
+  word-wrap: break-word;
+}
+  }
+
   #jobs-table {
 
 .is-not-link{



[38/45] git commit: AMBARI-7056. Need for a separate config file that comprises of cluster specific properties (aonishuk)

2014-08-28 Thread jonathanhurley
AMBARI-7056. Need for a separate config file that comprises of cluster specific 
properties (aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: 6bd0394a5f2254da2421f066473f680dc32772a1
Parents: 1b017b7
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Thu Aug 28 18:05:43 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Thu Aug 28 18:05:43 2014 +0300

--
 .../ambari/server/api/query/QueryImpl.java  |   1 -
 .../resources/ResourceInstanceFactoryImpl.java  |   4 +
 ...ackLevelConfigurationResourceDefinition.java |  53 ++
 .../StackVersionResourceDefinition.java |   1 +
 .../server/api/services/AmbariMetaInfo.java |  34 +++-
 .../server/api/services/StacksService.java  |  35 +++-
 .../server/api/util/StackExtensionHelper.java   | 105 ---
 .../controller/AmbariManagementController.java  |   8 +
 .../AmbariManagementControllerImpl.java |  44 +
 .../StackLevelConfigurationRequest.java |  42 +
 .../StackLevelConfigurationResponse.java|  37 
 .../server/controller/StackVersionResponse.java |  14 +-
 .../AbstractControllerResourceProvider.java |   2 +
 ...StackLevelConfigurationResourceProvider.java | 159 
 .../internal/StackVersionResourceProvider.java  |   6 +
 .../ambari/server/controller/spi/Resource.java  |   4 +-
 .../apache/ambari/server/state/ServiceInfo.java |   1 +
 .../apache/ambari/server/state/StackInfo.java   |  26 ++-
 .../src/main/resources/key_properties.json  |   5 +
 .../src/main/resources/properties.json  |  11 ++
 .../HDP/1.3.2/configuration/cluster-env.xml |  49 +
 .../HDP/2.0.6/configuration/cluster-env.xml |  49 +
 .../ambari/server/api/query/QueryImplTest.java  |   2 +-
 .../api/util/StackExtensionHelperTest.java  |  23 +--
 .../internal/AbstractResourceProviderTest.java  |  45 +
 ...kLevelConfigurationResourceProviderTest.java | 181 +++
 26 files changed, 892 insertions(+), 49 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6bd0394a/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java 
b/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
index 261559a..6dfdb49 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/api/query/QueryImpl.java
@@ -895,7 +895,6 @@ public class QueryImpl implements Query, ResourceInstance {
 mapTemporalInfo.put(propertyId, globalTemporalInfo);
   }
 }
-
 return PropertyHelper.getReadRequest(setProperties, requestInfoProperties, 
mapTemporalInfo);
   }
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/6bd0394a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
index 13fff1d..f85c0ea 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceInstanceFactoryImpl.java
@@ -141,6 +141,10 @@ public class ResourceInstanceFactoryImpl implements 
ResourceInstanceFactory {
   case StackVersion:
 resourceDefinition = new StackVersionResourceDefinition();
 break;
+
+  case StackLevelConfiguration:
+resourceDefinition = new StackLevelConfigurationResourceDefinition();
+break;
 
   case StackService:
 resourceDefinition = new StackServiceResourceDefinition();

http://git-wip-us.apache.org/repos/asf/ambari/blob/6bd0394a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/StackLevelConfigurationResourceDefinition.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/resources/StackLevelConfigurationResourceDefinition.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/api/resources/StackLevelConfigurationResourceDefinition.java
new file mode 100644
index 000..9265234
--- /dev/null
+++ 

[09/45] git commit: AMBARI-7042. When using JDBC URL with connection modifiers in Ambari Hive conf, it fails with java.lang.ArrayIndexOutOfBoundsException(vbrodetskyi)

2014-08-28 Thread jonathanhurley
AMBARI-7042. When using JDBC URL with connection modifiers in Ambari Hive conf, 
it fails with java.lang.ArrayIndexOutOfBoundsException(vbrodetskyi)


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

Branch: refs/heads/branch-alerts-dev
Commit: e20f15b61e2d29321537602a4fed24b19db48fdd
Parents: 8ca145b
Author: Vitaly Brodetskyi vbrodets...@hortonworks.com
Authored: Wed Aug 27 20:56:33 2014 +0300
Committer: Vitaly Brodetskyi vbrodets...@hortonworks.com
Committed: Wed Aug 27 20:56:33 2014 +0300

--
 ambari-server/src/main/resources/custom_actions/check_host.py| 2 +-
 .../HDP/1.3.2/services/HIVE/package/scripts/hive_service.py  | 2 +-
 .../HDP/1.3.2/services/OOZIE/package/scripts/oozie_service.py| 2 +-
 .../HDP/2.0.6/services/HIVE/package/scripts/hive_service.py  | 2 +-
 .../HDP/2.0.6/services/OOZIE/package/scripts/oozie_service.py| 2 +-
 ambari-server/src/test/python/TestCheckHost.py   | 2 +-
 ambari-server/src/test/python/TestResourceFilesKeeper.py | 2 +-
 .../src/test/python/stacks/1.3.2/HIVE/test_hive_metastore.py | 4 ++--
 .../src/test/python/stacks/1.3.2/HIVE/test_hive_server.py| 4 ++--
 .../src/test/python/stacks/2.0.6/HIVE/test_hive_metastore.py | 4 ++--
 .../src/test/python/stacks/2.0.6/HIVE/test_hive_server.py| 4 ++--
 .../src/test/python/stacks/2.1/HIVE/test_hive_metastore.py   | 4 ++--
 .../dummy_stack/HIVE/package/scripts/hive_service.py | 2 +-
 13 files changed, 18 insertions(+), 18 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e20f15b6/ambari-server/src/main/resources/custom_actions/check_host.py
--
diff --git a/ambari-server/src/main/resources/custom_actions/check_host.py 
b/ambari-server/src/main/resources/custom_actions/check_host.py
index 8e9b222..ddb1c59 100644
--- a/ambari-server/src/main/resources/custom_actions/check_host.py
+++ b/ambari-server/src/main/resources/custom_actions/check_host.py
@@ -201,7 +201,7 @@ class CheckHost(Script):
 # try to connect to db
   
 db_connection_check_command = format({java64_home}/bin/java -cp 
/usr/lib/ambari-agent/{check_db_connection_jar_name}: \
-   /usr/lib/ambari-agent/{jdbc_name} 
org.apache.ambari.server.DBConnectionVerification {db_connection_url}  \
+   /usr/lib/ambari-agent/{jdbc_name} 
org.apache.ambari.server.DBConnectionVerification '{db_connection_url}'  \
{user_name} {user_passwd!p} {jdbc_driver})
   
 process = subprocess.Popen(db_connection_check_command,

http://git-wip-us.apache.org/repos/asf/ambari/blob/e20f15b6/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/hive_service.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/hive_service.py
 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/hive_service.py
index 8a57b01..bea7c3d 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/hive_service.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/hive_service.py
@@ -53,7 +53,7 @@ def hive_service(
params.hive_jdbc_driver == oracle.jdbc.driver.OracleDriver:
   
   db_connection_check_command = format(
-{java64_home}/bin/java -cp 
{check_db_connection_jar}:/usr/share/java/{jdbc_jar_name} 
org.apache.ambari.server.DBConnectionVerification {hive_jdbc_connection_url} 
{hive_metastore_user_name} {hive_metastore_user_passwd!p} {hive_jdbc_driver})
+{java64_home}/bin/java -cp 
{check_db_connection_jar}:/usr/share/java/{jdbc_jar_name} 
org.apache.ambari.server.DBConnectionVerification '{hive_jdbc_connection_url}' 
{hive_metastore_user_name} {hive_metastore_user_passwd!p} {hive_jdbc_driver})
   
   Execute(db_connection_check_command,
   path='/usr/sbin:/sbin:/usr/local/bin:/bin:/usr/bin', tries=5, 
try_sleep=10)

http://git-wip-us.apache.org/repos/asf/ambari/blob/e20f15b6/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/OOZIE/package/scripts/oozie_service.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/OOZIE/package/scripts/oozie_service.py
 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/OOZIE/package/scripts/oozie_service.py
index 2be172b..f4cc283 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/OOZIE/package/scripts/oozie_service.py
+++ 

[07/45] git commit: AMBARI-7017. Jobs aren't displayed in Ambari UI (aonishuk)

2014-08-28 Thread jonathanhurley
AMBARI-7017. Jobs aren't displayed in Ambari UI (aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: af1db65118e91792b44eee882fc8eea0fef887a9
Parents: 9385d47
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Wed Aug 27 19:33:07 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Wed Aug 27 19:33:07 2014 +0300

--
 .../stacks/HDP/1.3.2/hooks/before-START/scripts/params.py| 4 ++--
 .../python/stacks/1.3.2/hooks/before-START/test_before_start.py  | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/af1db651/ambari-server/src/main/resources/stacks/HDP/1.3.2/hooks/before-START/scripts/params.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/hooks/before-START/scripts/params.py
 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/hooks/before-START/scripts/params.py
index 4e58939..97f32d5 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/hooks/before-START/scripts/params.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/hooks/before-START/scripts/params.py
@@ -93,8 +93,8 @@ ambari_db_rca_driver = 
config['hostLevelParams']['ambari_db_rca_driver']
 ambari_db_rca_username = config['hostLevelParams']['ambari_db_rca_username']
 ambari_db_rca_password = config['hostLevelParams']['ambari_db_rca_password']
 
-if 'rca_enabled' in config['configurations']['hadoop-env']:
-  rca_enabled =  config['configurations']['hadoop-env']['rca_enabled']
+if 'rca_enabled' in config['configurations']['mapred-env']:
+  rca_enabled =  config['configurations']['mapred-env']['rca_enabled']
 else:
   rca_enabled = False
 rca_disabled_prefix = ###

http://git-wip-us.apache.org/repos/asf/ambari/blob/af1db651/ambari-server/src/test/python/stacks/1.3.2/hooks/before-START/test_before_start.py
--
diff --git 
a/ambari-server/src/test/python/stacks/1.3.2/hooks/before-START/test_before_start.py
 
b/ambari-server/src/test/python/stacks/1.3.2/hooks/before-START/test_before_start.py
index 15d25a7..c559048 100644
--- 
a/ambari-server/src/test/python/stacks/1.3.2/hooks/before-START/test_before_start.py
+++ 
b/ambari-server/src/test/python/stacks/1.3.2/hooks/before-START/test_before_start.py
@@ -57,7 +57,7 @@ class TestHookBeforeStart(RMFTestCase):
   owner = 'hdfs',
   )
 self.assertResourceCalled('File', '/etc/hadoop/conf/log4j.properties',
-  content = 
'log4jproperties\nline2log4jproperties\nline2',
+  content = 
'log4jproperties\nline2log4jproperties\nline2\n\nlog4j.appender.JHA=org.apache.ambari.log4j.hadoop.mapreduce.jobhistory.JobHistoryAppender\nlog4j.appender.JHA.database=jdbc:postgresql://c6401.ambari.apache.org/ambarirca\nlog4j.appender.JHA.driver=org.postgresql.Driver\nlog4j.appender.JHA.user=mapred\nlog4j.appender.JHA.password=mapred\n\nlog4j.logger.org.apache.hadoop.mapred.JobHistory$JobHistoryLogger=DEBUG,JHA\nlog4j.additivity.org.apache.hadoop.mapred.JobHistory$JobHistoryLogger=true\n\n',
   owner = 'hdfs',
   group = 'hadoop',
   mode = 0644,



[17/45] git commit: AMBARI-7049. Remove the explicit logic of rendering specific configType category just for specific services. (jaimin)

2014-08-28 Thread jonathanhurley
AMBARI-7049. Remove the explicit logic of rendering specific configType 
category just for specific services. (jaimin)


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

Branch: refs/heads/branch-alerts-dev
Commit: debf29c23365c0826902f699a3f3cc9e23dc76a6
Parents: f77e9e8
Author: Jaimin Jetly jai...@hortonworks.com
Authored: Wed Aug 27 15:41:52 2014 -0700
Committer: Jaimin Jetly jai...@hortonworks.com
Committed: Wed Aug 27 15:41:52 2014 -0700

--
 ambari-web/app/models/stack_service.js | 15 +--
 1 file changed, 1 insertion(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/debf29c2/ambari-web/app/models/stack_service.js
--
diff --git a/ambari-web/app/models/stack_service.js 
b/ambari-web/app/models/stack_service.js
index a711936..89b2b81 100644
--- a/ambari-web/app/models/stack_service.js
+++ b/ambari-web/app/models/stack_service.js
@@ -332,25 +332,12 @@ App.StackService.configCategories = function () {
   serviceConfigCategories.pushObject(App.ServiceConfigCategory.create({ name: 
'Advanced', displayName: 'Advanced'}));
 
   var configTypes = Object.keys(this.get('configTypes'));
-  if (this.get('serviceName') !== 'HDFS') {
-configTypes = configTypes.without('core-site');
-  }
+
   //Falcon has dependency on oozie-site but oozie-site advanced/custom section 
should not be shown on Falcon page
   if (this.get('serviceName') !== 'OOZIE') {
 configTypes = configTypes.without('oozie-site');
   }
 
-  //Hive has dependency on tez-site but tez-site advanced/custom section 
should not be shown on Hive page
-  if (this.get('serviceName') !== 'TEZ') {
-configTypes = configTypes.without('tez-site');
-  }
-
-  //oozie has dependency on yarn-site but yarn-site advanced/custom section 
should not be shown on Oozie page
-  if (this.get('serviceName') !== 'YARN') {
-configTypes = configTypes.without('yarn-site');
-  }
-
-
   // Add Advanced section for every configType to all the services
   configTypes.forEach(function (type) {
 var displayName = 'Advanced ' + type;



[39/45] git commit: AMBARI-7059. FE: Adding Sqoop service right after install doesnt auto-select Client. (Max Shepel via akovalenko)

2014-08-28 Thread jonathanhurley
AMBARI-7059. FE: Adding Sqoop service right after install doesnt auto-select 
Client. (Max Shepel via akovalenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: f2f5dff25143545c6ab542ab0d62c7fc61ea418a
Parents: 6bd0394
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Thu Aug 28 18:09:43 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Thu Aug 28 18:09:43 2014 +0300

--
 .../controllers/main/service/add_controller.js  | 24 +++-
 .../app/controllers/wizard/step8_controller.js  | 12 ++
 ambari-web/app/routes/add_host_routes.js|  2 ++
 ambari-web/app/routes/add_service_routes.js |  2 ++
 ambari-web/app/routes/installer.js  |  2 ++
 .../main/service/add_controller_test.js | 10 
 6 files changed, 36 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f2f5dff2/ambari-web/app/controllers/main/service/add_controller.js
--
diff --git a/ambari-web/app/controllers/main/service/add_controller.js 
b/ambari-web/app/controllers/main/service/add_controller.js
index 52bd41b..cce1f5f 100644
--- a/ambari-web/app/controllers/main/service/add_controller.js
+++ b/ambari-web/app/controllers/main/service/add_controller.js
@@ -391,18 +391,20 @@ App.AddServiceController = App.WizardController.extend({
*/
   installAdditionalClients: function () {
 this.get('content.additionalClients').forEach(function (c) {
-  var queryStr = 'HostRoles/component_name='+ c.componentName + 
'HostRoles/host_name.in(' + c.hostNames.join() + ')';
-  App.ajax.send({
-name: 'common.host_component.update',
-sender: this,
-data: {
-  query: queryStr,
-  context: 'Install ' + App.format.role(c.componentName),
-  HostRoles: {
-state: 'INSTALLED'
+  if (c.hostNames.length  0) {
+var queryStr = 'HostRoles/component_name='+ c.componentName + 
'HostRoles/host_name.in(' + c.hostNames.join() + ')';
+App.ajax.send({
+  name: 'common.host_component.update',
+  sender: this,
+  data: {
+query: queryStr,
+context: 'Install ' + App.format.role(c.componentName),
+HostRoles: {
+  state: 'INSTALLED'
+}
   }
-}
-  });
+});
+  }
 }, this);
   }
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/f2f5dff2/ambari-web/app/controllers/wizard/step8_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step8_controller.js 
b/ambari-web/app/controllers/wizard/step8_controller.js
index 7eef55e..4396432 100644
--- a/ambari-web/app/controllers/wizard/step8_controller.js
+++ b/ambari-web/app/controllers/wizard/step8_controller.js
@@ -1285,11 +1285,13 @@ App.WizardStep8Controller = 
Em.Controller.extend(App.AddSecurityConfigs, {
   }, this);
 }, this);
 hostNames = hostNames.uniq();
-this.get('content.additionalClients').pushObject({hostNames: 
hostNames, componentName: _clientName});
-// If a dependency for being co-hosted is derived between existing 
client and selected new master but that
-// dependency is already satisfied in the cluster then disregard the 
derived dependency
-this.removeClientsFromList(_clientName, hostNames);
-this.registerHostsToComponent(hostNames, _clientName);
+if (hostNames.length  0) {
+  this.get('content.additionalClients').pushObject({hostNames: 
hostNames, componentName: _clientName});
+  // If a dependency for being co-hosted is derived between existing 
client and selected new master but that
+  // dependency is already satisfied in the cluster then disregard the 
derived dependency
+  this.removeClientsFromList(_clientName, hostNames);
+  this.registerHostsToComponent(hostNames, _clientName);
+}
   }
 }, this);
   },

http://git-wip-us.apache.org/repos/asf/ambari/blob/f2f5dff2/ambari-web/app/routes/add_host_routes.js
--
diff --git a/ambari-web/app/routes/add_host_routes.js 
b/ambari-web/app/routes/add_host_routes.js
index e4ae41f..ff281a9 100644
--- a/ambari-web/app/routes/add_host_routes.js
+++ b/ambari-web/app/routes/add_host_routes.js
@@ -154,11 +154,13 @@ module.exports = App.WizardRoute.extend({
 next: function (router, context) {
   var 

[25/45] git commit: AMBARI-7047. BE: Config validation type of values less than recommended should be WARNs

2014-08-28 Thread jonathanhurley
AMBARI-7047. BE: Config validation type of values less than recommended should 
be WARNs


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

Branch: refs/heads/branch-alerts-dev
Commit: fa10e3bff6f18aeee1d93eecf1f15ad0d7657235
Parents: d87cf7f
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Aug 27 13:51:39 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Aug 27 18:31:29 2014 -0700

--
 .../stacks/HDP/2.0.6/services/stack_advisor.py  | 56 +++-
 .../stacks/HDP/2.1/services/stack_advisor.py| 14 ++---
 .../stacks/2.0.6/common/test_stack_advisor.py   | 36 ++---
 3 files changed, 67 insertions(+), 39 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fa10e3bf/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
index ad0dcc0..083286e 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/stack_advisor.py
@@ -415,58 +415,66 @@ class HDP206StackAdvisor(StackAdvisor):
   YARN: [yarn-site, self.validateYARNConfigurations]
 }.get(serviceName, None)
 
-  def toConfigurationValidationErrors(self, items, siteName):
+  def toConfigurationValidationProblems(self, validationProblems, siteName):
 result = []
-for item in items:
-  if item[message] is not None:
-error = { type: 'configuration', level: 'ERROR', message: 
item[message], config-type: siteName, config-name: item[config-name] }
-result.append(error)
+for validationProblem in validationProblems:
+  validationItem = validationProblem.get(item, None)
+  if validationItem is not None:
+problem = { type: 'configuration', level: validationItem[level], 
message: validationItem[message],
+  config-type: siteName, config-name: 
validationProblem[config-name] }
+result.append(problem)
 return result
 
+  def getWarnItem(self, message):
+return {level: WARN, message: message}
+
+  def getErrorItem(self, message):
+return {level: ERROR, message: message}
+
   def validatorLessThenDefaultValue(self, properties, recommendedDefaults, 
propertyName):
 if not propertyName in properties:
-  return Value should be set
+  return self.getErrorItem(Value should be set)
 value = to_number(properties[propertyName])
 if value is None:
-  return Value should be integer
+  return self.getErrorItem(Value should be integer)
 defaultValue = to_number(recommendedDefaults[propertyName])
 if defaultValue is None:
   return None
 if value  defaultValue:
-  return Value is less than the recommended default of 
{0}.format(defaultValue)
+  return self.getWarnItem(Value is less than the recommended default of 
{0}.format(defaultValue))
 return None
 
   def validateXmxValue(self, properties, recommendedDefaults, propertyName):
 if not propertyName in properties:
-  return Value should be set
+  return self.getErrorItem(Value should be set)
 value = properties[propertyName]
 defaultValue = recommendedDefaults[propertyName]
 if defaultValue is None:
-  return Config's default value can't be null or undefined
+  return self.getErrorItem(Config's default value can't be null or 
undefined)
 if not checkXmxValueFormat(value):
-  return 'Invalid value format'
+  return self.getErrorItem('Invalid value format')
 valueInt = formatXmxSizeToBytes(getXmxSize(value))
 defaultValueXmx = getXmxSize(defaultValue)
 defaultValueInt = formatXmxSizeToBytes(defaultValueXmx)
 if valueInt  defaultValueInt:
-  return Value is less than the recommended default of -Xmx + 
defaultValueXmx
+  return self.getWarnItem(Value is less than the recommended default of 
-Xmx + defaultValueXmx)
 return None
 
   def validateMapReduce2Configurations(self, properties, recommendedDefaults):
-validationItems = [ {config-name: 'mapreduce.map.java.opts', message: 
self.validateXmxValue(properties, recommendedDefaults, 
'mapreduce.map.java.opts')},
-{config-name: 'mapreduce.reduce.java.opts', 
message: self.validateXmxValue(properties, recommendedDefaults, 
'mapreduce.reduce.java.opts')},
-{config-name: 'mapreduce.task.io.sort.mb', 
message: 

[37/45] git commit: AMBARI-7058. Improve logging on Ubuntu on package install failure. (aonishuk)

2014-08-28 Thread jonathanhurley
AMBARI-7058. Improve logging on Ubuntu on package install failure. (aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: 1b017b7cd4b4f8fbd89beaf7b1adf8bf9eaac3a2
Parents: 6b7e796
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Thu Aug 28 18:05:09 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Thu Aug 28 18:05:09 2014 +0300

--
 .../python/resource_management/TestPackageResource.py|  6 +++---
 .../resource_management/core/providers/package/apt.py| 11 ---
 2 files changed, 11 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/1b017b7c/ambari-agent/src/test/python/resource_management/TestPackageResource.py
--
diff --git 
a/ambari-agent/src/test/python/resource_management/TestPackageResource.py 
b/ambari-agent/src/test/python/resource_management/TestPackageResource.py
index d36c543..1628322 100644
--- a/ambari-agent/src/test/python/resource_management/TestPackageResource.py
+++ b/ambari-agent/src/test/python/resource_management/TestPackageResource.py
@@ -36,11 +36,11 @@ class TestPackageResource(TestCase):
   )
 call_mock.assert_has_calls([call(dpkg --get-selections some_package | 
grep -v deinstall),
 call(DEBIAN_FRONTEND=noninteractive 
/usr/bin/apt-get -q -o Dpkg::Options::='--force-confdef'
-   --allow-unauthenticated --assume-yes 
install some_package)
+   --allow-unauthenticated --assume-yes 
install some_package),
+call(apt-get update -qq)
   ])
 
-shell_mock.assert_has_calls([call(apt-get update -qq),
-call(DEBIAN_FRONTEND=noninteractive 
/usr/bin/apt-get -q -o Dpkg::Options::='--force-confdef' 
--allow-unauthenticated --assume-yes install some_package)
+shell_mock.assert_has_calls([call(DEBIAN_FRONTEND=noninteractive 
/usr/bin/apt-get -q -o Dpkg::Options::='--force-confdef' 
--allow-unauthenticated --assume-yes install some_package)
   ])
   
   @patch.object(shell, call)

http://git-wip-us.apache.org/repos/asf/ambari/blob/1b017b7c/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
 
b/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
index 4c6e2dd..f001f14 100644
--- 
a/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
+++ 
b/ambari-common/src/main/python/resource_management/core/providers/package/apt.py
@@ -33,12 +33,17 @@ class AptProvider(PackageProvider):
 if not self._check_existence(name):
   cmd = INSTALL_CMD % (name)
   Logger.info(Installing package %s ('%s') % (name, cmd))
-  code = shell.call(cmd)[0]
+  code, out = shell.call(cmd)
   
   # apt-get update wasn't done too long
   if code:
-Logger.info(Failed to install package %s. Executing `apt-get update` 
% (name))
-shell.checked_call(REPO_UPDATE_CMD)
+Logger.info(Execution of '%s' returned %d. %s % (cmd, code, out))
+Logger.info(Failed to install package %s. Executing `%s` % (name, 
REPO_UPDATE_CMD))
+code, out = shell.call(REPO_UPDATE_CMD)
+
+if code:
+  Logger.info(Execution of '%s' returned %d. %s % (REPO_UPDATE_CMD, 
code, out))
+  
 Logger.info(Retrying to install package %s % (name))
 shell.checked_call(cmd)
 else:



[33/45] git commit: AMBARI-7054. Slider View: Create app wizard should allow adding of custom-configs. (onechiporenko)

2014-08-28 Thread jonathanhurley
AMBARI-7054. Slider View: Create app wizard should allow adding of 
custom-configs. (onechiporenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 0fb6e635577aab62157711f1a73c65feb38018c2
Parents: 6bcd6d5
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Thu Aug 28 16:26:23 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Thu Aug 28 16:26:23 2014 +0300

--
 .../ui/app/components/configSection.js  | 122 +--
 .../createAppWizard/step1_controller.js |   1 +
 .../createAppWizard/step3_controller.js |  13 +-
 .../controllers/create_app_wizard_controller.js |  27 +++-
 .../app/templates/components/configSection.hbs  |  58 -
 .../ui/app/templates/createAppWizard/step3.hbs  |   6 +-
 .../src/main/resources/ui/app/translations.js   |   6 +
 7 files changed, 207 insertions(+), 26 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/0fb6e635/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/components/configSection.js 
b/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
index 7b2481d..c5858bc 100644
--- a/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
+++ b/contrib/views/slider/src/main/resources/ui/app/components/configSection.js
@@ -17,32 +17,134 @@
  */
 
 App.ConfigSectionComponent = Em.Component.extend({
-  layoutName:'components/configSection',
-  config:null,
-  section:'',
+
+  layoutName: 'components/configSection',
+
+  config: null,
+
+  section: '',
 
   /**
* label for current section
* @return {String}
*/
   sectionLabel: function () {
-return this.get('section').classify();
+return this.get('section').classify().replace(/([A-Z])/g, ' $1');
   }.property(),
 
   /**
* Return True is section name equals 'general'
* @type {Boolean}
*/
-  isGeneral:Ember.computed.equal('section', 'general'),
+  isGeneral: Ember.computed.equal('section', 'general'),
+
+  /**
+   * Return True is section name equals 'custom'
+   * @type {Boolean}
+   */
+  isCustom: Ember.computed.equal('section', 'custom'),
 
   /**
* Filtered configs for current section
*/
-  sectionConfigs: Ember.computed.filter('config', function(item) {
+  sectionConfigs: Ember.computed.filter('config', function (item) {
 if (this.get('isGeneral')) {
-  return !item.name.match('^site.');
-} else {
-  return !!item.name.match('^site.'+this.get('section')) ;
+  return !item.name.match('^site.')  
this.get('predefinedConfigNames').contains(item.name);
+}
+else {
+  if (this.get('isCustom')) {
+return !this.get('predefinedConfigNames').contains(item.name);
+  }
+  else {
+return !!item.name.match('^site.' + this.get('section'));
+  }
+}
+  }),
+
+  /**
+   * Is button Add Property visible
+   * True - yes, false - no (and App Property-form is visible)
+   * @type {bool}
+   */
+  buttonVisible: true,
+
+  /**
+   * Template for new config
+   * @type {Ember.Object}
+   */
+  newConfig: Em.Object.create({
+name: '',
+value: '',
+nameError: '',
+hasError: false
+  }),
+
+  /**
+   * Clear codenewConfig/code
+   * @method cleanNewConfig
+   */
+  cleanNewConfig: function() {
+this.get('newConfig').setProperties({
+  name: '',
+  value: '',
+  messsage: '',
+  hasError: false
+});
+  },
+
+  actions: {
+
+/**
+ * Click on App Property-button
+ * @method addProperty
+ */
+addProperty: function() {
+  this.toggleProperty('buttonVisible');
+},
+
+/**
+ * Delete custom config added by user
+ * @param {{name: string, label: string, value: *}} config
+ * @method deleteConfig
+ */
+deleteConfig: function(config) {
+  this.get('config').removeObject(config);
+},
+
+/**
+ * Validate and save custom config added by user
+ * @method submit
+ */
+submit: function() {
+  var name = this.get('newConfig.name'),
+value = this.get('newConfig.value');
+  if (this.get('config').mapBy('name').contains(name)) {
+this.get('newConfig').setProperties({
+  hasError: true,
+  messsage: Em.I18n.t('configs.add_property.name_exists')
+});
+return;
+  }
+  if (!/^[A-Za-z][A-Za-z0-9_\-\.]*$/.test(name)) {
+this.get('newConfig').setProperties({
+  hasError: true,
+  messsage: 

git commit: AMBARI-7069. Configs: make comparision bar info more clear.(xiwang)

2014-08-28 Thread xiwang
Repository: ambari
Updated Branches:
  refs/heads/trunk 869b00c61 - 663e0d6f0


AMBARI-7069. Configs: make comparision bar info more clear.(xiwang)


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

Branch: refs/heads/trunk
Commit: 663e0d6f087b5a8ed912712d642d1b8fdd04c50a
Parents: 869b00c
Author: Xi Wang xiw...@apache.org
Authored: Thu Aug 28 17:19:06 2014 -0700
Committer: Xi Wang xiw...@apache.org
Committed: Thu Aug 28 18:04:29 2014 -0700

--
 ambari-web/app/messages.js  |  3 +++
 ambari-web/app/models/service_config.js |  3 +++
 ambari-web/app/models/service_config_version.js |  3 +++
 ambari-web/app/styles/application.less  |  9 +
 .../templates/common/configs/compare_property.hbs   |  2 +-
 .../common/configs/config_history_flow.hbs  | 10 +++---
 .../templates/common/configs/overriddenProperty.hbs |  2 +-
 .../common/configs/service_config_category.hbs  |  2 +-
 .../app/views/common/configs/config_history_flow.js | 16 
 9 files changed, 44 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/663e0d6f/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 4c9abd9..bc8736e 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1412,7 +1412,9 @@ Em.I18n.translations = {
   'services.service.config.configHistory.configGroup': 'Config Group',
   'services.service.config.configHistory.leftArrow.tooltip': 'Show earlier 
versions',
   'services.service.config.configHistory.rightArrow.tooltip': 'Show later 
versions',
+  'services.service.config.configHistory.dismissIcon.tooltip': 'Dismiss',
   'services.service.config.configHistory.makeCurrent.message': 'Created from 
service config version {0}',
+  'services.service.config.configHistory.comparing': 'Comparing',
 
   'services.add.header':'Add Service Wizard',
   'services.reassign.header':'Move Master Wizard',
@@ -2007,6 +2009,7 @@ Em.I18n.translations = {
   'dashboard.configHistory.info-bar.makeCurrent.popup.title': 'Make Current 
Confirmation',
   'dashboard.configHistory.info-bar.save.popup.placeholder': 'What did you 
change?',
   'dashboard.configHistory.info-bar.revert.button': 'Make Current',
+  'dashboard.configHistory.info-bar.revert.versionButton': 'Make {0} Current',
   'dashboard.configHistory.info-bar.view.button.disabled': 'You are currently 
viewing this version.',
   'dashboard.configHistory.info-bar.compare.button.disabled': 'You cannot 
compare against the same version.',
   'dashboard.configHistory.info-bar.revert.button.disabled': 'This is the 
current version.',

http://git-wip-us.apache.org/repos/asf/ambari/blob/663e0d6f/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 8326dd4..891b54f 100644
--- a/ambari-web/app/models/service_config.js
+++ b/ambari-web/app/models/service_config.js
@@ -151,6 +151,9 @@ App.ServiceConfigProperty = Ember.Object.extend({
   isEditable: true, // by default a config property is editable
   isNotEditable: Ember.computed.not('isEditable'),
   isFinal: false,
+  hideFinalIcon: function () {
+return (!this.get('isFinal')) this.get('isNotEditable');
+  }.property('isFinal', 'isNotEditable'),
   defaultIsFinal: false,
   supportsFinal: false,
   isVisible: true,

http://git-wip-us.apache.org/repos/asf/ambari/blob/663e0d6f/ambari-web/app/models/service_config_version.js
--
diff --git a/ambari-web/app/models/service_config_version.js 
b/ambari-web/app/models/service_config_version.js
index 93da4aa..1f34261 100644
--- a/ambari-web/app/models/service_config_version.js
+++ b/ambari-web/app/models/service_config_version.js
@@ -44,6 +44,9 @@ App.ServiceConfigVersion = DS.Model.extend({
   versionText: function () {
 return 
Em.I18n.t('dashboard.configHistory.table.version.versionText').format(this.get('version'));
   }.property('version'),
+  makeCurrentButtonText: function() {
+return 
Em.I18n.t('dashboard.configHistory.info-bar.revert.versionButton').format(this.get('versionText'));
+  }.property('versionText'),
   modifiedDate: function () {
 return dateUtil.dateFormat(this.get('createTime'));
   }.property('createTime'),

http://git-wip-us.apache.org/repos/asf/ambari/blob/663e0d6f/ambari-web/app/styles/application.less

git commit: AMBARI-7071. Admin View: UI tweaks. (yusaku)

2014-08-28 Thread yusaku
Repository: ambari
Updated Branches:
  refs/heads/trunk 663e0d6f0 - 338190375


AMBARI-7071. Admin View: UI tweaks. (yusaku)


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

Branch: refs/heads/trunk
Commit: 33819037526678797645a626950051a54a6bcfc5
Parents: 663e0d6
Author: Yusaku Sako yus...@hortonworks.com
Authored: Thu Aug 28 20:17:22 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Thu Aug 28 20:41:31 2014 -0700

--
 .../ambariViews/CreateViewInstanceCtrl.js   |  5 +++--
 .../controllers/ambariViews/ViewsListCtrl.js|  6 +-
 .../controllers/groups/GroupsCreateCtrl.js  |  1 +
 .../controllers/users/UsersCreateCtrl.js|  1 +
 .../scripts/controllers/users/UsersShowCtrl.js  | 21 +++-
 .../admin-web/app/scripts/services/uiAlert.js   | 21 ++--
 .../app/views/ambariViews/listTable.html|  3 +++
 .../ui/admin-web/app/views/leftNavbar.html  |  2 +-
 8 files changed, 49 insertions(+), 11 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/33819037/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/CreateViewInstanceCtrl.js
--
diff --git 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/CreateViewInstanceCtrl.js
 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/CreateViewInstanceCtrl.js
index 92398ed..47b8f6a 100644
--- 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/CreateViewInstanceCtrl.js
+++ 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/CreateViewInstanceCtrl.js
@@ -74,7 +74,8 @@ angular.module('ambariAdminConsole')
 } else {
   View.createInstance($scope.instance)
   .then(function(data) {
-$location.path('/views');
+uiAlert.success('Created View Instance ' + 
$scope.instance.instance_name);
+$location.path('/views/' + $scope.instance.view_name + 
'/versions/' + $scope.instance.version + '/instances/' + 
$scope.instance.instance_name + '/edit');
   })
   .catch(function(data) {
 uiAlert.danger(data.data.status, data.data.message);
@@ -86,4 +87,4 @@ angular.module('ambariAdminConsole')
   });
 }
   };
-}]);
\ No newline at end of file
+}]);

http://git-wip-us.apache.org/repos/asf/ambari/blob/33819037/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/ViewsListCtrl.js
--
diff --git 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/ViewsListCtrl.js
 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/ViewsListCtrl.js
index b85bcb4..ed97a19 100644
--- 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/ViewsListCtrl.js
+++ 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/ambariViews/ViewsListCtrl.js
@@ -51,9 +51,13 @@ angular.module('ambariAdminConsole')
 var result = [];
 var filter = $scope.viewsFilter.toLowerCase();
 if(!filter){  // if no filter return all views
-  result = $scope.views;
+  result = $scope.views.map(function(view) {
+view.isOpened = false;
+return view;
+  });
 } else {
   result = $scope.views.map(function(view) {
+view.isOpened = true;
 if(view.view_name.toLowerCase().indexOf(filter) = 0){
   return view; // if filter matched with view name -- return whole view
 } else {

http://git-wip-us.apache.org/repos/asf/ambari/blob/33819037/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/groups/GroupsCreateCtrl.js
--
diff --git 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/groups/GroupsCreateCtrl.js
 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/groups/GroupsCreateCtrl.js
index d1c4542..ba35026 100644
--- 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/groups/GroupsCreateCtrl.js
+++ 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/groups/GroupsCreateCtrl.js
@@ -25,6 +25,7 @@ angular.module('ambariAdminConsole')
 $scope.form.submitted = true;
 if ($scope.form.$valid){
   $scope.group.save().then(function() {
+uiAlert.success('Created group ' + $scope.group.group_name);
 $location.path('/groups');
   })