git commit: AMBARI-7356.When the user completes Install Wizard, mark Clusters.provisioning_state as INSTALLED. (akovalenko)

2014-09-17 Thread akovalenko
Repository: ambari
Updated Branches:
  refs/heads/trunk e033815cc - f63dd8a6e


AMBARI-7356.When the user completes Install Wizard, mark 
Clusters.provisioning_state as INSTALLED. (akovalenko)


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

Branch: refs/heads/trunk
Commit: f63dd8a6eea79defd93837dbfc3011f42692ae91
Parents: e033815
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Wed Sep 17 14:06:44 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Wed Sep 17 14:06:44 2014 +0300

--
 ambari-web/app/controllers/installer.js | 15 +
 ambari-web/app/models/cluster_states.js |  1 -
 ambari-web/app/router.js| 84 
 ambari-web/app/routes/installer.js  | 12 ++--
 ambari-web/app/utils/ajax/ajax.js   | 17 +-
 5 files changed, 84 insertions(+), 45 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f63dd8a6/ambari-web/app/controllers/installer.js
--
diff --git a/ambari-web/app/controllers/installer.js 
b/ambari-web/app/controllers/installer.js
index e45eaee..d933e9a 100644
--- a/ambari-web/app/controllers/installer.js
+++ b/ambari-web/app/controllers/installer.js
@@ -745,6 +745,21 @@ App.InstallerController = App.WizardController.extend({
 App.router.get('applicationController').postUserPref(persists, true);
   },
 
+  /**
+   * Save cluster provisioning state to the server
+   * @param state cluster provisioning state
+   * @param callback is called after request completes
+   */
+  setClusterProvisioningState: function (state, callback) {
+App.ajax.send({
+  name: 'cluster.save_provisioning_state',
+  sender: this,
+  data: {
+state: state
+  }
+}).complete(callback());
+  },
+
   setStepsEnable: function () {
 for (var i = 0; i = this.totalSteps; i++) {
   var step = this.get('isStepDisabled').findProperty('step', i);

http://git-wip-us.apache.org/repos/asf/ambari/blob/f63dd8a6/ambari-web/app/models/cluster_states.js
--
diff --git a/ambari-web/app/models/cluster_states.js 
b/ambari-web/app/models/cluster_states.js
index 49760d6..95c1444 100644
--- a/ambari-web/app/models/cluster_states.js
+++ b/ambari-web/app/models/cluster_states.js
@@ -108,7 +108,6 @@ App.clusterStatus = Em.Object.create(App.UserPref, {
* @method updateFromServer
*/
   updateFromServer: function (overrideLocaldb) {
-// if overrideLocaldb is undefined, set it to true
 this.set('additionalData', {
   user: App.db.getUser(),
   login: App.db.getLoginName(),

http://git-wip-us.apache.org/repos/asf/ambari/blob/f63dd8a6/ambari-web/app/router.js
--
diff --git a/ambari-web/app/router.js b/ambari-web/app/router.js
index 18203f2..bbc06dd 100644
--- a/ambari-web/app/router.js
+++ b/ambari-web/app/router.js
@@ -29,6 +29,12 @@ App.Router = Em.Router.extend({
   enableLogging: true,
   isFwdNavigation: true,
   backBtnForHigherStep: false,
+
+  /**
+   * Is true, if cluster.provisioning_state is equal to 'INSTALLED'
+   * @type {Boolean}
+   */
+  clusterInstallCompleted: false,
   /**
* user prefered path to route
*/
@@ -119,6 +125,9 @@ App.Router = Em.Router.extend({
 
   onAuthenticationSuccess: function (data) {
 this.set('loggedIn', true);
+if (data.items.length) {
+  this.set('clusterInstallCompleted', 
data.items[0].Clusters.provisioning_state === 'INSTALLED');
+}
   },
 
   onAuthenticationError: function (data) {
@@ -265,7 +274,7 @@ App.Router = Em.Router.extend({
   App.usersMapper.map({items: [loginData]});
   router.setUserLoggedIn(params.loginName);
   var permissionList = 
privileges.items.mapProperty('PrivilegeInfo.permission_name');
-  var isAdmin = permissionList.indexOf('AMBARI.ADMIN')  -1;
+  var isAdmin = permissionList.contains('AMBARI.ADMIN');
   var transitionToApp = false;
   if (isAdmin) {
 App.set('isAdmin', true);
@@ -277,14 +286,15 @@ App.Router = Em.Router.extend({
 }
   } else {
 if (clustersData.items.length) {
+  this.set('clusterInstallCompleted', 
clustersData.items[0].Clusters.provisioning_state === 'INSTALLED');
   //TODO: Iterate over clusters
   var clusterName = clustersData.items[0].Clusters.cluster_name;
   var clusterPermissions = 
privileges.items.filterProperty('PrivilegeInfo.cluster_name', 
clusterName).mapProperty('PrivilegeInfo.permission_name');
-  if 

git commit: AMBARI-7358 Configs: compare between host config group versions shows other props. (atkach)

2014-09-17 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk f63dd8a6e - 0fb11d23e


AMBARI-7358 Configs: compare between host config group versions shows other 
props. (atkach)


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

Branch: refs/heads/trunk
Commit: 0fb11d23e7c312aa34140ab7ecf3db5826a5e7ab
Parents: f63dd8a
Author: atkach atk...@hortonworks.com
Authored: Wed Sep 17 15:10:27 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Wed Sep 17 15:10:27 2014 +0300

--
 .../controllers/main/service/info/configs.js| 237 +--
 ambari-web/app/models/service_config.js |   1 +
 .../common/configs/compare_property.hbs |  30 +--
 .../common/configs/service_config_category.hbs  |   6 +-
 4 files changed, 192 insertions(+), 82 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/0fb11d23/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 9fcdaaa..4411667 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -185,7 +185,7 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
* @return {Boolean}
*/
   isVersionDefault: function(version) {
-return version  version.get('groupId') == -1;
+return (App.ServiceConfigVersion.find(this.get('content.serviceName') + 
_ + version).get('groupId') == -1);
   },
 
   /**
@@ -324,12 +324,11 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
 var self = this;
 this.set('versionLoaded', false);
 version = version || this.get('currentDefaultVersion');
-var versionRecord = 
App.ServiceConfigVersion.find(this.get('content.serviceName') + _ + version);
 //version of non-default group require properties from current version of 
default group to correctly display page
-var versions = (this.isVersionDefault(versionRecord)) ? [version] : 
[this.get('currentDefaultVersion'), version];
+var versions = (this.isVersionDefault(version)) ? [version] : 
[this.get('currentDefaultVersion'), version];
 
 //if version from default group selected then switch to default group
-if (self.get('dataIsLoaded')  this.isVersionDefault(versionRecord)) {
+if (self.get('dataIsLoaded')  this.isVersionDefault(version)) {
   this.set('selectedConfigGroup', 
this.get('configGroups').findProperty('isDefault'));
 }
 
@@ -569,10 +568,16 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   loadCompareVersionConfigs: function (allConfigs) {
 var dfd = $.Deferred();
 var self = this;
-var compareServiceVersion = this.get('compareServiceVersion');
+var compareServiceVersions = [];
 
-if (compareServiceVersion) {
-  this.getCompareVersionConfigs(compareServiceVersion).done(function 
(json) {
+if (this.get('compareServiceVersion')) {
+  if 
(!this.isVersionDefault(this.get('compareServiceVersion').get('version'))) {
+compareServiceVersions = 
[this.get('compareServiceVersion').get('version'), this.get('selectedVersion')];
+  } else {
+compareServiceVersions = 
[this.get('compareServiceVersion').get('version')];
+  }
+
+  this.getCompareVersionConfigs(compareServiceVersions).done(function 
(json) {
 self.initCompareConfig(allConfigs, json);
 self.set('compareServiceVersion', null);
 self.set('isCompareMode', true);
@@ -597,76 +602,173 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   initCompareConfig: function(allConfigs, json) {
 var serviceVersionMap = {};
 var configNamesMap = {};
-var serviceName = json.items[0].service_name;
-var compareServiceVersion = this.get('compareServiceVersion');
+var serviceName = this.get('content.serviceName');
+var compareVersionNumber = 
this.get('compareServiceVersion').get('version');
+//indicate whether compared versions are from non-default group
+var compareNonDefaultVersions = (json.items.length  1);
 
+serviceVersionMap[compareVersionNumber] = {};
+if (compareNonDefaultVersions) {
+  serviceVersionMap[this.get('selectedVersion')] = {};
+}
 allConfigs.mapProperty('name').forEach(function(name) {
   configNamesMap[name] = true;
 });
 
-json.items[0].configurations.forEach(function (configuration) {
-  if (serviceName == 'YARN'  configuration.type == 

[01/29] git commit: AMBARI-7331. HDFS check fails with mkdir: /tmp: File exists(vbrodetskyi)

2014-09-17 Thread jonathanhurley
Repository: ambari
Updated Branches:
  refs/heads/branch-alerts-dev b7ae2d74a - a4e97aaa2


AMBARI-7331. HDFS check fails with mkdir: /tmp: File exists(vbrodetskyi)


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

Branch: refs/heads/branch-alerts-dev
Commit: f8aa99b34ae66fd3f06705b6b92edffcd28dfc9c
Parents: bd04a28
Author: Vitaly Brodetskyi vbrodets...@hortonworks.com
Authored: Tue Sep 16 16:38:06 2014 +0300
Committer: Vitaly Brodetskyi vbrodets...@hortonworks.com
Committed: Tue Sep 16 16:38:06 2014 +0300

--
 .../HDP/1.3.2/services/HDFS/package/scripts/service_check.py   | 2 +-
 .../HDP/2.0.6/services/HDFS/package/scripts/service_check.py   | 2 +-
 .../src/test/python/stacks/1.3.2/HDFS/test_service_check.py| 2 +-
 .../src/test/python/stacks/2.0.6/HDFS/test_service_check.py| 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f8aa99b3/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/service_check.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/service_check.py
 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/service_check.py
index 58da7ec..e04d68c 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/service_check.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/service_check.py
@@ -32,7 +32,7 @@ class HdfsServiceCheck(Script):
 safemode_command = dfsadmin -safemode get | grep OFF
 
 create_dir_cmd = format(fs -mkdir {dir} ; hadoop fs -chmod 777 {dir})
-test_dir_exists = format(hadoop fs -test -e {dir})
+test_dir_exists = format(su - {smoke_user} -c 'hadoop fs -test -e {dir}')
 cleanup_cmd = format(fs -rm {tmp_file})
 #cleanup put below to handle retries; if retrying there wil be a stale file
 #that needs cleanup; exit code is fn of second command

http://git-wip-us.apache.org/repos/asf/ambari/blob/f8aa99b3/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/service_check.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/service_check.py
 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/service_check.py
index 18f58bd..ef9a361 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/service_check.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/service_check.py
@@ -33,7 +33,7 @@ class HdfsServiceCheck(Script):
 
 create_dir_cmd = format(fs -mkdir {dir})
 chmod_command = format(fs -chmod 777 {dir})
-test_dir_exists = format(hadoop --config {hadoop_conf_dir} fs -test -e 
{dir})
+test_dir_exists = format(su - {smoke_user} -c 'hadoop --config 
{hadoop_conf_dir} fs -test -e {dir}')
 cleanup_cmd = format(fs -rm {tmp_file})
 #cleanup put below to handle retries; if retrying there wil be a stale file
 #that needs cleanup; exit code is fn of second command

http://git-wip-us.apache.org/repos/asf/ambari/blob/f8aa99b3/ambari-server/src/test/python/stacks/1.3.2/HDFS/test_service_check.py
--
diff --git 
a/ambari-server/src/test/python/stacks/1.3.2/HDFS/test_service_check.py 
b/ambari-server/src/test/python/stacks/1.3.2/HDFS/test_service_check.py
index beed46a..629406f 100644
--- a/ambari-server/src/test/python/stacks/1.3.2/HDFS/test_service_check.py
+++ b/ambari-server/src/test/python/stacks/1.3.2/HDFS/test_service_check.py
@@ -57,7 +57,7 @@ class TestServiceCheck(RMFTestCase):
 conf_dir = '/etc/hadoop/conf',
 bin_dir = '/usr/bin',
 logoutput = True,
-not_if = 'hadoop --config /etc/hadoop/conf fs -test -e /tmp',
+not_if = 'su - ambari-qa -c \'hadoop --config /etc/hadoop/conf fs 
-test -e /tmp\'',
 try_sleep = 3,
 tries = 5,
 user = 'ambari-qa',

http://git-wip-us.apache.org/repos/asf/ambari/blob/f8aa99b3/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_service_check.py
--
diff --git 
a/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_service_check.py 
b/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_service_check.py
index 57abab3..01f96c7 100644
--- 

[28/29] git commit: AMBARI-7359. Move Wizard should be disabled for single node cluster. (akovalenko)

2014-09-17 Thread jonathanhurley
AMBARI-7359. Move Wizard should be disabled for single node cluster. 
(akovalenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 24f0b47e5220a8e696233658fd99a08b8cdc399c
Parents: 0fb11d2
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Wed Sep 17 15:19:08 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Wed Sep 17 15:19:08 2014 +0300

--
 ambari-web/app/messages.js  |  1 +
 ambari-web/app/routes/reassign_master_routes.js | 96 +++-
 2 files changed, 52 insertions(+), 45 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/24f0b47e/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index f158f8d..7379220 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1459,6 +1459,7 @@ Em.I18n.translations = {
   'services.service.config_groups.switchGroupTextFull':'Switch to \'{0}\' host 
config group',
   'services.service.config_groups.switchGroupTextShort':'Switch to \'{0}\'',
   'services.reassign.closePopup':'Move {0} wizard is in progress. You must 
allow the wizard to complete for Ambari to be in usable state. If you choose to 
quit, you must follow manual instructions to complete or revert move {0} wizard 
as documented in the Ambari User Guide. Are you sure you want to exit the 
wizard?',
+  'services.reassign.error.fewHosts':'You must have at least 2 hosts in your 
cluster to run Move Wizard.',
 
   'services.reassign.step1.header':'Get Started',
   'services.reassign.step1.message1': 'This wizard will walk you through 
moving {0}.br/',

http://git-wip-us.apache.org/repos/asf/ambari/blob/24f0b47e/ambari-web/app/routes/reassign_master_routes.js
--
diff --git a/ambari-web/app/routes/reassign_master_routes.js 
b/ambari-web/app/routes/reassign_master_routes.js
index 85f91aa..f28083a 100644
--- a/ambari-web/app/routes/reassign_master_routes.js
+++ b/ambari-web/app/routes/reassign_master_routes.js
@@ -34,56 +34,62 @@ module.exports = App.WizardRoute.extend({
 
   enter: function (router) {
 console.log('in /service/reassign:enter');
-var context = this;
-Em.run.next(function () {
-  var reassignMasterController = router.get('reassignMasterController');
-  App.router.get('updateController').set('isWorking', false);
-  var popup = App.ModalPopup.show({
-classNames: ['full-width-modal'],
-header: Em.I18n.t('services.reassign.header'),
-bodyClass: App.ReassignMasterView.extend({
-  controller: reassignMasterController
-}),
-primary: Em.I18n.t('form.cancel'),
-showFooter: false,
-secondary: null,
+if (App.router.get('mainHostController.hostsCountMap.TOTAL')  1) {
+  var context = this;
+  Em.run.next(function () {
+var reassignMasterController = router.get('reassignMasterController');
+App.router.get('updateController').set('isWorking', false);
+var popup = App.ModalPopup.show({
+  classNames: ['full-width-modal'],
+  header: Em.I18n.t('services.reassign.header'),
+  bodyClass: App.ReassignMasterView.extend({
+controller: reassignMasterController
+  }),
+  primary: Em.I18n.t('form.cancel'),
+  showFooter: false,
+  secondary: null,
 
-onPrimary: function () {
-  this.hide();
-  App.router.get('updateController').set('isWorking', true);
-  App.router.transitionTo('main.services.index');
-},
-onClose: function () {
-  var reassignMasterController = 
router.get('reassignMasterController');
-  var currStep = reassignMasterController.get('currentStep');
+  onPrimary: function () {
+this.hide();
+App.router.get('updateController').set('isWorking', true);
+App.router.transitionTo('main.services.index');
+  },
+  onClose: function () {
+var reassignMasterController = 
router.get('reassignMasterController');
+var currStep = reassignMasterController.get('currentStep');
 
-  if (parseInt(currStep)  3) {
-var self = this;
-App.showConfirmationPopup(function(){
-  router.get('reassignMasterWizardStep' + currStep + 
'Controller').removeObserver('tasks.@each.status', this, 'onTaskStatusChange');
-  context.leaveWizard(router,self);
-}, 

[22/29] git commit: AMBARI-7347. Cannot view slider instance in API due to exception (srimanth)

2014-09-17 Thread jonathanhurley
AMBARI-7347. Cannot view slider instance in API due to exception (srimanth)


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

Branch: refs/heads/branch-alerts-dev
Commit: e83ab259c582cbe7ab2e9a9cf7505e6d4f364afb
Parents: fe890e9
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Tue Sep 16 15:12:50 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Tue Sep 16 15:12:57 2014 -0700

--
 contrib/views/slider/pom.xml|  2 +-
 .../slider/SliderAppTypesResourceProvider.java  |  6 +++--
 .../slider/SliderAppsViewControllerImpl.java| 28 +++-
 .../ui/app/controllers/slider_controller.js |  1 -
 .../src/main/resources/ui/app/helpers/ajax.js   |  6 -
 5 files changed, 32 insertions(+), 11 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e83ab259/contrib/views/slider/pom.xml
--
diff --git a/contrib/views/slider/pom.xml b/contrib/views/slider/pom.xml
index 82d27bb..8c33c93 100644
--- a/contrib/views/slider/pom.xml
+++ b/contrib/views/slider/pom.xml
@@ -551,7 +551,7 @@
/resource
resource
targetPathWEB-INF/lib/targetPath
-   filteringtrue/filtering
+   filteringfalse/filtering
directorylib/directory
includes
includeslider-agent.tar.gz/include

http://git-wip-us.apache.org/repos/asf/ambari/blob/e83ab259/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppTypesResourceProvider.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppTypesResourceProvider.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppTypesResourceProvider.java
index e696016..725c18a 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppTypesResourceProvider.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppTypesResourceProvider.java
@@ -75,8 +75,10 @@ public class SliderAppTypesResourceProvider implements
SetSliderAppType appSet = new HashSetSliderAppType();
ListSliderAppType sliderAppTypes = 
sliderController.getSliderAppTypes(request
.getPropertyIds());
-   for (SliderAppType app : sliderAppTypes)
-   appSet.add(app);
+if (sliderAppTypes != null) {
+  for (SliderAppType app : sliderAppTypes)
+appSet.add(app);
+}
return appSet;
}
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/e83ab259/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
index 04533ee..f3c3087 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
@@ -26,6 +26,8 @@ import java.io.InputStream;
 import java.lang.reflect.Field;
 import java.security.PrivilegedExceptionAction;
 import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
@@ -447,9 +449,20 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
 return yarnConfig;
   }
 
+  private boolean areViewParametersSet() {
+String hdfsPath = viewContext.getProperties().get(PROPERTY_HDFS_ADDRESS);
+String rmAddress = 
viewContext.getProperties().get(PROPERTY_YARN_RM_ADDRESS);
+String rmSchedulerAddress = 
viewContext.getProperties().get(PROPERTY_YARN_RM_SCHEDULER_ADDRESS);
+String zkQuorum = viewContext.getProperties().get(PROPERTY_ZK_QUOROM);
+return hdfsPath!=null  rmAddress!=null  rmSchedulerAddress!=null  
zkQuorum!=null;
+  }
+
   @Override
   public ListSliderApp getSliderApps(final SetString properties)
   throws YarnException, IOException, InterruptedException {
+if (!areViewParametersSet()) {
+  return 

[17/29] git commit: AMBARI-7225 deploy of 2.1.GlusterFS stack errors with: org.apache.ambari.server.controller.spi.SystemException: An internal system exception occurred: Configuration with tag 'versi

2014-09-17 Thread jonathanhurley
AMBARI-7225 deploy of 2.1.GlusterFS stack errors with:  
org.apache.ambari.server.controller.spi.SystemException: An internal system 
exception occurred: Configuration with tag 'version1' exists for 'core-site'
(Scott Creeley via eboyd)


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

Branch: refs/heads/branch-alerts-dev
Commit: b1336f395a93549b8e0591ff1e67a924aef6cfba
Parents: ceee5bf
Author: Erin A Boyd eb...@redhat.com
Authored: Tue Sep 16 14:42:35 2014 -0400
Committer: root r...@ambari.rhs
Committed: Tue Sep 16 14:43:40 2014 -0400

--
 .../GLUSTERFS/configuration/hadoop-env.xml  |  2 ++
 .../services/YARN/configuration/core-site.xml   | 20 
 2 files changed, 2 insertions(+), 20 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/b1336f39/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/GLUSTERFS/configuration/hadoop-env.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/GLUSTERFS/configuration/hadoop-env.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/GLUSTERFS/configuration/hadoop-env.xml
index 6b00199..6c6d4c1 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/GLUSTERFS/configuration/hadoop-env.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/GLUSTERFS/configuration/hadoop-env.xml
@@ -81,11 +81,13 @@
 valuehdfs/value
 descriptionUser to run HDFS as/description
   /property
+  !--
   property
 nameuser_group/name
 valuehadoop/value
 descriptionProxy user group./description
   /property
+  --
 !-- hadoop-env.sh --
   property
 namecontent/name

http://git-wip-us.apache.org/repos/asf/ambari/blob/b1336f39/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/YARN/configuration/core-site.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/YARN/configuration/core-site.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/YARN/configuration/core-site.xml
deleted file mode 100644
index 60f01ad..000
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/YARN/configuration/core-site.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-?xml version=1.0?
-?xml-stylesheet type=text/xsl href=configuration.xsl?
-!--
-   Licensed to the Apache Software Foundation (ASF) under one or more
-   contributor license agreements.  See the NOTICE file distributed with
-   this work for additional information regarding copyright ownership.
-   The ASF licenses this 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=true
-/configuration



[19/29] git commit: AMBARI-7327. After NameNode HA is enabled UI doesn't load (aonishuk)

2014-09-17 Thread jonathanhurley
AMBARI-7327. After NameNode HA is enabled UI doesn't load (aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: ceee5bfedd4a861594f74002ba7228e60803c7a6
Parents: db62322
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Tue Sep 16 22:10:40 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Tue Sep 16 22:10:40 2014 +0300

--
 .../server/api/util/StackExtensionHelper.java   |   31 +-
 .../api/util/StackExtensionHelperTest.java  |   20 +
 .../stacks/HDP/2.0.7/services/HDFS/metrics.json | 7840 --
 3 files changed, 44 insertions(+), 7847 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ceee5bfe/ambari-server/src/main/java/org/apache/ambari/server/api/util/StackExtensionHelper.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/api/util/StackExtensionHelper.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/api/util/StackExtensionHelper.java
index d5d816e..a63be38 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/api/util/StackExtensionHelper.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/api/util/StackExtensionHelper.java
@@ -220,12 +220,16 @@ public class StackExtensionHelper {
 mergedServiceInfo.setCustomCommands(mergedCustomCommands);
 
 // metrics
-if (null == childService.getMetricsFile()  null != 
parentService.getMetricsFile())
+if (null != childService.getMetricsFile())
+  mergedServiceInfo.setMetricsFile(childService.getMetricsFile());
+else if (null != parentService.getMetricsFile())
   mergedServiceInfo.setMetricsFile(parentService.getMetricsFile());
 
 // alerts
-if (null == childService.getAlertsFile()  null != 
parentService.getAlertsFile())
-  mergedServiceInfo.setAlertsFile(parentService.getAlertsFile());
+if (null != childService.getAlertsFile())
+  mergedServiceInfo.setAlertsFile(childService.getAlertsFile());
+else if (null != parentService.getAlertsFile())
+  mergedServiceInfo.setAlertsFile(parentService.getAlertsFile());
 
 populateComponents(mergedServiceInfo, parentService, childService);
 
@@ -425,12 +429,24 @@ public class StackExtensionHelper {
 // Map services with unique names
 MapString, ServiceInfo serviceInfoMap = new HashMapString,
   ServiceInfo();
+ListServiceInfo serviceInfoList = null;
 // Iterate with oldest parent first - all stacks are populated
+StackInfo parentStack = null;
 while(lt.hasPrevious()) {
-  StackInfo parentStack = lt.previous();
-  ListServiceInfo serviceInfoList = parentStack.getServices();
+  if (parentStack == null) {
+parentStack = lt.previous();
+serviceInfoList = parentStack.getServices();
+for (ServiceInfo service : serviceInfoList){
+  if (!service.isDeleted()) {
+serviceInfoMap.put(service.getName(), service);
+  }
+}
+continue;
+  }
+  StackInfo currentStackInfo = lt.previous();
+  serviceInfoList = currentStackInfo.getServices();
   
-  mergeStacks(parentStack, stackInfo);
+  mergeStacks(parentStack, currentStackInfo);
   
   for (ServiceInfo service : serviceInfoList) {
 ServiceInfo existingService = serviceInfoMap.get(service.getName());
@@ -439,7 +455,7 @@ public class StackExtensionHelper {
   continue;
 }
 
-if (existingService == null) {
+if (existingService == null  !service.isDeleted()) {
   serviceInfoMap.put(service.getName(), service);
 } else {
   // Redefined service - merge with parent
@@ -467,6 +483,7 @@ public class StackExtensionHelper {
 }
 
   }
+  parentStack = currentStackInfo;
 }
 return new ArrayListServiceInfo(serviceInfoMap.values());
   }

http://git-wip-us.apache.org/repos/asf/ambari/blob/ceee5bfe/ambari-server/src/test/java/org/apache/ambari/server/api/util/StackExtensionHelperTest.java
--
diff --git 
a/ambari-server/src/test/java/org/apache/ambari/server/api/util/StackExtensionHelperTest.java
 
b/ambari-server/src/test/java/org/apache/ambari/server/api/util/StackExtensionHelperTest.java
index 346202e..2219b6f 100644
--- 
a/ambari-server/src/test/java/org/apache/ambari/server/api/util/StackExtensionHelperTest.java
+++ 
b/ambari-server/src/test/java/org/apache/ambari/server/api/util/StackExtensionHelperTest.java
@@ -649,6 +649,26 @@ public class 

[23/29] git commit: AMBARI-7345 - Views : Exception from ambari-server startup, extract views

2014-09-17 Thread jonathanhurley
AMBARI-7345 - Views : Exception from ambari-server startup, extract views


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

Branch: refs/heads/branch-alerts-dev
Commit: 19533465d6ccc4c57d00ed8c9af7815f32b2cead
Parents: e83ab25
Author: tbeerbower tbeerbo...@hortonworks.com
Authored: Tue Sep 16 17:41:13 2014 -0400
Committer: tbeerbower tbeerbo...@hortonworks.com
Committed: Tue Sep 16 19:06:18 2014 -0400

--
 .../apache/ambari/server/view/ViewRegistry.java | 67 +--
 ambari-server/src/main/python/ambari-server.py  | 42 +++--
 .../ambari/server/view/ViewRegistryTest.java| 90 
 .../view/configuration/ViewConfigTest.java  |  1 +
 4 files changed, 186 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/19533465/ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java 
b/ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java
index 8f6774e..5e652a1 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java
@@ -28,7 +28,6 @@ import 
org.apache.ambari.server.api.resources.ViewExternalSubResourceDefinition;
 import org.apache.ambari.server.api.services.ViewExternalSubResourceService;
 import org.apache.ambari.server.api.services.ViewSubResourceService;
 import org.apache.ambari.server.configuration.Configuration;
-import org.apache.ambari.server.controller.ControllerModule;
 import org.apache.ambari.server.controller.spi.Resource;
 import org.apache.ambari.server.orm.dao.MemberDAO;
 import org.apache.ambari.server.orm.dao.PrivilegeDAO;
@@ -101,6 +100,7 @@ public class ViewRegistry {
* Constants
*/
   private static final String EXTRACTED_ARCHIVES_DIR = work;
+  private static final String EXTRACT_COMMAND = extract;
 
   /**
* Thread pool
@@ -219,15 +219,31 @@ public class ViewRegistry {
* Registry main method.
*
* @param args  the command line arguments
-   *
-   * @throws Exception if the registry command can not be completed
*/
-  public static void main(String[] args) throws Exception {
+  public static void main(String[] args) {
+
+if (args.length = 2) {
+  String archivePath = args[1];
+
+  try {
+Injector injector = Guice.createInjector();
 
-Injector injector = Guice.createInjector(new ControllerModule());
-initInstance(injector.getInstance(ViewRegistry.class));
+ViewExtractor  extractor  = 
injector.getInstance(ViewExtractor.class);
+ViewArchiveUtility archiveUtility = 
injector.getInstance(ViewArchiveUtility.class);
+Configuration  configuration  = 
injector.getInstance(Configuration.class);
 
-singleton.readViewArchives(true, false);
+if (args[0].equals(EXTRACT_COMMAND)) {
+  if (extractViewArchive(archivePath, extractor, archiveUtility, 
configuration, true)) {
+System.exit(0);
+  }
+}
+  } catch (Exception e) {
+String msg = Caught exception extracting view archive  + archivePath 
+ .;
+LOG.error(msg, e);
+System.exit(2);
+  }
+}
+System.exit(1);
   }
 
   /**
@@ -1229,6 +1245,43 @@ public class ViewRegistry {
 }
   }
 
+  // extract the view archive for the given path.
+  protected static boolean extractViewArchive(String archivePath,
+ViewExtractor extractor,
+ViewArchiveUtility archiveUtility,
+Configuration configuration,
+boolean systemOnly ) throws 
Exception {
+
+File viewDir = configuration.getViewsDir();
+
+String extractedArchivesPath = viewDir.getAbsolutePath() +
+File.separator + EXTRACTED_ARCHIVES_DIR;
+
+if (extractor.ensureExtractedArchiveDirectory(extractedArchivesPath)) {
+
+  File archiveFile = archiveUtility.getFile(archivePath);
+
+  ViewConfig viewConfig = 
archiveUtility.getViewConfigFromArchive(archiveFile);
+
+  String commonName = viewConfig.getName();
+  String version= viewConfig.getVersion();
+  String viewName   = ViewEntity.getViewName(commonName, version);
+
+  String extractedArchiveDirPath = extractedArchivesPath + File.separator 
+ viewName;
+  File   extractedArchiveDirFile = 
archiveUtility.getFile(extractedArchiveDirPath);
+
+  if 

[14/29] git commit: AMBARI-7308 Configs: changes to host config group are not saving notes. (ababiichuk)

2014-09-17 Thread jonathanhurley
AMBARI-7308 Configs: changes to host config group are not saving notes. 
(ababiichuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: f53e654513c7c0be09b62f748599c804bd18385e
Parents: 4770717
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Mon Sep 15 17:16:26 2014 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Tue Sep 16 20:49:01 2014 +0300

--
 ambari-web/app/controllers/main/service/info/configs.js | 1 +
 1 file changed, 1 insertion(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f53e6545/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 e7ee933..9fcdaaa 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -1282,6 +1282,7 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   tag: selectedConfigGroup.get('service.id'),
   description: selectedConfigGroup.get('description'),
   hosts: groupHosts,
+  service_config_version_note: this.get('serviceConfigVersionNote'),
   desired_configs: this.buildGroupDesiredConfigs(overridenConfigs)
 }
   }, true);



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

2014-09-17 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/a4e97aaa
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/a4e97aaa
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/a4e97aaa

Branch: refs/heads/branch-alerts-dev
Commit: a4e97aaa2df20b7434676dbdcc8afa9f28bdc84d
Parents: b7ae2d7 24f0b47
Author: Jonathan Hurley jhur...@hortonworks.com
Authored: Wed Sep 17 08:33:22 2014 -0400
Committer: Jonathan Hurley jhur...@hortonworks.com
Committed: Wed Sep 17 08:33:22 2014 -0400

--
 .../app/scripts/controllers/mainCtrl.js |   13 +-
 .../resources/ui/admin-web/app/styles/main.css  |   42 +-
 .../resources/ui/admin-web/app/views/main.html  |   41 +-
 .../src/main/python/ambari_jinja2/ext/jinja.el  |  213 -
 .../server/actionmanager/ActionScheduler.java   |   26 +-
 .../ambari/server/actionmanager/Request.java|   23 +-
 .../server/api/util/StackExtensionHelper.java   |   35 +-
 .../server/controller/ExecuteActionRequest.java |   20 +-
 .../controller/MaintenanceStateHelper.java  |2 +-
 .../internal/ConfigGroupResourceProvider.java   |   20 +-
 .../internal/RequestResourceProvider.java   |   12 +-
 .../server/orm/entities/RequestEntity.java  |   12 +
 .../server/upgrade/UpgradeCatalog170.java   |4 +
 .../apache/ambari/server/view/ViewRegistry.java |   67 +-
 ambari-server/src/main/python/ambari-server.py  |   42 +-
 .../main/resources/Ambari-DDL-MySQL-CREATE.sql  |2 +-
 .../main/resources/Ambari-DDL-Oracle-CREATE.sql |2 +-
 .../resources/Ambari-DDL-Postgres-CREATE.sql|2 +-
 .../Ambari-DDL-Postgres-EMBEDDED-CREATE.sql |2 +-
 .../src/main/resources/properties.json  |1 +
 .../HDFS/package/scripts/service_check.py   |2 +-
 .../services/HIVE/configuration/hive-site.xml   |   19 +
 .../HDFS/package/scripts/service_check.py   |2 +-
 .../services/HIVE/configuration/hive-site.xml   |   19 +
 .../stacks/HDP/2.0/role_command_order.json  |2 +-
 .../stacks/HDP/2.0/services/HBASE/metainfo.xml  |3 -
 .../stacks/HDP/2.0/services/HDFS/metainfo.xml   |1 -
 .../stacks/HDP/2.0/services/HIVE/metainfo.xml   |6 -
 .../stacks/HDP/2.0/services/OOZIE/metainfo.xml  |3 -
 .../stacks/HDP/2.0/services/PIG/metainfo.xml|1 -
 .../stacks/HDP/2.0/services/SQOOP/metainfo.xml  |3 -
 .../HDP/2.0/services/WEBHCAT/metainfo.xml   |   27 -
 .../stacks/HDP/2.0/services/YARN/metainfo.xml   |2 -
 .../HDP/2.0/services/ZOOKEEPER/metainfo.xml |1 -
 .../GLUSTERFS/configuration/hadoop-env.xml  |2 +
 .../services/HIVE/configuration/hive-site.xml   |   19 +
 .../services/YARN/configuration/core-site.xml   |   20 -
 .../stacks/HDP/2.1/services/FLUME/metainfo.xml  |3 +-
 .../stacks/HDP/2.1/services/HBASE/metainfo.xml  |3 -
 .../stacks/HDP/2.1/services/HDFS/metainfo.xml   |1 -
 .../services/HIVE/configuration/hive-site.xml   |   19 +
 .../stacks/HDP/2.1/services/HIVE/metainfo.xml   |1 -
 .../stacks/HDP/2.1/services/NAGIOS/metainfo.xml |1 -
 .../stacks/HDP/2.1/services/OOZIE/metainfo.xml  |2 -
 .../stacks/HDP/2.1/services/PIG/metainfo.xml|1 -
 .../stacks/HDP/2.1/services/SQOOP/metainfo.xml  |3 -
 .../stacks/HDP/2.1/services/YARN/metainfo.xml   |1 -
 .../HDP/2.1/services/ZOOKEEPER/metainfo.xml |2 -
 .../stacks/HDP/2.2.1/repos/repoinfo.xml |2 +-
 .../stacks/HDP/2.2.1/services/HDFS/metainfo.xml |1 -
 .../stacks/HDP/2.2.1/services/HIVE/metainfo.xml |1 -
 .../stacks/HDP/2.2/services/FALCON/metainfo.xml |1 -
 .../stacks/HDP/2.2/services/FLUME/metainfo.xml  |1 -
 .../stacks/HDP/2.2/services/HBASE/metainfo.xml  |3 -
 .../stacks/HDP/2.2/services/HDFS/metainfo.xml   |1 -
 .../stacks/HDP/2.2/services/HIVE/metainfo.xml   |1 -
 .../stacks/HDP/2.2/services/OOZIE/metainfo.xml  |2 -
 .../stacks/HDP/2.2/services/PIG/metainfo.xml|1 -
 .../stacks/HDP/2.2/services/SQOOP/metainfo.xml  |3 -
 .../stacks/HDP/2.2/services/STORM/metainfo.xml  |1 -
 .../stacks/HDP/2.2/services/TEZ/metainfo.xml|1 -
 .../HDP/2.2/services/WEBHCAT/metainfo.xml   |1 -
 .../stacks/HDP/2.2/services/YARN/metainfo.xml   |2 -
 .../HDP/2.2/services/ZOOKEEPER/metainfo.xml |1 -
 .../actionmanager/TestActionDBAccessorImpl.java |2 +-
 .../actionmanager/TestActionScheduler.java  |  264 +-
 .../api/util/StackExtensionHelperTest.java  |   20 +
 .../AmbariCustomCommandExecutionHelperTest.java |2 +-
 .../AmbariManagementControllerTest.java |   86 +-
 .../BackgroundCustomCommandExecutionTest.java   |2 +-
 .../ambari/server/view/ViewRegistryTest.java|   90 +
 .../view/configuration/ViewConfigTest.java  |1 +
 .../stacks/1.3.2/HDFS/test_service_check.py |2 +-
 .../stacks/2.0.6/HDFS/test_service_check.py |2 +-
 

[06/29] git commit: AMBARI-7334. Slider View: Show view name along with hover of view properties. (onechiporenko)

2014-09-17 Thread jonathanhurley
AMBARI-7334. Slider View: Show view name along with hover of view properties. 
(onechiporenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 42a5a33497e432f3d7f258f7070eeeaf20beb2a8
Parents: 460ae9e
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Tue Sep 16 18:01:26 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Tue Sep 16 18:01:26 2014 +0300

--
 .../ui/app/controllers/slider_controller.js | 104 +
 .../src/main/resources/ui/app/initialize.js |  31 +++--
 .../ui/app/mappers/application_status.js| 115 ---
 .../resources/ui/app/styles/application.less|   8 ++
 .../resources/ui/app/templates/application.hbs  |   4 +-
 .../ui/app/templates/slider_title_tooltip.hbs   |  27 +
 .../src/main/resources/ui/app/translations.js   |   2 +-
 .../resources/ui/app/views/application_view.js  |  64 +++
 8 files changed, 207 insertions(+), 148 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/42a5a334/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
index 8283de1..a5eec96 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
@@ -29,29 +29,36 @@
  * If Slider-properties exists:
  *  - Load cluster name
  *  - Load hostNames
+ * After whole data has been loaded set codeApp.sliderConfigs/code and 
enable/disable Slider
  * @type {Ember.Controller}
  */
-App.SliderController = Ember.Controller.extend({
+App.SliderController = Ember.Controller.extend(App.RunPeriodically, {
 
   /**
-   *  Load resources on controller initialization
-   * @method initResources
+   * Map for Slider-errors
+   * If some config is empty, service isn't installed
+   * @type {object}
*/
-  initResources: function () {
-this.getParametersFromViewProperties();
+  serviceConfigMap: {
+HDFS: 'hdfsAddress',
+YARN: 'yarnResourceManager',
+ZOOKEEPER: 'zookeeperQuorum'
   },
 
   /**
* List of Slider-properties mapped from Ambari-configs
+   * Key-names used in Slider-Title-Popup, so don't change it pls
* @type {Em.Object}
*/
   initialValuesToLoad: Em.Object.create({
 ambariAddress: null,
 clusterName: null,
 hdfsAddress: null,
-yarnRMAddress: null,
-yarnRMSchedulerAddress: null,
-zookeeperQuorum: null
+yarnResourceManager: null,
+yarnResourceManagerScheduler: null,
+zookeeperQuorum: null,
+gangliaServer: null,
+gangliaClusters: null
   }),
 
   /**
@@ -61,6 +68,14 @@ App.SliderController = Ember.Controller.extend({
   zookeeperHosts: [],
 
   /**
+   *  Load resources on controller initialization
+   * @method initResources
+   */
+  initResources: function () {
+this.getParametersFromViewProperties();
+  },
+
+  /**
* Get Slider properties from View-parameters (set in the Ambari Admin View)
* If parameters can't be found, use Ambari-configs to populate Slider 
properties
* @returns {$.ajax}
@@ -71,20 +86,44 @@ App.SliderController = Ember.Controller.extend({
   name: 'slider.getViewParams',
   sender: this,
   success: 'getParametersFromViewPropertiesSuccessCallback',
-  error: 'getClusterName'
+  error: 'getParametersFromViewPropertiesErrorCallback'
 });
   },
 
   /**
* Check if Slider-properties exist
+   * If exist - set Slider properties using view-configs
* If not - get Ambari configs to populate Slider properties
* @param {object} data
* @method getParametersFromViewPropertiesSuccessCallback
*/
   getParametersFromViewPropertiesSuccessCallback: function(data) {
 var properties = Em.get(data, 'ViewInstanceInfo.properties'),
-  loadConfigs = Em.isNone(properties);
-  this.getClusterName(loadConfigs);
+  initialValuesToLoad = this.get('initialValuesToLoad');
+if (Em.isEmpty(properties)) {
+  this.getClusterName();
+}
+else {
+  initialValuesToLoad.setProperties({
+ambariAddress: location.protocol + // + document.location.host,
+hdfsAddress: properties['hdfs.address'],
+yarnResourceManager: properties['yarn.resourcemanager.address'],
+yarnResourceManagerScheduler: 
properties['yarn.resourcemanager.scheduler.address'],
+

[16/29] git commit: AMBARI-7340. Webhcat and hcat services are shown in 2.0 stack as separate (aonishuk)

2014-09-17 Thread jonathanhurley
AMBARI-7340. Webhcat and hcat services are shown in 2.0 stack as separate 
(aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: db62322f4b16be65ea59577e43a3740c5b408199
Parents: 246ae72
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Tue Sep 16 21:39:20 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Tue Sep 16 21:39:20 2014 +0300

--
 .../stacks/HDP/2.0/role_command_order.json  |  2 +-
 .../stacks/HDP/2.0/services/HIVE/metainfo.xml   |  4 ---
 .../HDP/2.0/services/WEBHCAT/metainfo.xml   | 26 
 3 files changed, 1 insertion(+), 31 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/db62322f/ambari-server/src/main/resources/stacks/HDP/2.0/role_command_order.json
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0/role_command_order.json 
b/ambari-server/src/main/resources/stacks/HDP/2.0/role_command_order.json
index e90617e..9c5db5c 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0/role_command_order.json
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0/role_command_order.json
@@ -23,7 +23,7 @@
 OOZIE_SERVICE_CHECK-SERVICE_CHECK: [OOZIE_SERVER-START, 
MAPREDUCE2_SERVICE_CHECK-SERVICE_CHECK],
 WEBHCAT_SERVICE_CHECK-SERVICE_CHECK: [WEBHCAT_SERVER-START],
 HBASE_SERVICE_CHECK-SERVICE_CHECK: [HBASE_MASTER-START, 
HBASE_REGIONSERVER-START],
-HIVE_SERVICE_CHECK-SERVICE_CHECK: [HIVE_SERVER-START, 
HIVE_METASTORE-START],
+HIVE_SERVICE_CHECK-SERVICE_CHECK: [HIVE_SERVER-START, 
HIVE_METASTORE-START, WEBHCAT_SERVER-START],
 HCAT_SERVICE_CHECK-SERVICE_CHECK: [HIVE_SERVER-START],
 PIG_SERVICE_CHECK-SERVICE_CHECK: [RESOURCEMANAGER-START, 
NODEMANAGER-START],
 SQOOP_SERVICE_CHECK-SERVICE_CHECK: [RESOURCEMANAGER-START, 
NODEMANAGER-START],

http://git-wip-us.apache.org/repos/asf/ambari/blob/db62322f/ambari-server/src/main/resources/stacks/HDP/2.0/services/HIVE/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0/services/HIVE/metainfo.xml 
b/ambari-server/src/main/resources/stacks/HDP/2.0/services/HIVE/metainfo.xml
index bed0ee4..b24dada 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0/services/HIVE/metainfo.xml
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0/services/HIVE/metainfo.xml
@@ -22,9 +22,5 @@
   nameHIVE/name
   version0.12.0.2.0/version
 /service
-service
-  nameHCATALOG/name
-  version0.12.0.2.0/version
-/service
   /services
 /metainfo

http://git-wip-us.apache.org/repos/asf/ambari/blob/db62322f/ambari-server/src/main/resources/stacks/HDP/2.0/services/WEBHCAT/metainfo.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0/services/WEBHCAT/metainfo.xml 
b/ambari-server/src/main/resources/stacks/HDP/2.0/services/WEBHCAT/metainfo.xml
deleted file mode 100644
index 89c52c0..000
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0/services/WEBHCAT/metainfo.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-?xml version=1.0?
-!--
-   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.
---
-metainfo
-  schemaVersion2.0/schemaVersion
-  services
-service
-  nameWEBHCAT/name
-  version0.12.0.2.0/version
-/service
-  /services
-/metainfo



[09/29] git commit: AMBARI-7335. Remove ambari-common/src/main/python/ambari_jinja2/ext/jinja.el from Ambari. (aonishuk)

2014-09-17 Thread jonathanhurley
AMBARI-7335. Remove ambari-common/src/main/python/ambari_jinja2/ext/jinja.el 
from Ambari. (aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: ef6ecf86c4fe7ca6246a567f6390cb189ae733ed
Parents: 2ab5bad
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Tue Sep 16 18:56:06 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Tue Sep 16 18:56:06 2014 +0300

--
 .../src/main/python/ambari_jinja2/ext/jinja.el  | 213 ---
 1 file changed, 213 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/ef6ecf86/ambari-common/src/main/python/ambari_jinja2/ext/jinja.el
--
diff --git a/ambari-common/src/main/python/ambari_jinja2/ext/jinja.el 
b/ambari-common/src/main/python/ambari_jinja2/ext/jinja.el
deleted file mode 100644
index da4800a..000
--- a/ambari-common/src/main/python/ambari_jinja2/ext/jinja.el
+++ /dev/null
@@ -1,213 +0,0 @@
-;;; jinja.el --- Jinja mode highlighting
-;;
-;; Author: Georg Brandl
-;; Copyright: (c) 2009 by the Jinja Team
-;; Last modified: 2008-05-22 23:04 by gbr
-;;
-;;
-;;
-;;; Commentary:
-;;
-;; Mostly ripped off django-mode by Lennart Borgman.
-;;
-;;
-;;
-;; This program is free software; you can redistribute it and/or
-;; modify it under the terms of the GNU General Public License as
-;; published by the Free Software Foundation; either version 2, or
-;; (at your option) any later version.
-;;
-;; This program is distributed in the hope that it will be useful,
-;; but WITHOUT ANY WARRANTY; without even the implied warranty of
-;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-;; General Public License for more details.
-;;
-;; You should have received a copy of the GNU General Public License
-;; along with this program; see the file COPYING.  If not, write to
-;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-;; Floor, Boston, MA 02110-1301, USA.
-;;
-;;
-;;
-;;; Code:
-
-(defconst jinja-font-lock-keywords
-  (list
-;   (cons (rx {% comment %} (submatch (0+ anything))
-; {% endcomment %}) (list 1 font-lock-comment-face))
-   '({# ?\\(.*?\\) ?#} . (1 font-lock-comment-face))
-   '({%-?\\|-?%}\\|{{\\|}} . font-lock-preprocessor-face)
-   '({#\\|#} . font-lock-comment-delimiter-face)
-   ;; first word in a block is a command
-   '({%-?[ \t\n]*\\([a-zA-Z_]+\\) . (1 font-lock-keyword-face))
-   ;; variables
-   '(\\({{ ?\\)\\([^|]*?\\)\\(|.*?\\)? ?}} . (1 
font-lock-variable-name-face))
-   ;; keywords and builtins
-   (cons (rx word-start
- (or in as recursive not and or if else
- import with without context)
- word-end)
- font-lock-keyword-face)
-   (cons (rx word-start
- (or true false none loop self super)
- word-end)
- font-lock-builtin-face)
-   ;; tests
-   '(\\(is\\)[ \t]*\\(not\\)[ \t]*\\([a-zA-Z_]+\\)
- (1 font-lock-keyword-face) (2 font-lock-keyword-face)
- (3 font-lock-function-name-face))
-   ;; builtin filters
-   (cons (rx
-  | (* space)
-  (submatch
-   (or abs batch capitalize capture center count default
-   dformat dictsort e escape filesizeformat first
-   float format getattribute getitem groupby indent
-   int join jsonencode last length lower markdown
-   pprint random replace reverse round rst slice
-   sort string striptags sum textile title trim
-   truncate upper urlencode urlize wordcount wordwrap
-   xmlattr)))
- (list 1 font-lock-builtin-face))
-   )
-   Minimal highlighting expressions for Jinja mode)
-
-(define-derived-mode jinja-mode nil Jinja
-  Simple Jinja mode for use with `mumamo-mode'.
-This mode only provides syntax highlighting.
-  ;;(set (make-local-variable 'comment-start) {#)
-  ;;(set (make-local-variable 'comment-end)   #})
-  (setq font-lock-defaults '(jinja-font-lock-keywords)))
-
-;; mumamo stuff
-
-(when (require 'mumamo nil t)
-
-  (defun mumamo-chunk-jinja3(pos min max)
-Find {# ... #}.  Return range and `jinja-mode'.
-See `mumamo-find-possible-chunk' for POS, MIN and MAX.
-(mumamo-find-possible-chunk pos min max
-'mumamo-search-bw-exc-start-jinja3
-'mumamo-search-bw-exc-end-jinja3
-  

[20/29] git commit: AMBARI-7342. Slider View: Action dialogs do not look the same as Ambari dialogs (alexantonenko)

2014-09-17 Thread jonathanhurley
AMBARI-7342. Slider View: Action dialogs do not look the same as Ambari dialogs 
(alexantonenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: e24eb5bc1c08b156fad8e3c202520dd5ca11b390
Parents: b1336f3
Author: Alex Antonenko hiv...@gmail.com
Authored: Tue Sep 16 21:49:20 2014 +0300
Committer: Alex Antonenko hiv...@gmail.com
Committed: Tue Sep 16 22:15:58 2014 +0300

--
 .../ui/app/controllers/slider_app_controller.js | 15 ++-
 .../resources/ui/app/styles/application.less| 99 
 2 files changed, 109 insertions(+), 5 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e24eb5bc/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
index e78a1b3..6558e87 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
@@ -319,12 +319,17 @@ App.SliderAppController = Ember.ObjectController.extend({
 openModal: function(option) {
   this.set('currentAction', option.action);
   if (option.confirm) {
-Bootstrap.ModalManager.confirm(
-  this,
+Bootstrap.ModalManager.open(
+  confirm-modal,
   Ember.I18n.t('common.confirmation'),
-  Ember.I18n.t('question.sure'),
-  Ember.I18n.t('yes'),
-  Ember.I18n.t('no')
+  Ember.View.extend({
+template: Ember.Handlebars.compile('{{t question.sure}}')
+  }),
+  [
+Ember.Object.create({title: Em.I18n.t('common.cancel'), 
clicked:modalCanceled, dismiss: 'modal'}),
+Ember.Object.create({title: Em.I18n.t('ok'), 
clicked:modalConfirmed, type:'success'})
+  ],
+  this
 );
   }
   else {

http://git-wip-us.apache.org/repos/asf/ambari/blob/e24eb5bc/contrib/views/slider/src/main/resources/ui/app/styles/application.less
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/styles/application.less 
b/contrib/views/slider/src/main/resources/ui/app/styles/application.less
index 241a52d..90f10d7 100644
--- a/contrib/views/slider/src/main/resources/ui/app/styles/application.less
+++ b/contrib/views/slider/src/main/resources/ui/app/styles/application.less
@@ -753,4 +753,103 @@ a {
   .row {
 .table-row();
   }
+}
+
+.modal-header {
+  padding: 9px 15px;
+  border-bottom: 1px solid #eee;
+}
+.modal-title {
+  line-height: 30px;
+  font-size: 24px;
+  font-family: inherit;
+  font-weight: bold;
+  color: inherit;
+  text-rendering: optimizelegibility;
+}
+.modal-body{
+  padding: 15px;
+}
+.modal-footer {
+  margin-top: 0px;
+  padding: 14px 15px 15px;
+  margin-bottom: 0;
+  text-align: right;
+  background-color: #f5f5f5;
+  border-top: 1px solid #ddd;
+  -webkit-border-radius: 0 0 6px 6px;
+  -moz-border-radius: 0 0 6px 6px;
+  border-radius: 0 0 6px 6px;
+  -webkit-box-shadow: inset 0 1px 0 #ff;
+  -moz-box-shadow: inset 0 1px 0 #ff;
+  box-shadow: inset 0 1px 0 #ff;
+
+  .btn{
+display: inline-block;
+padding: 4px 14px;
+margin-bottom: 0;
+font-size: 14px;
+line-height: 20px;
+color: #33;
+text-align: center;
+text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75);
+vertical-align: middle;
+cursor: pointer;
+background-color: #f5f5f5;
+background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ff), 
to(#e6e6e6));
+background-image: -webkit-linear-gradient(top, #ff, #e6e6e6);
+background-image: -o-linear-gradient(top, #ff, #e6e6e6);
+background-image: linear-gradient(to bottom, #ff, #e6e6e6);
+background-image: -moz-linear-gradient(top, #ff, #e6e6e6);
+background-repeat: repeat-x;
+border: 1px solid #bb;
+border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
+border-color: #e6e6e6 #e6e6e6 #bfbfbf;
+border-bottom-color: #a2a2a2;
+-webkit-border-radius: 4px;
+-moz-border-radius: 4px;
+border-radius: 4px;
+filter: progid:dximagetransform.microsoft.gradient(enabled=false);
+-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px 
rgba(0, 0, 0, 0.05);
+-moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 
0, 0, 0.05);
+

[02/29] git commit: AMBARI-7330. Add HiveServer2 dynamic service discovery configs to Ambari (aonishuk)

2014-09-17 Thread jonathanhurley
AMBARI-7330. Add HiveServer2 dynamic service discovery configs to Ambari 
(aonishuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: a8fb52f33c3137313b8651590b828e1cad3da7ff
Parents: f8aa99b
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Tue Sep 16 16:48:03 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Tue Sep 16 16:48:03 2014 +0300

--
 .../services/HIVE/configuration/hive-site.xml| 19 +++
 .../services/HIVE/configuration/hive-site.xml| 19 +++
 .../services/HIVE/configuration/hive-site.xml| 19 +++
 .../services/HIVE/configuration/hive-site.xml| 19 +++
 ambari-web/app/data/HDP2/site_properties.js  |  9 +
 ambari-web/app/data/site_properties.js   |  9 +
 6 files changed, 94 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/a8fb52f3/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/configuration/hive-site.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/configuration/hive-site.xml
 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/configuration/hive-site.xml
index 8206a6a..524a27b 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/configuration/hive-site.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/configuration/hive-site.xml
@@ -257,4 +257,23 @@ limitations under the License.
 /description
   /property
 
+  property
+namehive.server2.support.dynamic.service.discovery/name
+valuefalse/value
+descriptionWhether HiveServer2 supports dynamic service discovery for its
+  clients. To support this, each instance of HiveServer2 currently uses
+  ZooKeeper to register itself, when it is brought up. JDBC/ODBC clients
+  should use the ZooKeeper ensemble: hive.zookeeper.quorum in their
+  connection string.
+/description
+  /property
+
+  property
+namehive.server2.zookeeper.namespace/name
+valuehiveserver2/value
+descriptionThe parent node in ZooKeeper used by HiveServer2 when
+  supporting dynamic service discovery.
+/description
+  /property
+
 /configuration

http://git-wip-us.apache.org/repos/asf/ambari/blob/a8fb52f3/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/configuration/hive-site.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/configuration/hive-site.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/configuration/hive-site.xml
index 9057fbe..e64e6a0 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/configuration/hive-site.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/configuration/hive-site.xml
@@ -309,4 +309,23 @@ limitations under the License.
 /description
   /property
 
+  property
+namehive.server2.support.dynamic.service.discovery/name
+valuefalse/value
+descriptionWhether HiveServer2 supports dynamic service discovery for its
+  clients. To support this, each instance of HiveServer2 currently uses
+  ZooKeeper to register itself, when it is brought up. JDBC/ODBC clients
+  should use the ZooKeeper ensemble: hive.zookeeper.quorum in their
+  connection string.
+/description
+  /property
+
+  property
+namehive.server2.zookeeper.namespace/name
+valuehiveserver2/value
+descriptionThe parent node in ZooKeeper used by HiveServer2 when
+  supporting dynamic service discovery.
+/description
+  /property
+
 /configuration

http://git-wip-us.apache.org/repos/asf/ambari/blob/a8fb52f3/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/HIVE/configuration/hive-site.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/HIVE/configuration/hive-site.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/HIVE/configuration/hive-site.xml
index 8b4f065..ad1df07 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/HIVE/configuration/hive-site.xml
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/HIVE/configuration/hive-site.xml
@@ -480,4 +480,23 @@ limitations under the License.
 /description
   /property
 
+  property
+namehive.server2.support.dynamic.service.discovery/name

[24/29] git commit: AMBARI-7351. Slider View: Flex API call throws 400-Bad Request (srimanth)

2014-09-17 Thread jonathanhurley
AMBARI-7351. Slider View: Flex API call throws 400-Bad Request (srimanth)


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

Branch: refs/heads/branch-alerts-dev
Commit: cae2fc4d5bdf2ea1234191e9e9cdd8d4eb299825
Parents: 1953346
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Tue Sep 16 19:41:47 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Tue Sep 16 19:41:54 2014 -0700

--
 .../view/slider/SliderAppsViewController.java   |  4 ++
 .../slider/SliderAppsViewControllerImpl.java| 44 +---
 .../view/slider/rest/SliderAppsResource.java| 21 +-
 .../ambari/view/slider/rest/client/Metric.java  |  9 +++-
 4 files changed, 69 insertions(+), 9 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/cae2fc4d/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewController.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewController.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewController.java
index 93c63f2..64ab78c 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewController.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewController.java
@@ -20,6 +20,7 @@ package org.apache.ambari.view.slider;
 
 import java.io.IOException;
 import java.util.List;
+import java.util.Map;
 import java.util.Set;
 
 import org.apache.hadoop.yarn.exceptions.YarnException;
@@ -90,4 +91,7 @@ public interface SliderAppsViewController {
 
   public void thawApp(String appId) throws YarnException, IOException,
   InterruptedException;
+
+  public void flexApp(String appId, MapString, Integer componentsMap)
+  throws YarnException, IOException, InterruptedException;
 }

http://git-wip-us.apache.org/repos/asf/ambari/blob/cae2fc4d/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
index f3c3087..5d6c368 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
@@ -26,7 +26,6 @@ import java.io.InputStream;
 import java.lang.reflect.Field;
 import java.security.PrivilegedExceptionAction;
 import java.util.ArrayList;
-import java.util.Arrays;
 import java.util.Collections;
 import java.util.HashMap;
 import java.util.HashSet;
@@ -44,7 +43,6 @@ import org.apache.commons.io.IOUtils;
 import org.apache.commons.io.filefilter.RegexFileFilter;
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FileSystem;
-import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.hdfs.HdfsConfiguration;
 import org.apache.hadoop.security.UserGroupInformation;
 import org.apache.hadoop.yarn.api.records.ApplicationId;
@@ -58,6 +56,7 @@ import org.apache.slider.api.ClusterDescription;
 import org.apache.slider.client.SliderClient;
 import org.apache.slider.common.SliderKeys;
 import org.apache.slider.common.params.ActionCreateArgs;
+import org.apache.slider.common.params.ActionFlexArgs;
 import org.apache.slider.common.params.ActionFreezeArgs;
 import org.apache.slider.common.params.ActionInstallPackageArgs;
 import org.apache.slider.common.params.ActionThawArgs;
@@ -250,10 +249,12 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
 ListSliderAppType appTypes = getSliderAppTypes(null);
 if (appTypes != null  appTypes.size()  0) {
   for (SliderAppType appType : appTypes) {
-logger.info(TYPE:  + appType.getTypeName() +
-+ app.getType());
-logger.info(VERSION:  + appType.getTypeVersion() +
-+ app.getAppVersion());
+if (logger.isDebugEnabled()) {
+  logger.debug(TYPE:  + appType.getTypeName() +
+  + app.getType());
+  logger.debug(VERSION:  + appType.getTypeVersion() +   
 
+  + app.getAppVersion());
+}
 if ((appType.getTypeName() != null  

[21/29] git commit: AMBARI-7343. Slider View: Flex app action should not have a confirmation dialog (alexantonenko)

2014-09-17 Thread jonathanhurley
AMBARI-7343. Slider View: Flex app action should not have a confirmation dialog 
(alexantonenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: fe890e9a98d3a2899ede69e07b61592b006a1503
Parents: e24eb5b
Author: Alex Antonenko hiv...@gmail.com
Authored: Tue Sep 16 22:14:35 2014 +0300
Committer: Alex Antonenko hiv...@gmail.com
Committed: Tue Sep 16 22:16:00 2014 +0300

--
 .../src/main/resources/ui/app/controllers/slider_app_controller.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/fe890e9a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
index 6558e87..2779a57 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_app_controller.js
@@ -46,7 +46,7 @@ App.SliderAppController = Ember.ObjectController.extend({
   actions.push({
 title: 'Flex',
 action: 'flex',
-confirm: true
+confirm: false
   });
 }
 if ('FROZEN' === status) {



[07/29] git commit: AMBARI-7306. Can't save notes for config groups. (mpapirkovskyy)

2014-09-17 Thread jonathanhurley
AMBARI-7306. Can't save notes for config groups. (mpapirkovskyy)


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

Branch: refs/heads/branch-alerts-dev
Commit: 56e022e554f6775c2bce683cb28d28b5744eec07
Parents: 6457726
Author: Myroslav Papirkovskyy mpapyrkovs...@hortonworks.com
Authored: Mon Sep 15 19:33:02 2014 +0300
Committer: Myroslav Papirkovskyy mpapyrkovs...@hortonworks.com
Committed: Tue Sep 16 18:07:16 2014 +0300

--
 .../internal/ConfigGroupResourceProvider.java   | 20 ++--
 1 file changed, 18 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/56e022e5/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ConfigGroupResourceProvider.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ConfigGroupResourceProvider.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ConfigGroupResourceProvider.java
index 6e13d9c..46e9016 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ConfigGroupResourceProvider.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ConfigGroupResourceProvider.java
@@ -211,6 +211,20 @@ public class ConfigGroupResourceProvider extends
 return getRequestStatus(null);
   }
 
+  @Override
+  public SetString checkPropertyIds(SetString propertyIds) {
+//allow providing service_config_version_note, but we should not return it 
for config group
+SetString unsupportedPropertyIds = super.checkPropertyIds(propertyIds);
+for (IteratorString iterator = unsupportedPropertyIds.iterator(); 
iterator.hasNext(); ) {
+  String next = iterator.next();
+  next = PropertyHelper.getPropertyName(next);
+  if (next.equals(service_config_version_note) || 
next.equals(/service_config_version_note)) {
+iterator.remove();
+  }
+}
+return unsupportedPropertyIds;
+  }
+
   /**
* Create configuration group resources based on set of config group 
requests.
*
@@ -477,7 +491,8 @@ public class ConfigGroupResourceProvider extends
   configGroup.persist();
   cluster.addConfigGroup(configGroup);
   if (serviceName != null) {
-cluster.createServiceConfigVersion(serviceName, 
getManagementController().getAuthName(), null, configGroup);
+cluster.createServiceConfigVersion(serviceName, 
getManagementController().getAuthName(),
+  request.getServiceConfigVersionNote(), configGroup);
   } else {
 LOG.warn(Could not determine service name for config group {}, 
service config version not created,
 configGroup.getId());
@@ -569,7 +584,8 @@ public class ConfigGroupResourceProvider extends
 
   configGroup.persist();
   if (serviceName != null) {
-cluster.createServiceConfigVersion(serviceName, 
getManagementController().getAuthName(), null, configGroup);
+cluster.createServiceConfigVersion(serviceName, 
getManagementController().getAuthName(),
+  request.getServiceConfigVersionNote(), configGroup);
   } else {
 LOG.warn(Could not determine service name for config group {}, 
service config version not created,
 configGroup.getId());



[05/29] git commit: AMBARI-7281. Slider View: App summary details shown differently than Ambari service summary. (onechiporenko)

2014-09-17 Thread jonathanhurley
AMBARI-7281. Slider View: App summary details shown differently than Ambari 
service summary. (onechiporenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: 460ae9ed3026b0a6c9ec1ce0cb42394afe028087
Parents: 6457726
Author: Oleg Nechiporenko onechipore...@apache.org
Authored: Tue Sep 16 13:10:14 2014 +0300
Committer: Oleg Nechiporenko onechipore...@apache.org
Committed: Tue Sep 16 17:37:40 2014 +0300

--
 .../resources/ui/app/models/slider_app_component.js | 10 +-
 .../src/main/resources/ui/app/styles/application.less   | 12 
 .../resources/ui/app/templates/slider_app/summary.hbs   |  2 +-
 3 files changed, 22 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/460ae9ed/contrib/views/slider/src/main/resources/ui/app/models/slider_app_component.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/models/slider_app_component.js 
b/contrib/views/slider/src/main/resources/ui/app/models/slider_app_component.js
index 8f4f584..2e999c1 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/models/slider_app_component.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/models/slider_app_component.js
@@ -36,7 +36,15 @@ App.SliderAppComponent = DS.Model.extend({
   /**
* @type {App.SliderApp}
*/
-  appId: DS.belongsTo('sliderApp')
+  appId: DS.belongsTo('sliderApp'),
+
+  /**
+   * Is component running (used in the templates)
+   * @type {bool}
+   */
+  isRunning: function() {
+return this.get('status') === 'Running';
+  }.property('status')
 
 });
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/460ae9ed/contrib/views/slider/src/main/resources/ui/app/styles/application.less
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/styles/application.less 
b/contrib/views/slider/src/main/resources/ui/app/styles/application.less
index b934a20..33f 100644
--- a/contrib/views/slider/src/main/resources/ui/app/styles/application.less
+++ b/contrib/views/slider/src/main/resources/ui/app/styles/application.less
@@ -555,6 +555,18 @@ a {
   text-align: right;
 }
   }
+  .panel-components {
+.status {
+  display: inline-block;
+  width: 25px;
+}
+.icon-ok-sign {
+  color: #5ab400;
+}
+.icon-warning-sign {
+  color: #ff;
+}
+  }
   .panel-link {
 margin-top: -5px;
 margin-right: -7px;

http://git-wip-us.apache.org/repos/asf/ambari/blob/460ae9ed/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
 
b/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
index 5cb2cd1..68d47b4 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
+++ 
b/contrib/views/slider/src/main/resources/ui/app/templates/slider_app/summary.hbs
@@ -58,7 +58,7 @@
 tbody
   {{#each controller.model.components}}
   tr
-td{{componentName}}/td
+tdspan {{bind-attr 
class=isRunning:icon-ok-sign:icon-warning-sign :status}}/span 
{{componentName}}/td
 td{{host}}/td
   /tr
   {{/each}}



[13/29] git commit: AMBARI-7309 UI should issue separate requests for starting service and disabling MM. (ababiichuk)

2014-09-17 Thread jonathanhurley
AMBARI-7309 UI should issue separate requests for starting service and 
disabling MM. (ababiichuk)


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

Branch: refs/heads/branch-alerts-dev
Commit: 34ffd774c4c05ce98881f920e4b40af9b89a887f
Parents: f53e654
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Mon Sep 15 17:18:40 2014 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Tue Sep 16 20:49:01 2014 +0300

--
 ambari-web/app/controllers/main/service/item.js | 36 +---
 .../app/utils/batch_scheduled_requests.js   |  2 +-
 2 files changed, 25 insertions(+), 13 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/34ffd774/ambari-web/app/controllers/main/service/item.js
--
diff --git a/ambari-web/app/controllers/main/service/item.js 
b/ambari-web/app/controllers/main/service/item.js
index edb524c..84d833f 100644
--- a/ambari-web/app/controllers/main/service/item.js
+++ b/ambari-web/app/controllers/main/service/item.js
@@ -157,20 +157,34 @@ App.MainServiceItemController = Em.Controller.extend({
 
 return App.showConfirmationFeedBackPopup(function(query, runMmOperation) {
   self.set('isPending', true);
-  self.startStopPopupPrimary(serviceHealth, query, runMmOperation);
+  self.startStopWithMmode(serviceHealth, query, runMmOperation);
 }, bodyMessage);
   },
 
-  startStopPopupPrimary: function (serviceHealth, query, runMmOperation) {
-var requestInfo = ;
-var turnOnMM = ON;
-if (serviceHealth == STARTED) {
-  turnOnMM = OFF;
-  requestInfo = 
App.BackgroundOperationsController.CommandContexts.START_SERVICE.format(this.get('content.serviceName'));
+
+  startStopWithMmode: function(serviceHealth, query, runMmOperation) {
+var self = this;
+if (runMmOperation) {
+  if (serviceHealth == STARTED) {
+this.startStopPopupPrimary(serviceHealth, query).complete(function() {
+  batchUtils.turnOnOffPassiveRequest(OFF, 
Em.I18n.t('passiveState.turnOff'), 
self.get('content.serviceName').toUpperCase());
+});
+  } else {
+batchUtils.turnOnOffPassiveRequest(ON, 
Em.I18n.t('passiveState.turnOn'), 
this.get('content.serviceName').toUpperCase()).complete(function() {
+  self.startStopPopupPrimary(serviceHealth, query);
+})
+  }
 } else {
-  requestInfo = 
App.BackgroundOperationsController.CommandContexts.STOP_SERVICE.format(this.get('content.serviceName'));
+  this.startStopPopupPrimary(serviceHealth, query);
 }
 
+  },
+
+  startStopPopupPrimary: function (serviceHealth, query) {
+var requestInfo = (serviceHealth == STARTED)
+? 
App.BackgroundOperationsController.CommandContexts.START_SERVICE.format(this.get('content.serviceName'))
+: 
App.BackgroundOperationsController.CommandContexts.STOP_SERVICE.format(this.get('content.serviceName'));
+
 var data = {
   'context': requestInfo,
   'serviceName': this.get('content.serviceName').toUpperCase(),
@@ -179,10 +193,8 @@ App.MainServiceItemController = Em.Controller.extend({
   },
   'query': query
 };
-if (runMmOperation) {
-  data.ServiceInfo.maintenance_state = turnOnMM;
-}
-App.ajax.send({
+
+return App.ajax.send({
   'name': 'common.service.update',
   'sender': this,
   'success': 'startStopPopupSuccessCallback',

http://git-wip-us.apache.org/repos/asf/ambari/blob/34ffd774/ambari-web/app/utils/batch_scheduled_requests.js
--
diff --git a/ambari-web/app/utils/batch_scheduled_requests.js 
b/ambari-web/app/utils/batch_scheduled_requests.js
index 1ee7c70..52bf0d8 100644
--- a/ambari-web/app/utils/batch_scheduled_requests.js
+++ b/ambari-web/app/utils/batch_scheduled_requests.js
@@ -266,7 +266,7 @@ module.exports = {
   },
 
   turnOnOffPassiveRequest: function(state, message, serviceName, callback) {
-App.ajax.send({
+return App.ajax.send({
   'name': 'common.service.passive',
   'sender': {
 'successCallback': callback || defaultSuccessCallback,



[27/29] git commit: AMBARI-7358 Configs: compare between host config group versions shows other props. (atkach)

2014-09-17 Thread jonathanhurley
AMBARI-7358 Configs: compare between host config group versions shows other 
props. (atkach)


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

Branch: refs/heads/branch-alerts-dev
Commit: 0fb11d23e7c312aa34140ab7ecf3db5826a5e7ab
Parents: f63dd8a
Author: atkach atk...@hortonworks.com
Authored: Wed Sep 17 15:10:27 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Wed Sep 17 15:10:27 2014 +0300

--
 .../controllers/main/service/info/configs.js| 237 +--
 ambari-web/app/models/service_config.js |   1 +
 .../common/configs/compare_property.hbs |  30 +--
 .../common/configs/service_config_category.hbs  |   6 +-
 4 files changed, 192 insertions(+), 82 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/0fb11d23/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 9fcdaaa..4411667 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -185,7 +185,7 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
* @return {Boolean}
*/
   isVersionDefault: function(version) {
-return version  version.get('groupId') == -1;
+return (App.ServiceConfigVersion.find(this.get('content.serviceName') + 
_ + version).get('groupId') == -1);
   },
 
   /**
@@ -324,12 +324,11 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
 var self = this;
 this.set('versionLoaded', false);
 version = version || this.get('currentDefaultVersion');
-var versionRecord = 
App.ServiceConfigVersion.find(this.get('content.serviceName') + _ + version);
 //version of non-default group require properties from current version of 
default group to correctly display page
-var versions = (this.isVersionDefault(versionRecord)) ? [version] : 
[this.get('currentDefaultVersion'), version];
+var versions = (this.isVersionDefault(version)) ? [version] : 
[this.get('currentDefaultVersion'), version];
 
 //if version from default group selected then switch to default group
-if (self.get('dataIsLoaded')  this.isVersionDefault(versionRecord)) {
+if (self.get('dataIsLoaded')  this.isVersionDefault(version)) {
   this.set('selectedConfigGroup', 
this.get('configGroups').findProperty('isDefault'));
 }
 
@@ -569,10 +568,16 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   loadCompareVersionConfigs: function (allConfigs) {
 var dfd = $.Deferred();
 var self = this;
-var compareServiceVersion = this.get('compareServiceVersion');
+var compareServiceVersions = [];
 
-if (compareServiceVersion) {
-  this.getCompareVersionConfigs(compareServiceVersion).done(function 
(json) {
+if (this.get('compareServiceVersion')) {
+  if 
(!this.isVersionDefault(this.get('compareServiceVersion').get('version'))) {
+compareServiceVersions = 
[this.get('compareServiceVersion').get('version'), this.get('selectedVersion')];
+  } else {
+compareServiceVersions = 
[this.get('compareServiceVersion').get('version')];
+  }
+
+  this.getCompareVersionConfigs(compareServiceVersions).done(function 
(json) {
 self.initCompareConfig(allConfigs, json);
 self.set('compareServiceVersion', null);
 self.set('isCompareMode', true);
@@ -597,76 +602,173 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   initCompareConfig: function(allConfigs, json) {
 var serviceVersionMap = {};
 var configNamesMap = {};
-var serviceName = json.items[0].service_name;
-var compareServiceVersion = this.get('compareServiceVersion');
+var serviceName = this.get('content.serviceName');
+var compareVersionNumber = 
this.get('compareServiceVersion').get('version');
+//indicate whether compared versions are from non-default group
+var compareNonDefaultVersions = (json.items.length  1);
 
+serviceVersionMap[compareVersionNumber] = {};
+if (compareNonDefaultVersions) {
+  serviceVersionMap[this.get('selectedVersion')] = {};
+}
 allConfigs.mapProperty('name').forEach(function(name) {
   configNamesMap[name] = true;
 });
 
-json.items[0].configurations.forEach(function (configuration) {
-  if (serviceName == 'YARN'  configuration.type == 'capacity-scheduler') 
{
-// put all properties in a single 

[12/29] git commit: AMBARI-7322. Admin View: update landing page content.(xiwang)

2014-09-17 Thread jonathanhurley
AMBARI-7322. Admin View: update landing page content.(xiwang)


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

Branch: refs/heads/branch-alerts-dev
Commit: 4770717db7e11d904aa59c7acbdaead2060720d4
Parents: f92c28e
Author: Xi Wang xiw...@apache.org
Authored: Mon Sep 15 18:18:55 2014 -0700
Committer: Xi Wang xiw...@apache.org
Committed: Tue Sep 16 10:43:02 2014 -0700

--
 .../app/scripts/controllers/mainCtrl.js | 13 +-
 .../resources/ui/admin-web/app/styles/main.css  | 42 +++-
 .../resources/ui/admin-web/app/views/main.html  | 41 ++-
 3 files changed, 92 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/4770717d/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/mainCtrl.js
--
diff --git 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/mainCtrl.js
 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/mainCtrl.js
index 6f68831..797ecb2 100644
--- 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/mainCtrl.js
+++ 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/mainCtrl.js
@@ -18,7 +18,7 @@
 'use strict';
 
 angular.module('ambariAdminConsole')
-.controller('MainCtrl',['$scope', 'Auth', 'uiAlert', '$modal', 
function($scope, Auth, uiAlert, $modal) {
+.controller('MainCtrl',['$scope', 'Auth', 'uiAlert', '$modal', 'Cluster', 
function($scope, Auth, uiAlert, $modal, Cluster) {
   $scope.signOut = function() {
 Auth.signout().then(function() {
  window.location.pathname = ''; // Change location hard, because Angular 
works only with relative urls
@@ -39,4 +39,15 @@ angular.module('ambariAdminConsole')
   };
 
   $scope.currentUser = Auth.getCurrentUser();
+
+  $scope.cluster = null;
+  $scope.isLoaded = null;
+
+  Cluster.getStatus().then(function(cluster) {
+$scope.cluster = cluster;
+$scope.isLoaded = true;
+  }).catch(function(data) {
+  uiAlert.danger(data.status, data.message);
+  });
+
 }]);

http://git-wip-us.apache.org/repos/asf/ambari/blob/4770717d/ambari-admin/src/main/resources/ui/admin-web/app/styles/main.css
--
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/styles/main.css 
b/ambari-admin/src/main/resources/ui/admin-web/app/styles/main.css
index 3d5628a..9b41f63 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/styles/main.css
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/styles/main.css
@@ -211,12 +211,49 @@
 }
 .mainpage .panel-body{
   padding: 20px;
-  height: 560px;
+  height: 620px;
 }
 .mainpage h1{
   font-size: 24px;
   margin-top: 10px;
 }
+.mainpage .panel-body #main-operations-boxes {
+  padding: 10px;
+}
+.mainpage .panel-body #main-operations-boxes .thumbnail{
+  display: block;
+  height: 230px;
+  padding: 8px;
+  background-color: #ee;
+  margin-bottom: 20px;
+  margin-left: 20px;
+  margin-right: 10px;
+  border: none;
+  border-radius: 0px;
+}
+.mainpage .panel-body #main-operations-boxes .thumbnail .title,
+.mainpage .panel-body #main-operations-boxes .thumbnail .description,
+.mainpage .panel-body #main-operations-boxes .thumbnail .buttons {
+  text-align: center;
+  line-height: 1.5;
+}
+.mainpage .panel-body #main-operations-boxes .thumbnail .buttons .btn{
+  width: 200px;
+  margin: 5px;
+}
+.mainpage .panel-body #main-operations-boxes .thumbnail .buttons 
.btn.userslist-button,
+.mainpage .panel-body #main-operations-boxes .thumbnail .buttons 
.btn.groupslist-button {
+  width: 100px;
+}
+.mainpage .panel-body #main-operations-boxes .thumbnail .glyphicon {
+  font-size: 50px;
+  text-align: center;
+  display: block;
+  line-height: 1.5;
+}
+.mainpage .panel-body #main-operations-boxes .col-sm-5 {
+  width: 43.5%;
+}
 
 .views-list-table .panel{
   border-radius: 0;
@@ -488,6 +525,9 @@
   .container{
 width: 1170px;
   }
+  .mainpage .panel-body #main-operations-boxes .col-sm-5 {
+width: 44%;
+  }
 }
 
 ul.nav li  a{

http://git-wip-us.apache.org/repos/asf/ambari/blob/4770717d/ambari-admin/src/main/resources/ui/admin-web/app/views/main.html
--
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/views/main.html 
b/ambari-admin/src/main/resources/ui/admin-web/app/views/main.html
index a66eaf4..7785d2f 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/views/main.html
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/views/main.html
@@ -18,7 +18,44 @@
 div 

[26/29] git commit: AMBARI-7356.When the user completes Install Wizard, mark Clusters.provisioning_state as INSTALLED. (akovalenko)

2014-09-17 Thread jonathanhurley
AMBARI-7356.When the user completes Install Wizard, mark 
Clusters.provisioning_state as INSTALLED. (akovalenko)


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

Branch: refs/heads/branch-alerts-dev
Commit: f63dd8a6eea79defd93837dbfc3011f42692ae91
Parents: e033815
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Wed Sep 17 14:06:44 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Wed Sep 17 14:06:44 2014 +0300

--
 ambari-web/app/controllers/installer.js | 15 +
 ambari-web/app/models/cluster_states.js |  1 -
 ambari-web/app/router.js| 84 
 ambari-web/app/routes/installer.js  | 12 ++--
 ambari-web/app/utils/ajax/ajax.js   | 17 +-
 5 files changed, 84 insertions(+), 45 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f63dd8a6/ambari-web/app/controllers/installer.js
--
diff --git a/ambari-web/app/controllers/installer.js 
b/ambari-web/app/controllers/installer.js
index e45eaee..d933e9a 100644
--- a/ambari-web/app/controllers/installer.js
+++ b/ambari-web/app/controllers/installer.js
@@ -745,6 +745,21 @@ App.InstallerController = App.WizardController.extend({
 App.router.get('applicationController').postUserPref(persists, true);
   },
 
+  /**
+   * Save cluster provisioning state to the server
+   * @param state cluster provisioning state
+   * @param callback is called after request completes
+   */
+  setClusterProvisioningState: function (state, callback) {
+App.ajax.send({
+  name: 'cluster.save_provisioning_state',
+  sender: this,
+  data: {
+state: state
+  }
+}).complete(callback());
+  },
+
   setStepsEnable: function () {
 for (var i = 0; i = this.totalSteps; i++) {
   var step = this.get('isStepDisabled').findProperty('step', i);

http://git-wip-us.apache.org/repos/asf/ambari/blob/f63dd8a6/ambari-web/app/models/cluster_states.js
--
diff --git a/ambari-web/app/models/cluster_states.js 
b/ambari-web/app/models/cluster_states.js
index 49760d6..95c1444 100644
--- a/ambari-web/app/models/cluster_states.js
+++ b/ambari-web/app/models/cluster_states.js
@@ -108,7 +108,6 @@ App.clusterStatus = Em.Object.create(App.UserPref, {
* @method updateFromServer
*/
   updateFromServer: function (overrideLocaldb) {
-// if overrideLocaldb is undefined, set it to true
 this.set('additionalData', {
   user: App.db.getUser(),
   login: App.db.getLoginName(),

http://git-wip-us.apache.org/repos/asf/ambari/blob/f63dd8a6/ambari-web/app/router.js
--
diff --git a/ambari-web/app/router.js b/ambari-web/app/router.js
index 18203f2..bbc06dd 100644
--- a/ambari-web/app/router.js
+++ b/ambari-web/app/router.js
@@ -29,6 +29,12 @@ App.Router = Em.Router.extend({
   enableLogging: true,
   isFwdNavigation: true,
   backBtnForHigherStep: false,
+
+  /**
+   * Is true, if cluster.provisioning_state is equal to 'INSTALLED'
+   * @type {Boolean}
+   */
+  clusterInstallCompleted: false,
   /**
* user prefered path to route
*/
@@ -119,6 +125,9 @@ App.Router = Em.Router.extend({
 
   onAuthenticationSuccess: function (data) {
 this.set('loggedIn', true);
+if (data.items.length) {
+  this.set('clusterInstallCompleted', 
data.items[0].Clusters.provisioning_state === 'INSTALLED');
+}
   },
 
   onAuthenticationError: function (data) {
@@ -265,7 +274,7 @@ App.Router = Em.Router.extend({
   App.usersMapper.map({items: [loginData]});
   router.setUserLoggedIn(params.loginName);
   var permissionList = 
privileges.items.mapProperty('PrivilegeInfo.permission_name');
-  var isAdmin = permissionList.indexOf('AMBARI.ADMIN')  -1;
+  var isAdmin = permissionList.contains('AMBARI.ADMIN');
   var transitionToApp = false;
   if (isAdmin) {
 App.set('isAdmin', true);
@@ -277,14 +286,15 @@ App.Router = Em.Router.extend({
 }
   } else {
 if (clustersData.items.length) {
+  this.set('clusterInstallCompleted', 
clustersData.items[0].Clusters.provisioning_state === 'INSTALLED');
   //TODO: Iterate over clusters
   var clusterName = clustersData.items[0].Clusters.cluster_name;
   var clusterPermissions = 
privileges.items.filterProperty('PrivilegeInfo.cluster_name', 
clusterName).mapProperty('PrivilegeInfo.permission_name');
-  if (clusterPermissions.indexOf('CLUSTER.OPERATE')  -1) {
+  if 

[25/29] git commit: AMBARI-7334. Slider View: Show view name along with hover of view properties - fixes (srimanth)

2014-09-17 Thread jonathanhurley
AMBARI-7334. Slider View: Show view name along with hover of view properties - 
fixes (srimanth)


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

Branch: refs/heads/branch-alerts-dev
Commit: e033815cc723900ef52884439634e5732f7eabc0
Parents: cae2fc4
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Tue Sep 16 22:28:24 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Tue Sep 16 22:28:24 2014 -0700

--
 .../main/resources/ui/app/controllers/slider_controller.js   | 8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/e033815c/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
--
diff --git 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
index 51fd057..5eb323d 100644
--- 
a/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
+++ 
b/contrib/views/slider/src/main/resources/ui/app/controllers/slider_controller.js
@@ -100,10 +100,12 @@ App.SliderController = 
Ember.Controller.extend(App.RunPeriodically, {
   getParametersFromViewPropertiesSuccessCallback: function(data) {
 var properties = Em.get(data, 'ViewInstanceInfo.properties'),
   initialValuesToLoad = this.get('initialValuesToLoad');
-if (Em.isEmpty(properties)) {
+if (properties == null || properties['hdfs.address'] == null
+|| properties['yarn.resourcemanager.address'] == null
+|| properties['yarn.resourcemanager.scheduler.address'] == null
+|| properties['zookeeper.quorum'] == null) {
   this.getClusterName();
-}
-else {
+} else {
   initialValuesToLoad.setProperties({
 ambariAddress: location.protocol + // + document.location.host,
 hdfsAddress: properties['hdfs.address'],



git commit: AMBARI-7318. ClusterHostInfo host indexes should be hostnames in download client configs (dlysnichenko)

2014-09-17 Thread dmitriusan
Repository: ambari
Updated Branches:
  refs/heads/trunk ac290e259 - d6a4a68d0


AMBARI-7318. ClusterHostInfo host indexes should be hostnames in download 
client configs (dlysnichenko)


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

Branch: refs/heads/trunk
Commit: d6a4a68d0fbf0d076b201e4b4d635330dab530b8
Parents: ac290e2
Author: Lisnichenko Dmitro dlysniche...@hortonworks.com
Authored: Wed Sep 17 16:54:31 2014 +0300
Committer: Lisnichenko Dmitro dlysniche...@hortonworks.com
Committed: Wed Sep 17 16:54:31 2014 +0300

--
 .../internal/ClientConfigResourceProvider.java  | 35 ++--
 .../ClientConfigResourceProviderTest.java   | 24 ++
 2 files changed, 49 insertions(+), 10 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/d6a4a68d/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
index 366b5e1..34f4d6f 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
@@ -18,7 +18,6 @@
 package org.apache.ambari.server.controller.internal;
 
 import com.google.gson.Gson;
-import com.google.inject.Inject;
 import com.google.inject.assistedinject.Assisted;
 import com.google.inject.assistedinject.AssistedInject;
 import com.google.inject.persist.Transactional;
@@ -213,6 +212,7 @@ public class ClientConfigResourceProvider extends 
AbstractControllerResourceProv
   clusterHostInfo = 
StageUtils.getClusterHostInfo(managementController.getClusters().getHostsForCluster(cluster.getClusterName()),
 cluster);
   serviceInfo = 
managementController.getAmbariMetaInfo().getServiceInfo(stackId.getStackName(),
   stackId.getStackVersion(), serviceName);
+  clusterHostInfo = substituteHostIndexes(clusterHostInfo);
   osFamily = clusters.getHost(hostName).getOsFamily();
 
   TreeMapString, String hostLevelParams = new TreeMapString, String();
@@ -248,11 +248,11 @@ public class ClientConfigResourceProvider extends 
AbstractControllerResourceProv
   }
   String packageList = gson.toJson(packages);
   hostLevelParams.put(PACKAGE_LIST, packageList);
-  
+
   SetString userSet = 
configHelper.getPropertyValuesWithPropertyType(stackId, PropertyType.USER, 
cluster);
   String userList = gson.toJson(userSet);
   hostLevelParams.put(USER_LIST, userList);
-  
+
   SetString groupSet = 
configHelper.getPropertyValuesWithPropertyType(stackId, PropertyType.GROUP, 
cluster);
   String groupList = gson.toJson(groupSet);
   hostLevelParams.put(GROUP_LIST, groupList);
@@ -324,6 +324,35 @@ public class ClientConfigResourceProvider extends 
AbstractControllerResourceProv
 return resources;
   }
 
+  private static MapString, SetString substituteHostIndexes(MapString, 
SetString clusterHostInfo) throws SystemException {
+SetString keysToSkip = new HashSetString(Arrays.asList(all_hosts, 
all_ping_ports,
+ambari_server_host));
+String[] allHosts = {};
+if (clusterHostInfo.get(all_hosts) != null) {
+  allHosts = clusterHostInfo.get(all_hosts).toArray(new 
String[clusterHostInfo.get(all_hosts).size()]);
+}
+SetString keys = clusterHostInfo.keySet();
+for (String key : keys) {
+  if (keysToSkip.contains(key)) {
+continue;
+  }
+  SetString hosts = new HashSetString();
+  SetString currentHostsIndexes = clusterHostInfo.get(key);
+  if (currentHostsIndexes == null) {
+continue;
+  }
+  for (String hostIndex : currentHostsIndexes) {
+try {
+  hosts.add(allHosts[Integer.parseInt(hostIndex)]);
+} catch (ArrayIndexOutOfBoundsException ex) {
+  throw new SystemException(Failed to fill cluster host info  , ex);
+}
+  }
+  clusterHostInfo.put(key, hosts);
+}
+return clusterHostInfo;
+  }
+
   @Override
   public RequestStatus updateResources(final Request request, Predicate 
predicate)
   throws SystemException, UnsupportedPropertyException, 
NoSuchResourceException, NoSuchParentResourceException {


git commit: AMBARI-7254 - Slider View: Slider view not initializing due to long parameter description

2014-09-17 Thread tbeerbower
Repository: ambari
Updated Branches:
  refs/heads/trunk d6a4a68d0 - c46d4916a


AMBARI-7254 - Slider View: Slider view not initializing due to long parameter 
description


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

Branch: refs/heads/trunk
Commit: c46d4916abc8775d6ad8c6446a6d640005458ac6
Parents: d6a4a68
Author: tbeerbower tbeerbo...@hortonworks.com
Authored: Wed Sep 17 10:41:20 2014 -0400
Committer: tbeerbower tbeerbo...@hortonworks.com
Committed: Wed Sep 17 10:41:20 2014 -0400

--
 .../server/upgrade/UpgradeCatalog170.java   | 22 +++-
 .../main/resources/Ambari-DDL-MySQL-CREATE.sql  |  6 +++---
 .../main/resources/Ambari-DDL-Oracle-CREATE.sql |  6 +++---
 .../resources/Ambari-DDL-Postgres-CREATE.sql|  6 +++---
 .../Ambari-DDL-Postgres-EMBEDDED-CREATE.sql |  6 +++---
 5 files changed, 29 insertions(+), 17 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/c46d4916/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
index a08d794..e58b6d3 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
@@ -197,14 +197,16 @@ public class UpgradeCatalog170 extends 
AbstractUpgradeCatalog {
   String.class, 255, null, true));
 dbAccessor.addColumn(viewmain, new DBColumnInfo(system_view,
 Character.class, 1, null, true));
+dbAccessor.addColumn(viewmain, new DBColumnInfo(resource_type_id,
+Integer.class, 1, 1, false));
+dbAccessor.addColumn(viewmain, new DBColumnInfo(description,
+String.class, 2048, null, true));
 dbAccessor.addColumn(viewparameter, new DBColumnInfo(masked,
   Character.class, 1, null, true));
 dbAccessor.addColumn(users, new DBColumnInfo(active,
   Integer.class, 1, 1, false));
 dbAccessor.addColumn(users, new DBColumnInfo(principal_id,
 Long.class, 1, 1, false));
-dbAccessor.addColumn(viewmain, new DBColumnInfo(resource_type_id,
-Integer.class, 1, 1, false));
 dbAccessor.addColumn(viewinstance, new DBColumnInfo(resource_id,
 Long.class, 1, 1, false));
 dbAccessor.addColumn(viewinstance, new DBColumnInfo(xml_driven,
@@ -223,9 +225,6 @@ public class UpgradeCatalog170 extends 
AbstractUpgradeCatalog {
 dbAccessor.addColumn(host_role_command, new DBColumnInfo(error_log,
 String.class, 255, null, true));
 
-dbAccessor.addColumn(viewmain, new DBColumnInfo(description,
-String.class, 255, null, true));
-
 addAlertingFrameworkDDL();
 
 // Exclusive requests changes
@@ -288,6 +287,19 @@ public class UpgradeCatalog170 extends 
AbstractUpgradeCatalog {
   }
 }
 
+// alter view tables description columns size
+if (dbType.equals(Configuration.ORACLE_DB_NAME) ||
+dbType.equals(Configuration.MYSQL_DB_NAME)) {
+  dbAccessor.executeQuery(ALTER TABLE viewinstance MODIFY description 
VARCHAR(2048));
+  dbAccessor.executeQuery(ALTER TABLE viewparameter MODIFY description 
VARCHAR(2048));
+} else if (Configuration.POSTGRES_DB_NAME.equals(dbType)) {
+  dbAccessor.executeQuery(ALTER TABLE viewinstance ALTER COLUMN 
description TYPE VARCHAR(2048));
+  dbAccessor.executeQuery(ALTER TABLE viewparameter ALTER COLUMN 
description TYPE VARCHAR(2048));
+} else if (dbType.equals(Configuration.DERBY_DB_NAME)) {
+  dbAccessor.executeQuery(ALTER TABLE viewinstance ALTER COLUMN 
description SET DATA TYPE VARCHAR(2048));
+  dbAccessor.executeQuery(ALTER TABLE viewparameter ALTER COLUMN 
description SET DATA TYPE VARCHAR(2048));
+}
+
 //upgrade unit test workaround
 if (Configuration.DERBY_DB_NAME.equals(dbType)) {
   dbAccessor.executeQuery(ALTER TABLE clusterconfig ALTER COLUMN 
config_id DEFAULT 0);

http://git-wip-us.apache.org/repos/asf/ambari/blob/c46d4916/ambari-server/src/main/resources/Ambari-DDL-MySQL-CREATE.sql
--
diff --git a/ambari-server/src/main/resources/Ambari-DDL-MySQL-CREATE.sql 
b/ambari-server/src/main/resources/Ambari-DDL-MySQL-CREATE.sql
index fee90c9..a259870 100644
--- a/ambari-server/src/main/resources/Ambari-DDL-MySQL-CREATE.sql
+++ b/ambari-server/src/main/resources/Ambari-DDL-MySQL-CREATE.sql
@@ -65,11 +65,11 @@ CREATE TABLE hostgroup 

git commit: AMBARI-7363 Recommendations: ui changes for usability. (ababiichuk)

2014-09-17 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk c46d4916a - 4bcf111f1


AMBARI-7363 Recommendations: ui changes for usability. (ababiichuk)


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

Branch: refs/heads/trunk
Commit: 4bcf111f1f8539df666fbe3d9c41609547d4e5b3
Parents: c46d491
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Wed Sep 17 17:33:03 2014 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Wed Sep 17 17:56:20 2014 +0300

--
 .../controllers/main/service/info/configs.js|  5 +++
 .../app/controllers/wizard/step7_controller.js  |  5 +++
 ambari-web/app/messages.js  |  3 +-
 ambari-web/app/mixins/common/serverValidator.js |  1 +
 ambari-web/app/styles/application.less  |  5 +++
 .../configs/config_recommendation_popup.hbs | 35 ++--
 .../wizard/step6/step6_issues_popup.hbs | 44 ++--
 7 files changed, 73 insertions(+), 25 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/4bcf111f/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 4411667..32343ff 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -146,6 +146,11 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
   attributeName: 'isValid',
   attributeValue: false,
   caption: 'common.combobox.dropdown.issues'
+},
+{
+  attributeName: 'warn',
+  attributeValue: true,
+  caption: 'common.combobox.dropdown.warnings'
 }
   ],
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/4bcf111f/ambari-web/app/controllers/wizard/step7_controller.js
--
diff --git a/ambari-web/app/controllers/wizard/step7_controller.js 
b/ambari-web/app/controllers/wizard/step7_controller.js
index 8afc87d..55c83ff 100644
--- a/ambari-web/app/controllers/wizard/step7_controller.js
+++ b/ambari-web/app/controllers/wizard/step7_controller.js
@@ -220,6 +220,11 @@ App.WizardStep7Controller = 
Em.Controller.extend(App.ServerValidatorMixin, {
   attributeName: 'isValid',
   attributeValue: false,
   caption: 'common.combobox.dropdown.issues'
+},
+{
+  attributeName: 'warn',
+  attributeValue: true,
+  caption: 'common.combobox.dropdown.warnings'
 }
   ],
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/4bcf111f/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 7379220..d1f7afd 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -658,7 +658,7 @@ Em.I18n.translations = {
   'installer.step7.popup.validation.request.failed.body': 'Config validaition 
failed.',
   'installer.step7.popup.validation.warning.header': 'Configurations',
   'installer.step7.popup.validation.warning.body': 'Some service 
configurations are not configured properly. We recommend you review and change 
the highlighted configuration values. Are you sure you want to proceed without 
correcting configurations?',
-
+  'installer.step7.popup.validation.warning.errorDescription': ' value is less 
than the recommended default of ',
   'installer.step7.oozie.database.new': 'New Derby Database',
   'installer.step7.hive.database.new': 'New MySQL Database',
 
@@ -2263,6 +2263,7 @@ Em.I18n.translations = {
   'common.combobox.dropdown.final': 'Final properties',
   'common.combobox.dropdown.changed': 'Changed properties',
   'common.combobox.dropdown.issues': 'Show property issues',
+  'common.combobox.dropdown.warnings': 'Show property warnings',
 
   'quick.links.error.label': 'Hostname is undefined',
   'quick.links.publicHostName': '{0} ({1})',

http://git-wip-us.apache.org/repos/asf/ambari/blob/4bcf111f/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 bea7bd7..8d551f8 100644
--- a/ambari-web/app/mixins/common/serverValidator.js
+++ b/ambari-web/app/mixins/common/serverValidator.js
@@ -274,6 +274,7 @@ App.ServerValidatorMixin = Em.Mixin.create({
   // Motivation: for server-side validation warnings and EVEN errors allow 
user to continue wizard
   

git commit: AMBARI-7333. Tez deployment changes for Champlain (aonishuk)

2014-09-17 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 4bcf111f1 - c09edb729


AMBARI-7333. Tez deployment changes for Champlain (aonishuk)


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

Branch: refs/heads/trunk
Commit: c09edb729fce602f0943b048df7810353ecd4975
Parents: 4bcf111
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Wed Sep 17 18:11:06 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Wed Sep 17 18:11:06 2014 +0300

--
 .../libraries/providers/copy_from_local.py   | 12 +---
 .../libraries/resources/copy_from_local.py   |  3 ++-
 .../HIVE/package/scripts/install_jars.py | 19 +++
 .../2.1/services/TEZ/configuration/tez-site.xml  |  2 +-
 .../python/stacks/2.0.6/HIVE/test_hive_server.py | 10 ++
 5 files changed, 37 insertions(+), 9 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/c09edb72/ambari-common/src/main/python/resource_management/libraries/providers/copy_from_local.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/providers/copy_from_local.py
 
b/ambari-common/src/main/python/resource_management/libraries/providers/copy_from_local.py
index 9031a77..79d3e35 100644
--- 
a/ambari-common/src/main/python/resource_management/libraries/providers/copy_from_local.py
+++ 
b/ambari-common/src/main/python/resource_management/libraries/providers/copy_from_local.py
@@ -27,6 +27,7 @@ class CopyFromLocalProvider(Provider):
   def action_run(self):
 path = self.resource.path
 dest_dir = self.resource.dest_dir
+dest_file = self.resource.dest_file
 kinnit_if_needed = self.resource.kinnit_if_needed
 owner = self.resource.owner
 group = self.resource.group
@@ -34,9 +35,14 @@ class CopyFromLocalProvider(Provider):
 hdfs_usr=self.resource.hdfs_user
 hadoop_conf_path = self.resource.hadoop_conf_dir
 
-copy_cmd = format(fs -copyFromLocal {path} {dest_dir})
-dest_file_name = os.path.split(path)[1]
-dest_path = dest_dir + dest_file_name if dest_dir.endswith(os.sep) else 
dest_dir + os.sep + dest_file_name
+
+if dest_file:
+  copy_cmd = format(fs -copyFromLocal {path} {dest_dir}/{dest_file})
+  dest_path = dest_dir + dest_file if dest_dir.endswith(os.sep) else 
dest_dir + os.sep + dest_file
+else:
+  dest_file_name = os.path.split(path)[1]
+  copy_cmd = format(fs -copyFromLocal {path} {dest_dir})
+  dest_path = dest_dir + os.sep + dest_file_name
 # Need to run unless as resource user
 su_cmd = 'su - {0} -c'.format(owner)
 unless_cmd = format({su_cmd} '{kinnit_if_needed} hadoop fs -ls 
{dest_path}' /dev/null 21)

http://git-wip-us.apache.org/repos/asf/ambari/blob/c09edb72/ambari-common/src/main/python/resource_management/libraries/resources/copy_from_local.py
--
diff --git 
a/ambari-common/src/main/python/resource_management/libraries/resources/copy_from_local.py
 
b/ambari-common/src/main/python/resource_management/libraries/resources/copy_from_local.py
index 328d9c2..eaaeab5 100644
--- 
a/ambari-common/src/main/python/resource_management/libraries/resources/copy_from_local.py
+++ 
b/ambari-common/src/main/python/resource_management/libraries/resources/copy_from_local.py
@@ -28,6 +28,7 @@ class CopyFromLocal(Resource):
 
   path = ResourceArgument(default=lambda obj: obj.name)
   dest_dir = ResourceArgument(required=True)
+  dest_file = ResourceArgument()
   owner = ResourceArgument(required=True)
   group = ResourceArgument()
   mode = ResourceArgument()
@@ -35,4 +36,4 @@ class CopyFromLocal(Resource):
   hadoop_conf_dir = ResourceArgument(default='/etc/hadoop/conf')
   hdfs_user = ResourceArgument(default='hdfs')
 
-  actions = Resource.actions + [run]
\ No newline at end of file
+  actions = Resource.actions + [run]

http://git-wip-us.apache.org/repos/asf/ambari/blob/c09edb72/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/install_jars.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/install_jars.py
 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/install_jars.py
index 3548de7..0045fee 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/install_jars.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/install_jars.py
@@ -72,6 +72,16 @@ def install_tez_jars():
  

git commit: AMBARI-7365. Resource Manager HA wizard appears after closing and page refresh. (akovalenko)

2014-09-17 Thread akovalenko
Repository: ambari
Updated Branches:
  refs/heads/trunk c09edb729 - 892f423c8


AMBARI-7365. Resource Manager HA wizard appears after closing and page refresh. 
(akovalenko)


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

Branch: refs/heads/trunk
Commit: 892f423c8266ddaf205cc74d8996dd2a378928d2
Parents: c09edb7
Author: Aleksandr Kovalenko akovale...@hortonworks.com
Authored: Wed Sep 17 18:12:03 2014 +0300
Committer: Aleksandr Kovalenko akovale...@hortonworks.com
Committed: Wed Sep 17 18:13:47 2014 +0300

--
 .../resourceManager/wizard_controller.js|  1 -
 ambari-web/app/routes/rm_high_availability_routes.js| 12 
 2 files changed, 8 insertions(+), 5 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/892f423c/ambari-web/app/controllers/main/admin/highAvailability/resourceManager/wizard_controller.js
--
diff --git 
a/ambari-web/app/controllers/main/admin/highAvailability/resourceManager/wizard_controller.js
 
b/ambari-web/app/controllers/main/admin/highAvailability/resourceManager/wizard_controller.js
index 697bd13..c5a3e9e 100644
--- 
a/ambari-web/app/controllers/main/admin/highAvailability/resourceManager/wizard_controller.js
+++ 
b/ambari-web/app/controllers/main/admin/highAvailability/resourceManager/wizard_controller.js
@@ -44,7 +44,6 @@ App.RMHighAvailabilityWizardController = 
App.WizardController.extend({
 this._super(currentStep, completed);
 App.clusterStatus.setClusterStatus({
   clusterName: this.get('content.cluster.name'),
-  clusterState: 'RM_HIGH_AVAILABILITY_DEPLOY',
   wizardControllerName: 'rMHighAvailabilityWizardController',
   localdb: App.db.data
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/892f423c/ambari-web/app/routes/rm_high_availability_routes.js
--
diff --git a/ambari-web/app/routes/rm_high_availability_routes.js 
b/ambari-web/app/routes/rm_high_availability_routes.js
index a7a83dd..1739a4f 100644
--- a/ambari-web/app/routes/rm_high_availability_routes.js
+++ b/ambari-web/app/routes/rm_high_availability_routes.js
@@ -22,8 +22,12 @@ module.exports = App.WizardRoute.extend({
   route: '/highAvailability/ResourceManager/enable',
 
   enter: function (router,transition) {
+var rMHighAvailabilityWizardController = 
router.get('rMHighAvailabilityWizardController');
+rMHighAvailabilityWizardController.dataLoading().done(function () {
+  //Set YARN as current service
+  App.router.set('mainServiceItemController.content', 
App.Service.find().findProperty('serviceName', 'YARN'));
+});
 Em.run.next(function () {
-  var rMHighAvailabilityWizardController = 
router.get('rMHighAvailabilityWizardController');
   App.router.get('updateController').set('isWorking', false);
   var popup = App.ModalPopup.show({
 classNames: ['full-width-modal'],
@@ -50,7 +54,7 @@ module.exports = App.WizardRoute.extend({
 localdb: App.db.data
   }, {alwaysCallback: function () {
 self.hide();
-router.route('/main/services/YARN/summary');
+router.transitionTo('main.services.index');
 location.reload();
   }});
 }, Em.I18n.t('admin.rm_highAvailability.closePopup'));
@@ -58,7 +62,7 @@ module.exports = App.WizardRoute.extend({
 this.hide();
 rMHighAvailabilityWizardController.setCurrentStep('1');
 router.get('updateController').set('isWorking', true);
-router.route('/main/services/YARN/summary');
+router.transitionTo('main.services.index');
   }
 },
 didInsertElement: function () {
@@ -181,7 +185,7 @@ module.exports = App.WizardRoute.extend({
 localdb: App.db.data
   }, {alwaysCallback: function () {
 controller.get('popup').hide();
-router.route('/main/services/YARN/summary');
+router.transitionTo('main.services.index');
 location.reload();
   }});
 }



git commit: AMBARI-7366 On switching config group config version stays the same. (atkach)

2014-09-17 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk 892f423c8 - 760d9894d


AMBARI-7366 On switching config group config version stays the same. (atkach)


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

Branch: refs/heads/trunk
Commit: 760d9894d3939dfd4b4d343ddbbeef05f48f9208
Parents: 892f423
Author: atkach atk...@hortonworks.com
Authored: Wed Sep 17 18:27:55 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Wed Sep 17 18:27:55 2014 +0300

--
 .../controllers/main/service/info/configs.js| 21 +++-
 ambari-web/app/models/service_config_version.js |  2 +-
 2 files changed, 17 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/760d9894/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 32343ff..3112d40 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -324,17 +324,18 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
* get selected service config version
* In case selected version is undefined then take currentDefaultVersion
* @param version
+   * @param switchToGroup
*/
-  loadSelectedVersion: function (version) {
+  loadSelectedVersion: function (version, switchToGroup) {
 var self = this;
 this.set('versionLoaded', false);
 version = version || this.get('currentDefaultVersion');
 //version of non-default group require properties from current version of 
default group to correctly display page
 var versions = (this.isVersionDefault(version)) ? [version] : 
[this.get('currentDefaultVersion'), version];
+switchToGroup = this.isVersionDefault(version) ? 
this.get('configGroups').findProperty('isDefault') : switchToGroup;
 
-//if version from default group selected then switch to default group
-if (self.get('dataIsLoaded')  this.isVersionDefault(version)) {
-  this.set('selectedConfigGroup', 
this.get('configGroups').findProperty('isDefault'));
+if (self.get('dataIsLoaded')  switchToGroup) {
+  this.set('selectedConfigGroup', switchToGroup);
 }
 
 App.ajax.send({
@@ -2708,7 +2709,17 @@ App.MainServiceInfoConfigsController = 
Em.Controller.extend(App.ServerValidatorM
 }
 //clean when switch config group
 this.loadedGroupToOverrideSiteToTagMap = {};
-this.set('selectedConfigGroup', event.context);
+if (App.supports.configHistory) {
+  var configGroupVersions = 
App.ServiceConfigVersion.find().filterProperty('groupId', 
event.context.get('id'));
+  //check whether config group has config versions
+  if (configGroupVersions.length  0) {
+
this.loadSelectedVersion(configGroupVersions.findProperty('isCurrent').get('version'),
 event.context);
+  } else {
+this.loadSelectedVersion(null, event.context);
+  }
+} else {
+  this.set('selectedConfigGroup', event.context);
+}
   },
 
   /**

http://git-wip-us.apache.org/repos/asf/ambari/blob/760d9894/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 4a65ac2..61703ad 100644
--- a/ambari-web/app/models/service_config_version.js
+++ b/ambari-web/app/models/service_config_version.js
@@ -27,7 +27,7 @@ App.ServiceConfigVersion = DS.Model.extend({
 return App.format.role(this.get('serviceName'));
   }.property('serviceName'),
   groupName: DS.attr('string'),
-  groupId: DS.attr('string'),
+  groupId: DS.attr('number'),
   version: DS.attr('number'),
   createTime: DS.attr('number'),
   author: DS.attr('string'),



git commit: AMBARI-7364. Oozie start fails with oozie_admin_port was not found, after ambari upgrade from 1.6.0 to 1.7.0.(vbrodetskyi)

2014-09-17 Thread vbrodetskyi
Repository: ambari
Updated Branches:
  refs/heads/trunk 760d9894d - 6952fa448


AMBARI-7364. Oozie start fails with oozie_admin_port was not found, after 
ambari upgrade from 1.6.0 to 1.7.0.(vbrodetskyi)


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

Branch: refs/heads/trunk
Commit: 6952fa4482cc999a437e6b498ec1d1a2a893ff21
Parents: 760d989
Author: Vitaly Brodetskyi vbrodets...@hortonworks.com
Authored: Wed Sep 17 18:39:50 2014 +0300
Committer: Vitaly Brodetskyi vbrodets...@hortonworks.com
Committed: Wed Sep 17 18:39:50 2014 +0300

--
 .../java/org/apache/ambari/server/upgrade/UpgradeCatalog161.java | 1 -
 .../java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java | 2 ++
 .../org/apache/ambari/server/upgrade/UpgradeCatalog161Test.java  | 4 
 .../org/apache/ambari/server/upgrade/UpgradeCatalog170Test.java  | 4 
 4 files changed, 6 insertions(+), 5 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/6952fa44/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog161.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog161.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog161.java
index 62b4e35..a4bb2b2 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog161.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog161.java
@@ -289,7 +289,6 @@ public class UpgradeCatalog161 extends 
AbstractUpgradeCatalog {
   protected void addMissingConfigs() throws AmbariException {
 updateConfigurationProperties(hbase-site, 
Collections.singletonMap(hbase.regionserver.info.port, 60030), false, 
false);
 updateConfigurationProperties(hbase-site, 
Collections.singletonMap(hbase.master.info.port, 60010), false, false);
-updateConfigurationProperties(oozie-env, 
Collections.singletonMap(oozie_admin_port, 11001), false, false);
 updateConfigurationProperties(hive-site, 
Collections.singletonMap(hive.heapsize, 1024), false, false);
 updateConfigurationProperties(pig-properties, 
Collections.singletonMap(pig-content, \n# Licensed to the Apache  +
 Software Foundation (ASF) under one\n# or more contributor 
license agreements.  See the NOTICE file\n#  +

http://git-wip-us.apache.org/repos/asf/ambari/blob/6952fa44/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
--
diff --git 
a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
 
b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
index e58b6d3..1c9608c 100644
--- 
a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
+++ 
b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog170.java
@@ -945,6 +945,8 @@ public class UpgradeCatalog170 extends 
AbstractUpgradeCatalog {
 updateConfigurationProperties(hadoop-env,
 Collections.singletonMap(hadoop_root_logger, INFO,RFA), false,
 false);
+
+updateConfigurationProperties(oozie-env, 
Collections.singletonMap(oozie_admin_port, 11001), false, false);
   }
 
   /**

http://git-wip-us.apache.org/repos/asf/ambari/blob/6952fa44/ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog161Test.java
--
diff --git 
a/ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog161Test.java
 
b/ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog161Test.java
index 1d12ea0..4315e2c 100644
--- 
a/ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog161Test.java
+++ 
b/ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog161Test.java
@@ -147,10 +147,6 @@ public class UpgradeCatalog161Test {
 Collections.singletonMap(hbase.master.info.port, 60010), false, 
false);
 expectLastCall();
 
-upgradeCatalog.updateConfigurationProperties(oozie-env,
-Collections.singletonMap(oozie_admin_port, 11001), false, false);
-expectLastCall();
-
 upgradeCatalog.updateConfigurationProperties(hive-site,
 Collections.singletonMap(hive.heapsize, 1024), false, false);
 expectLastCall();

http://git-wip-us.apache.org/repos/asf/ambari/blob/6952fa44/ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog170Test.java

git commit: AMBARI-7333. Tez deployment changes for Champlain (aonishuk)

2014-09-17 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 6952fa448 - 0449d2223


AMBARI-7333. Tez deployment changes for Champlain (aonishuk)


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

Branch: refs/heads/trunk
Commit: 0449d22238aedc5c6fe5489b40e58d01f0a9caf1
Parents: 6952fa4
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Wed Sep 17 18:49:09 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Wed Sep 17 18:49:09 2014 +0300

--
 .../stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py  | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/0449d222/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py
 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py
index fd8945f..ab86ff7 100644
--- 
a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/params.py
@@ -222,7 +222,8 @@ if System.get_instance().os_family == ubuntu:
   mysql_configname = '/etc/mysql/my.cnf'
 else:
   mysql_configname = '/etc/my.cnf'
-  
+
+tez_tar_file = /usr/lib/tez/tez*.tar.gz
 
 # Hive security
 hive_authorization_enabled = 
config['configurations']['hive-site']['hive.security.authorization.enabled']



git commit: AMBARI-7333. Tez deployment changes for Champlain (aonishuk)

2014-09-17 Thread aonishuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 0449d2223 - 117b4558c


AMBARI-7333. Tez deployment changes for Champlain (aonishuk)


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

Branch: refs/heads/trunk
Commit: 117b4558c347a80ac4d26db295f12c37237a3b8b
Parents: 0449d22
Author: Andrew Onishuk aonis...@hortonworks.com
Authored: Wed Sep 17 18:55:23 2014 +0300
Committer: Andrew Onishuk aonis...@hortonworks.com
Committed: Wed Sep 17 18:55:23 2014 +0300

--
 .../src/test/python/resource_management/TestCopyFromLocal.py | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/117b4558/ambari-agent/src/test/python/resource_management/TestCopyFromLocal.py
--
diff --git 
a/ambari-agent/src/test/python/resource_management/TestCopyFromLocal.py 
b/ambari-agent/src/test/python/resource_management/TestCopyFromLocal.py
index 90397ae..6862db3 100644
--- a/ambari-agent/src/test/python/resource_management/TestCopyFromLocal.py
+++ b/ambari-agent/src/test/python/resource_management/TestCopyFromLocal.py
@@ -36,9 +36,9 @@ class TestCopyFromLocal(TestCase):
   call_arg_list = execute_hadoop_mock.call_args_list
   self.assertEqual('fs -copyFromLocal /user/testdir/*.files /apps/test/',
call_arg_list[0][0][0].command)
-  self.assertEquals({'not_if': su - user1 -c ' hadoop fs -ls 
/apps/test/*.files' /dev/null 21, 'user': 'user1', 'conf_dir': 
'/etc/hadoop/conf'},
+  self.assertEquals({'not_if': su - user1 -c ' hadoop fs -ls 
/apps/test//*.files' /dev/null 21, 'user': 'user1', 'conf_dir': 
'/etc/hadoop/conf'},
 call_arg_list[0][0][0].arguments)
-  self.assertEquals('fs -chown user1 /apps/test/*.files', 
call_arg_list[1][0][0].command)
+  self.assertEquals('fs -chown user1 /apps/test//*.files', 
call_arg_list[1][0][0].command)
   self.assertEquals({'user': 'hdfs', 'conf_dir': '/etc/hadoop/conf'}, 
call_arg_list[1][0][0].arguments)
 
 
@@ -57,9 +57,9 @@ class TestCopyFromLocal(TestCase):
   call_arg_list = execute_hadoop_mock.call_args_list
   self.assertEqual('fs -copyFromLocal /user/testdir/*.files /apps/test/',
call_arg_list[0][0][0].command)
-  self.assertEquals({'not_if': su - user1 -c ' hadoop fs -ls 
/apps/test/*.files' /dev/null 21, 'user': 'user1', 'conf_dir': 
'/etc/hadoop/conf'},
+  self.assertEquals({'not_if': su - user1 -c ' hadoop fs -ls 
/apps/test//*.files' /dev/null 21, 'user': 'user1', 'conf_dir': 
'/etc/hadoop/conf'},
 call_arg_list[0][0][0].arguments)
-  self.assertEquals('fs -chown user1:hdfs /apps/test/*.files', 
call_arg_list[1][0][0].command)
+  self.assertEquals('fs -chown user1:hdfs /apps/test//*.files', 
call_arg_list[1][0][0].command)
   self.assertEquals({'user': 'hdfs', 'conf_dir': '/etc/hadoop/conf'}, 
call_arg_list[1][0][0].arguments)
 
 



git commit: AMBARI-7367 Config History filter by date custom throws JS. (ababiichuk)

2014-09-17 Thread ababiichuk
Repository: ambari
Updated Branches:
  refs/heads/trunk 117b4558c - b4e1aed4a


AMBARI-7367 Config History filter by date custom throws JS. (ababiichuk)


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

Branch: refs/heads/trunk
Commit: b4e1aed4a7e3b67e48eb330e518786c3a24a07d8
Parents: 117b455
Author: aBabiichuk ababiic...@cybervisiontech.com
Authored: Wed Sep 17 19:26:46 2014 +0300
Committer: aBabiichuk ababiic...@cybervisiontech.com
Committed: Wed Sep 17 19:26:46 2014 +0300

--
 .../app/templates/common/custom_date_popup.hbs  | 39 
 ambari-web/app/views.js |  1 +
 .../app/views/common/select_custom_date_view.js | 36 ++
 3 files changed, 76 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/b4e1aed4/ambari-web/app/templates/common/custom_date_popup.hbs
--
diff --git a/ambari-web/app/templates/common/custom_date_popup.hbs 
b/ambari-web/app/templates/common/custom_date_popup.hbs
new file mode 100644
index 000..04c4560
--- /dev/null
+++ b/ambari-web/app/templates/common/custom_date_popup.hbs
@@ -0,0 +1,39 @@
+{{!
+* 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.
+}}
+
+div class=jobs-custom-dates
+  div
+label{{t jobs.customDateFilter.startTime}}/label
+{{view Ember.TextField 
valueBinding=controller.customDateFormFields.startDate class=input-small 
datepicker}}
+{{view Ember.Select contentBinding=view.hourOptions 
selectionBinding=controller.customDateFormFields.hoursForStart 
class=input-mini}}
+{{view Ember.Select contentBinding=view.minuteOptions 
selectionBinding=controller.customDateFormFields.minutesForStart 
class=input-mini}}
+{{view Ember.Select contentBinding=view.middayPeriodOptions 
selectionBinding=controller.customDateFormFields.middayPeriodForStart 
class=input-mini}}
+span 
class=help-inline{{controller.filterObject.errorMessages.startDate}}/span
+  /div
+  div
+
+  /div
+  div
+label{{t jobs.customDateFilter.endTime}}/label
+{{view Ember.TextField 
valueBinding=controller.customDateFormFields.endDate class=input-small 
datepicker}}
+{{view Ember.Select contentBinding=view.hourOptions 
selectionBinding=controller.customDateFormFields.hoursForEnd 
class=input-mini}}
+{{view Ember.Select contentBinding=view.minuteOptions 
selectionBinding=controller.customDateFormFields.minutesForEnd 
class=input-mini}}
+{{view Ember.Select contentBinding=view.middayPeriodOptions 
selectionBinding=controller.customDateFormFields.middayPeriodForEnd 
class=input-mini}}
+span 
class=help-inline{{controller.filterObject.errorMessages.endDate}}/span
+  /div
+/div

http://git-wip-us.apache.org/repos/asf/ambari/blob/b4e1aed4/ambari-web/app/views.js
--
diff --git a/ambari-web/app/views.js b/ambari-web/app/views.js
index baaee39..12b2683 100644
--- a/ambari-web/app/views.js
+++ b/ambari-web/app/views.js
@@ -26,6 +26,7 @@ require('views/common/chart/linear');
 require('views/common/chart/linear_time');
 require('views/common/modal_popup');
 require('views/common/rolling_restart_view');
+require('views/common/select_custom_date_view');
 require('views/common/metric');
 require('views/common/time_range');
 require('views/common/form/field');

http://git-wip-us.apache.org/repos/asf/ambari/blob/b4e1aed4/ambari-web/app/views/common/select_custom_date_view.js
--
diff --git a/ambari-web/app/views/common/select_custom_date_view.js 
b/ambari-web/app/views/common/select_custom_date_view.js
new file mode 100644
index 000..55da7fd
--- /dev/null
+++ b/ambari-web/app/views/common/select_custom_date_view.js
@@ -0,0 +1,36 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license 

git commit: AMBARI-7369. Clients in INIT or INSTALL FAILED state should have an menu action for installation (Denys Buzhor via alexantonenko)

2014-09-17 Thread alexantonenko
Repository: ambari
Updated Branches:
  refs/heads/trunk b4e1aed4a - 1f4d315ce


AMBARI-7369. Clients in INIT or INSTALL FAILED state should have an menu action 
for installation (Denys Buzhor via alexantonenko)


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

Branch: refs/heads/trunk
Commit: 1f4d315ce2c9be2e3077fb4c264b1a10e1cc11d8
Parents: b4e1aed
Author: Alex Antonenko hiv...@gmail.com
Authored: Wed Sep 17 19:45:40 2014 +0300
Committer: Alex Antonenko hiv...@gmail.com
Committed: Wed Sep 17 19:45:40 2014 +0300

--
 ambari-web/app/controllers/main/host/details.js |  9 -
 ambari-web/app/messages.js  |  1 +
 ambari-web/app/templates/main/host/summary.hbs  |  8 
 ambari-web/app/views/main/host/summary.js   | 11 +++
 4 files changed, 28 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/1f4d315c/ambari-web/app/controllers/main/host/details.js
--
diff --git a/ambari-web/app/controllers/main/host/details.js 
b/ambari-web/app/controllers/main/host/details.js
index a9b7d76..39d9086 100644
--- a/ambari-web/app/controllers/main/host/details.js
+++ b/ambari-web/app/controllers/main/host/details.js
@@ -1592,6 +1592,13 @@ App.MainHostDetailsController = Em.Controller.extend({
   componentName: event.context.get('componentName'),
   displayName: event.context.get('displayName')
 });
-  }
+  },
 
+  reinstallClients: function(event) {
+var clientsToInstall = event.context.filter(function(component) {
+  return ['INIT', 'INSTALL_FAILED'].contains(component.get('workStatus'));
+});
+if (!clientsToInstall.length) return;
+this.sendComponentCommand(clientsToInstall, 
Em.I18n.t('host.host.details.installClients'), 'INSTALLED');
+  }
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/1f4d315c/ambari-web/app/messages.js
--
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index d1f7afd..5c330b4 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1695,6 +1695,7 @@ Em.I18n.translations = {
   'hosts.host.details.restartAllComponents':'Restart All Components',
   'hosts.host.details.refreshConfigs':'Refresh configs',
   'hosts.host.details.for.postfix':'{0} for host',
+  'host.host.details.installClients': 'Install clients',
 
   'host.host.componentFilter.master':'Master Components',
   'host.host.componentFilter.slave':'Slave Components',

http://git-wip-us.apache.org/repos/asf/ambari/blob/1f4d315c/ambari-web/app/templates/main/host/summary.hbs
--
diff --git a/ambari-web/app/templates/main/host/summary.hbs 
b/ambari-web/app/templates/main/host/summary.hbs
index df2a02f..1c363ee 100644
--- a/ambari-web/app/templates/main/host/summary.hbs
+++ b/ambari-web/app/templates/main/host/summary.hbs
@@ -72,6 +72,9 @@
   div class=span7
 {{#each component in view.clients}}
   {{component.displayName}}
+  {{#if component.isInstallFailed}}
+span class=health-status-installed 
icon-warning-sign/span
+  {{/if}}
   {{#if component.staleConfigs}}
 span class=text-warning icon-refresh/span
   {{/if}}
@@ -97,6 +100,11 @@
   {{t hosts.host.details.refreshConfigs}}
 /a
   /li
+  li
+a href=javscript:void(null) {{bindAttr 
class=view.areClientsInstallFailed::disabled }} data-toggle=modal {{action 
reinstallClients view.clients target=controller}}
+  {{t host.host.details.installClients}}
+/a
+  /li
 /ul
   /div
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/1f4d315c/ambari-web/app/views/main/host/summary.js
--
diff --git a/ambari-web/app/views/main/host/summary.js 
b/ambari-web/app/views/main/host/summary.js
index 90ce1e7..e67be32 100644
--- a/ambari-web/app/views/main/host/summary.js
+++ b/ambari-web/app/views/main/host/summary.js
@@ -182,11 +182,22 @@ App.MainHostSummaryView = Em.View.extend({
   clients[clients.length - 1].set('isLast', false);
 }
 component.set('isLast', true);
+if (['INSTALL_FAILED', 

git commit: AMBARI-6040. Modify configuration with Ambari Shell. (Janos Matyas and Krisztian Horvath via yusaku)

2014-09-17 Thread yusaku
Repository: ambari
Updated Branches:
  refs/heads/trunk 1f4d315ce - f3345be0b


AMBARI-6040. Modify configuration with Ambari Shell. (Janos Matyas and 
Krisztian Horvath via yusaku)


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

Branch: refs/heads/trunk
Commit: f3345be0b99b40f6811745808f51f924a10740e2
Parents: 1f4d315
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Sep 17 09:59:48 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Sep 17 10:00:36 2014 -0700

--
 .../ambari/groovy/client/AmbariClient.groovy|   7 +-
 ambari-shell/ambari-groovy-shell/pom.xml|  11 ++
 .../ambari/shell/commands/ConfigCommands.java   | 163 +++
 .../shell/completion/AbstractCompletion.java|  34 
 .../ambari/shell/completion/Blueprint.java  |   9 +-
 .../ambari/shell/completion/ConfigType.java |  29 
 .../apache/ambari/shell/completion/Host.java|   9 +-
 .../apache/ambari/shell/completion/Service.java |  12 +-
 .../configuration/ConverterConfiguration.java   |   6 +
 .../shell/converter/AbstractConverter.java  |  63 +++
 .../shell/converter/BlueprintConverter.java |  21 +--
 .../shell/converter/ConfigTypeConverter.java|  45 +
 .../ambari/shell/converter/HostConverter.java   |  21 +--
 .../shell/converter/ServiceConverter.java   |  24 +--
 .../shell/commands/ConfigCommandsTest.java  |  98 +++
 .../src/test/resources/core-site.xml|  13 ++
 16 files changed, 490 insertions(+), 75 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/f3345be0/ambari-client/groovy-client/src/main/groovy/org/apache/ambari/groovy/client/AmbariClient.groovy
--
diff --git 
a/ambari-client/groovy-client/src/main/groovy/org/apache/ambari/groovy/client/AmbariClient.groovy
 
b/ambari-client/groovy-client/src/main/groovy/org/apache/ambari/groovy/client/AmbariClient.groovy
index f0ca650..6d94c5d 100644
--- 
a/ambari-client/groovy-client/src/main/groovy/org/apache/ambari/groovy/client/AmbariClient.groovy
+++ 
b/ambari-client/groovy-client/src/main/groovy/org/apache/ambari/groovy/client/AmbariClient.groovy
@@ -443,7 +443,7 @@ class AmbariClient {
 
   /**
* Adds a blueprint with the desired configurations.
-   * 
+   *
* @param json blueprint to be added
* @param configurations blueprint will be extended with these configurations
* @return the extended blueprint as json
@@ -752,11 +752,12 @@ class AmbariClient {
*
* @return a Map with entries of format servicename, Mapproperty, value
*/
-  def MapString, MapString, String getServiceConfigMap() {
+  def MapString, MapString, String getServiceConfigMap(String type = ) {
 def MapString, Integer serviceToTags = new HashMap()
 
 //get services and last versions configurations
-MapString, ? configsResourceRequestMap = 
getResourceRequestMap(clusters/${getClusterName()}/configurations, [:])
+def path = clusters/${getClusterName()}/configurations
+MapString, ? configsResourceRequestMap = getResourceRequestMap(path, 
type ? [type: type] : [:])
 def rawConfigs = getSlurpedResource(configsResourceRequestMap)
 
 rawConfigs?.items.collect { object -

http://git-wip-us.apache.org/repos/asf/ambari/blob/f3345be0/ambari-shell/ambari-groovy-shell/pom.xml
--
diff --git a/ambari-shell/ambari-groovy-shell/pom.xml 
b/ambari-shell/ambari-groovy-shell/pom.xml
index a1acf8b..ed4d0b6 100644
--- a/ambari-shell/ambari-groovy-shell/pom.xml
+++ b/ambari-shell/ambari-groovy-shell/pom.xml
@@ -71,6 +71,16 @@
   groupIdorg.codehaus.jackson/groupId
   artifactIdjackson-mapper-asl/artifactId
 /dependency
+dependency
+  groupIdorg.apache.hadoop/groupId
+  artifactIdhadoop-common/artifactId
+  version2.4.1/version
+/dependency
+dependency
+  groupIdorg.apache.httpcomponents/groupId
+  artifactIdhttpclient/artifactId
+  version4.2.5/version
+/dependency
   /dependencies
   build
 plugins
@@ -87,6 +97,7 @@
 excludesrc/test/resources/2columns/exclude
 excludesrc/test/resources/3columns/exclude
 excludesrc/test/resources/testBlueprint.json/exclude
+excludesrc/test/resources/core-site.xml/exclude
   /excludes
 /configuration
 executions

http://git-wip-us.apache.org/repos/asf/ambari/blob/f3345be0/ambari-shell/ambari-groovy-shell/src/main/java/org/apache/ambari/shell/commands/ConfigCommands.java

git commit: AMBARI-7370 yarn.admin.acl property showing up in compare but it's not set in versions. (atkach)

2014-09-17 Thread atkach
Repository: ambari
Updated Branches:
  refs/heads/trunk f3345be0b - 9efa63da0


AMBARI-7370 yarn.admin.acl property showing up in compare but it's not set in 
versions. (atkach)


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

Branch: refs/heads/trunk
Commit: 9efa63da0eab71c7d1aefbe95fcd4e21ac742762
Parents: f3345be
Author: atkach atk...@hortonworks.com
Authored: Wed Sep 17 20:06:24 2014 +0300
Committer: atkach atk...@hortonworks.com
Committed: Wed Sep 17 20:06:24 2014 +0300

--
 ambari-web/app/utils/config.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/9efa63da/ambari-web/app/utils/config.js
--
diff --git a/ambari-web/app/utils/config.js b/ambari-web/app/utils/config.js
index f49c5aa..8226811 100644
--- a/ambari-web/app/utils/config.js
+++ b/ambari-web/app/utils/config.js
@@ -364,7 +364,7 @@ App.config = Em.Object.create({
   // in case when config is absent on server and defined UI config is 
required
   // by server, this config should be ignored
   var serverProperty = properties[serviceConfigObj.get('name')];
-  if (!serverProperty  serviceConfigObj.get('isRequiredByAgent')) {
+  if (Em.isNone(serverProperty)  
serviceConfigObj.get('isRequiredByAgent')) {
 continue;
   }
 }



git commit: AMBARI-7371. Admin View : Set systemtrue/system in view.xml. (jaimin)

2014-09-17 Thread jaimin
Repository: ambari
Updated Branches:
  refs/heads/trunk 9efa63da0 - 372514d90


AMBARI-7371. Admin View : Set systemtrue/system in view.xml. (jaimin)


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

Branch: refs/heads/trunk
Commit: 372514d904d935a8220dfbdc261c1825c1431ead
Parents: 9efa63d
Author: Jaimin Jetly jai...@hortonworks.com
Authored: Wed Sep 17 13:57:18 2014 -0700
Committer: Jaimin Jetly jai...@hortonworks.com
Committed: Wed Sep 17 13:57:18 2014 -0700

--
 ambari-admin/src/main/resources/view.xml | 1 +
 1 file changed, 1 insertion(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/372514d9/ambari-admin/src/main/resources/view.xml
--
diff --git a/ambari-admin/src/main/resources/view.xml 
b/ambari-admin/src/main/resources/view.xml
index c618a8a..9bb4d8e 100644
--- a/ambari-admin/src/main/resources/view.xml
+++ b/ambari-admin/src/main/resources/view.xml
@@ -18,6 +18,7 @@ limitations under the License. Kerberos, LDAP, Custom. 
Binary/Htt
   nameADMIN_VIEW/name
   labelAmbari Admin View/label
   version1.0.0/version
+  systemtrue/system
   instance
 nameINSTANCE/name
 visiblefalse/visible



git commit: AMBARI-7350. Add SLIDER service to the stacks

2014-09-17 Thread smohanty
Repository: ambari
Updated Branches:
  refs/heads/trunk 2a5759c5d - dcc03bc73


AMBARI-7350. Add SLIDER service to the stacks


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

Branch: refs/heads/trunk
Commit: dcc03bc735f1258ba5503847b38d11ef8c725ecd
Parents: 2a5759c
Author: Sumit Mohanty smoha...@hortonworks.com
Authored: Wed Sep 17 15:59:44 2014 -0700
Committer: Sumit Mohanty smoha...@hortonworks.com
Committed: Wed Sep 17 15:59:44 2014 -0700

--
 .../SLIDER/configuration/slider-client.xml  |  56 +
 .../SLIDER/configuration/slider-log4j.xml   |  89 ++
 .../stacks/HDP/2.2/services/SLIDER/metainfo.xml |  72 
 .../SLIDER/package/files/hbaseSmokeVerify.sh|  34 ++
 .../services/SLIDER/package/scripts/__init__.py |  19 +++
 .../services/SLIDER/package/scripts/params.py   |  45 
 .../SLIDER/package/scripts/service_check.py |  45 
 .../services/SLIDER/package/scripts/slider.py   |  68 +++
 .../SLIDER/package/scripts/slider_client.py |  43 +++
 .../SLIDER/package/templates/slider-wrapper.j2  |  42 +++
 .../stacks/2.2/SLIDER/test_slider_client.py | 109 ++
 .../test/python/stacks/2.2/configs/default.json | 115 +++
 .../test/python/stacks/2.2/configs/secured.json |  79 +
 13 files changed, 816 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/dcc03bc7/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-client.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-client.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-client.xml
new file mode 100644
index 000..7d55760
--- /dev/null
+++ 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-client.xml
@@ -0,0 +1,56 @@
+?xml version=1.0?
+?xml-stylesheet type=text/xsl href=configuration.xsl?
+!--
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this 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=true
+  property
+nameslider.yarn.queue/name
+valuedefault/value
+descriptionYARN queue for the Application Master/description
+  /property
+  property
+nameslider.zookeeper.quorum/name
+valuelocalhost:2181/value
+descriptionZK quorum/description
+  /property
+  !--property
+nameyarn.resourcemanager.address/name
+valuelocalhost:8050/value
+descriptionThe address of the applications manager interface in the 
RM./description
+  /property
+  property
+nameyarn.resourcemanager.scheduler.address/name
+valuelocalhost:8030/value
+descriptionThe address of the scheduler interface./description
+  /property
+  property
+nameyarn.application.classpath/name
+value
+  
/etc/hadoop/conf,/usr/lib/hadoop/*,/usr/lib/hadoop/lib/*,/usr/lib/hadoop-hdfs/*,/usr/lib/hadoop-hdfs/lib/*,/usr/lib/hadoop-yarn/*,/usr/lib/hadoop-yarn/lib/*,/usr/lib/hadoop-mapreduce/*,/usr/lib/hadoop-mapreduce/lib/*
+/value
+descriptionDefault application classpath./description
+  /property
+  property
+namefs.defaultFS/name
+valuehdfs://localhost:8020/value
+descriptionThe name of the default file system.  Either the
+  literal string local or a host:port for NDFS./description
+  /property--
+/configuration

http://git-wip-us.apache.org/repos/asf/ambari/blob/dcc03bc7/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-log4j.xml
--
diff --git 
a/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-log4j.xml
 
b/ambari-server/src/main/resources/stacks/HDP/2.2/services/SLIDER/configuration/slider-log4j.xml
new file mode 100644
index 000..709867c

git commit: AMBARI-7375. Views list not loaded into menu after first login. (yusaku)

2014-09-17 Thread yusaku
Repository: ambari
Updated Branches:
  refs/heads/trunk dcc03bc73 - 856ac44f8


AMBARI-7375. Views list not loaded into menu after first login. (yusaku)


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

Branch: refs/heads/trunk
Commit: 856ac44f8074527f44df79d43e6335479ae712c1
Parents: dcc03bc
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Sep 17 16:30:28 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Sep 17 16:34:02 2014 -0700

--
 ambari-web/app/controllers/main.js  | 1 -
 ambari-web/app/controllers/main/views_controller.js | 6 +-
 ambari-web/app/routes/main.js   | 1 -
 3 files changed, 5 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/856ac44f/ambari-web/app/controllers/main.js
--
diff --git a/ambari-web/app/controllers/main.js 
b/ambari-web/app/controllers/main.js
index b5d83c4..55db450 100644
--- a/ambari-web/app/controllers/main.js
+++ b/ambari-web/app/controllers/main.js
@@ -44,7 +44,6 @@ App.MainController = Em.Controller.extend({
*/
   initialize: function(){
 App.router.get('clusterController').loadClusterData();
-App.router.get('mainViewsController').loadAmbariViews();
   },
 
   dataLoading: function () {

http://git-wip-us.apache.org/repos/asf/ambari/blob/856ac44f/ambari-web/app/controllers/main/views_controller.js
--
diff --git a/ambari-web/app/controllers/main/views_controller.js 
b/ambari-web/app/controllers/main/views_controller.js
index b3b36fe..fb1dce7 100644
--- a/ambari-web/app/controllers/main/views_controller.js
+++ b/ambari-web/app/controllers/main/views_controller.js
@@ -25,6 +25,10 @@ App.MainViewsController = Em.Controller.extend({
 
   ambariViews: [],
 
+  init: function () {
+this.loadAmbariViews();
+  },
+
   dataLoading: function () {
 var viewsController = this;
 var dfd = $.Deferred();
@@ -103,7 +107,7 @@ App.MainViewsController = Em.Controller.extend({
 
   setView: function(event) {
 if(event.context){
-  App.router.transitionTo('views.viewDetails', event.context);
+  App.router.transitionTo('main.views.viewDetails', event.context);
 }
   }
 });
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/856ac44f/ambari-web/app/routes/main.js
--
diff --git a/ambari-web/app/routes/main.js b/ambari-web/app/routes/main.js
index d6521bd..44e64b9 100644
--- a/ambari-web/app/routes/main.js
+++ b/ambari-web/app/routes/main.js
@@ -39,7 +39,6 @@ module.exports = Em.Route.extend({
 }
 else {
   App.router.get('clusterController').set('isLoaded', true);
-  App.router.get('mainViewsController').loadAmbariViews();
 }
   }
 });



[2/2] git commit: AMBARI-7378. Completely hide System Views from all of UI (Admin View, Ambari Web). (yusaku)

2014-09-17 Thread yusaku
AMBARI-7378. Completely hide System Views from all of UI (Admin View, Ambari 
Web). (yusaku)


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

Branch: refs/heads/trunk
Commit: 7a087b1860ab80bbce5d3574e08068042b63d530
Parents: 0cec52d
Author: Yusaku Sako yus...@hortonworks.com
Authored: Wed Sep 17 17:21:49 2014 -0700
Committer: Yusaku Sako yus...@hortonworks.com
Committed: Wed Sep 17 17:21:49 2014 -0700

--
 .../src/main/resources/ui/admin-web/app/scripts/services/View.js  | 3 ++-
 ambari-web/app/utils/ajax/ajax.js | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/7a087b18/ambari-admin/src/main/resources/ui/admin-web/app/scripts/services/View.js
--
diff --git 
a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/services/View.js 
b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/services/View.js
index 960ac87..e30dcf3 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/services/View.js
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/services/View.js
@@ -245,7 +245,8 @@ angular.module('ambariAdminConsole')
   method: 'GET',
   url: Settings.baseUrl + '/views',
   params:{
-'fields': fields.join(',')
+'fields': fields.join(','),
+'versions/ViewVersionInfo/system': false
   }
 }).success(function(data) {
   var views = [];

http://git-wip-us.apache.org/repos/asf/ambari/blob/7a087b18/ambari-web/app/utils/ajax/ajax.js
--
diff --git a/ambari-web/app/utils/ajax/ajax.js 
b/ambari-web/app/utils/ajax/ajax.js
index 4342195..c2a971d 100644
--- a/ambari-web/app/utils/ajax/ajax.js
+++ b/ambari-web/app/utils/ajax/ajax.js
@@ -1728,7 +1728,7 @@ var urls = {
* Get all instances of all views across versions
*/
   'views.instances': {
-'real': 
'/views?fields=versions/instances/ViewInstanceInfo,versions/ViewVersionInfo/label',
+'real': 
'/views?fields=versions/instances/ViewInstanceInfo,versions/ViewVersionInfo/labelversions/ViewVersionInfo/system=false',
 'mock': '/data/views/instances.json'
   },
   'host.host_component.flume.metrics': {



git commit: AMBARI-7377. Slider View: Add support for custom users to login into Ambari and submit application as themselves (srimanth)

2014-09-17 Thread srimanth
Repository: ambari
Updated Branches:
  refs/heads/trunk 7a087b186 - c7651de83


AMBARI-7377. Slider View: Add support for custom users to login into Ambari and 
submit application as themselves (srimanth)


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

Branch: refs/heads/trunk
Commit: c7651de83d16e2d9de16ca99399aaa9ad3c595cd
Parents: 7a087b1
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Sep 17 17:08:47 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Sep 17 17:37:39 2014 -0700

--
 .../ambari/view/slider/SliderAppsViewControllerImpl.java  | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/c7651de8/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
index 3626cbe..027f824 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
@@ -133,7 +133,7 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
 ClassLoader currentClassLoader = 
Thread.currentThread().getContextClassLoader();
 Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
 try {
-  T value = UserGroupInformation.getBestUGI(null, yarn).doAs(
+  T value = UserGroupInformation.getBestUGI(null, 
viewContext.getUsername()).doAs(
   new PrivilegedExceptionActionT() {
 @Override
 public T run() throws Exception {
@@ -274,7 +274,6 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
   app.setConfigs(configs);
 } else if (components.equals(property.toLowerCase())) {
   try {
-System.setProperty(SliderKeys.HADOOP_USER_NAME, yarn);
 ClusterDescription description = sliderClient
 .getClusterDescription(yarnApp.getName());
 if (description != null  description.status != null
@@ -368,7 +367,7 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
 SliderClient client = new SliderClient() {
   @Override
   public String getUsername() throws IOException {
-return yarn;
+return viewContext.getUsername();
   }
 
   @Override
@@ -377,7 +376,7 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
 // Override the default FS client to the calling user
 try {
   FileSystem fs = FileSystem.get(FileSystem.getDefaultUri(getConfig()),
-  getConfig(), yarn);
+  getConfig(), viewContext.getUsername());
   SliderFileSystem fileSystem = new SliderFileSystem(fs, getConfig());
   Field fsField = SliderClient.class
   .getDeclaredField(sliderFileSystem);



git commit: AMBARI-7374. Slider View: BE - Provide alerts in view API. Correcting component counts

2014-09-17 Thread srimanth
Repository: ambari
Updated Branches:
  refs/heads/trunk c7651de83 - 005892444


AMBARI-7374. Slider View: BE - Provide alerts in view API. Correcting component 
counts


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

Branch: refs/heads/trunk
Commit: 0058924443bee9cb4b55afade3bfa08196765308
Parents: c7651de
Author: Srimanth Gunturi sgunt...@hortonworks.com
Authored: Wed Sep 17 21:00:46 2014 -0700
Committer: Srimanth Gunturi sgunt...@hortonworks.com
Committed: Wed Sep 17 21:00:46 2014 -0700

--
 .../ambari/view/slider/SliderAppsAlerts.java| 30 
 .../slider/SliderAppsViewControllerImpl.java|  8 ++
 .../assets/data/resource/service_configs.json   |  2 +-
 .../createAppWizard/step1_controller.js |  2 +-
 .../ui/app/templates/slider_app/summary.hbs |  2 +-
 5 files changed, 29 insertions(+), 15 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/ambari/blob/00589244/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsAlerts.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsAlerts.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsAlerts.java
index 957c6e8..4eb54d5 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsAlerts.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsAlerts.java
@@ -66,8 +66,23 @@ public class SliderAppsAlerts {
 HashMapAlertField,Object alertItem = new HashMapAlertField, Object();
 Date date = Calendar.getInstance().getTime();
 
-
-AlertState state = getComponentState(component);
+int totalContainerCount = component.getInstanceCount();
+int activeContainerCount = component.getActiveContainers() != null ? 
component
+.getActiveContainers().size() : 0;
+AlertState state = AlertState.UNKNOWN;
+String message = String.format(%s out of %s active, activeContainerCount,
+totalContainerCount);
+if (totalContainerCount == activeContainerCount || totalContainerCount  
1) {
+  // Everything OK
+  state = AlertState.OK;
+} else {
+  float fraction = (float) activeContainerCount / (float) 
totalContainerCount;
+  if (fraction = 0.2) { // less than or equal to 20%
+state = AlertState.WARNING;
+  } else {
+state = AlertState.CRITICAL;
+  }
+}
 alertItem.put(AlertField.description, String.format(%s 
component,component.getComponentName()));
 alertItem.put(AlertField.host_name, getComponentHostName(component));
 alertItem.put(AlertField.last_status, state);
@@ -78,7 +93,7 @@ public class SliderAppsAlerts {
 alertItem.put(AlertField.component_name, component.getComponentName());
 alertItem.put(AlertField.status, state);
 alertItem.put(AlertField.status_time, new 
java.sql.Timestamp(date.getTime()));
-alertItem.put(AlertField.output, state);
+alertItem.put(AlertField.output, message);
 alertItem.put(AlertField.actual_status, state);
 return alertItem;
   }
@@ -108,13 +123,4 @@ public class SliderAppsAlerts {
 }
 return null;
   }
-
-  private AlertState getComponentState(SliderAppComponent component){
-if (component.getInstanceCount() == 
component.getActiveContainers().size()){
-  return AlertState.OK;
-}
-return AlertState.CRITICAL;
-  }
-
-
 }

http://git-wip-us.apache.org/repos/asf/ambari/blob/00589244/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
--
diff --git 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
index 027f824..ef11cfa 100644
--- 
a/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
+++ 
b/contrib/views/slider/src/main/java/org/apache/ambari/view/slider/SliderAppsViewControllerImpl.java
@@ -319,9 +319,17 @@ public class SliderAppsViewControllerImpl implements 
SliderAppsViewController {
   containerId, containerDataMap);
 }
   }
+  // Set total instances count from statistics
   appComponent.setInstanceCount(appComponent
   .getActiveContainers().size()
   + appComponent.getCompletedContainers().size());
+