You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by yu...@apache.org on 2013/05/31 00:14:32 UTC

svn commit: r1488039 [9/10] - in /incubator/ambari/branches/branch-1.2.4: ./ ambari-agent/ ambari-agent/src/main/puppet/modules/hdp-ganglia/manifests/ ambari-agent/src/main/puppet/modules/hdp-ganglia/templates/ ambari-agent/src/main/puppet/modules/hdp-...

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/info/summary.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/info/summary.hbs?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/info/summary.hbs (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/info/summary.hbs Thu May 30 22:14:29 2013
@@ -48,25 +48,23 @@
                 {{#unless view.serviceStatus.hbase}}
                   {{#unless view.serviceStatus.ganglia}}
                     {{#unless view.serviceStatus.hue}}
-                      {{#unless view.serviceStatus.mapreduce2}}
-	                      {{#each component in view.components}}
-	                        <tr>
-	                          {{#if component.isMaster}}
-	                            <td class="summary-label">{{component.displayName}}</td>
-	                            <td><a {{action selectHost component.host}} href="javascript:void(null)">{{component.host.publicHostName}}</a></td>
-	                          {{else}}
-	                            <td class="summary-label">{{component.displayName}}s</td>
-	                            <td><a {{action filterHosts component}} href="javascript:void(null)">{{component.displayName}}s</a></td>
-	                          {{/if}}
-	                        </tr>
-	                      {{/each}}
-	                      {{#if view.serviceStatus.nagios}}
-	                        <tr>
-	                          <td class="summary-label">{{t services.service.info.summary.nagiosWebUI}}</td>
-	                          <td><a target=_blank href="http://{{unbound view.nagiosServer}}/nagios">{{view.nagiosServer}}/nagios</a></td>
-	                        </tr>
-	                      {{/if}}
-                      {{/unless}}
+                      {{#each component in view.components}}
+                        <tr>
+                          {{#if component.isMaster}}
+                            <td class="summary-label">{{component.displayName}}</td>
+                            <td><a {{action selectHost component.host}} href="javascript:void(null)">{{component.host.publicHostName}}</a></td>
+                          {{else}}
+                            <td class="summary-label">{{component.displayName}}s</td>
+                            <td><a {{action filterHosts component}} href="javascript:void(null)">{{component.displayName}}s</a></td>
+                          {{/if}}
+                        </tr>
+                      {{/each}}
+                      {{#if view.serviceStatus.nagios}}
+                        <tr>
+                          <td class="summary-label">{{t services.service.info.summary.nagiosWebUI}}</td>
+                          <td><a target=_blank href="http://{{unbound view.nagiosServer}}/nagios">{{view.nagiosServer}}/nagios</a></td>
+                        </tr>
+                      {{/if}}
                     {{/unless}}
                   {{/unless}}
                 {{/unless}}
@@ -81,9 +79,6 @@
       {{#if view.serviceStatus.mapreduce}}
         {{view App.MainDashboardServiceMapreduceView showOnlyRows=true serviceBinding="view.service"}}
       {{/if}}
-      {{#if view.serviceStatus.mapreduce2}}
-        {{template "templates/main/service/info/summary/mapreduce2"}}
-      {{/if}}
       {{#if view.serviceStatus.hbase}}
         {{view App.MainDashboardServiceHbaseView showOnlyRows=true serviceBinding="view.service"}}
       {{/if}}

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/reconfigure.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/reconfigure.hbs?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/reconfigure.hbs (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/main/service/reconfigure.hbs Thu May 30 22:14:29 2013
@@ -21,11 +21,11 @@
     {{#each stage in controller.stages}}
       {{#view App.StageStatusView}}
       <td>
-        {{#if stage.isPolling}}
+        {{#if controller.hasHostPopup}}
           <a  href="javascript:void(0)" {{action "showHostPopup" stage.label target="view"}}>
         {{/if}}
         <p {{bindAttr class="stage.hasStarted::faintText"}}>{{stage.label}}</p>
-        {{#if stage.isPolling}}
+        {{#if controller.hasHostPopup}}
           </a>
         {{/if}}
       </td>

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step13.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step13.hbs?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step13.hbs (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step13.hbs Thu May 30 22:14:29 2013
@@ -39,8 +39,8 @@
       <ul><em> <b>{{item.name}}</b></em>
 
         <div>
-          <ul>{{t installer.step13.oldValue}}: &nbsp;<span class="text text-info">{{item.oldValue}}</span></ul>
-          <ul>{{t installer.step13.newValue}}: <span class="text text-info">{{item.value}}</span></ul>
+          <ul>Old value: &nbsp;<span class="text text-info">{{item.oldValue}} {{#if item.unit}}{{item.unit}}{{/if}}</span></ul>
+          <ul>New value: <span class="text text-info">{{item.value}} {{#if item.unit}}{{item.unit}}{{/if}}</span></ul>
         </div>
 
       </ul>

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step9HostTasksLogPopup.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step9HostTasksLogPopup.hbs?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step9HostTasksLogPopup.hbs (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/templates/wizard/step9HostTasksLogPopup.hbs Thu May 30 22:14:29 2013
@@ -55,8 +55,8 @@
       <span class="task-detail-log-rolename" >{{{view.openedTask.role}} {{view.openedTask.command}}</span>
     </div>
     <div class="task-detail-ico-wrap">
-      <a title="Click to Copy" {{action "textTrigger" taskInfo target="view"}} class="task-detail-copy"><i class="icon-copy"></i> {{t common.copy}}</a>
-      <a title="Open in New Window" {{action openTaskLogInDialog}} class="task-detail-open-dialog"><i class="icon-external-link"></i> {{t common.open}}</a>
+      <div title="Click to Copy" {{action "textTrigger" taskInfo target="view"}} class="task-detail-copy"><i class="icon-copy"></i> {{t common.copy}}</div>
+      <div title="Open in New Window" {{action openTaskLogInDialog}} class="task-detail-open-dialog"><i class="icon-external-link"></i> {{t common.open}}</div>
     </div>
   </div>
   <div class="task-detail-log-info">

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/ajax.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/ajax.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/ajax.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/ajax.js Thu May 30 22:14:29 2013
@@ -201,7 +201,7 @@ var urls = {
   },
   'config.advanced': {
     'real': '{stack2VersionUrl}/stackServices/{serviceName}/configurations?fields=*',
-    'mock': '/data/wizard/stack/hdp/version{stackVersion}/{serviceName}.json',
+    'mock': '/data/wizard/stack/hdp/version130/{serviceName}.json',
     'format': function (data) {
       return {
         async: false
@@ -579,7 +579,7 @@ var urls = {
   },
   'wizard.service_components': {
     'real': '{stackUrl}/stackServices?fields=StackServices',
-    'mock': '/data/wizard/stack/hdp/version/{stackVersion}.json',
+    'mock': '/data/wizard/stack/hdp/version/1.3.0.json',
     'format': function (data, opt) {
       return {
         async: false

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/config.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/config.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/config.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/config.js Thu May 30 22:14:29 2013
@@ -17,7 +17,6 @@
  */
 
 var App = require('app');
-var stringUtils = require('utils/string_utils');
 
 var serviceComponents = {};
 var configGroupsByTag = [];
@@ -25,29 +24,9 @@ var globalPropertyToServicesMap = null;
 
 App.config = Em.Object.create({
 
-  preDefinedServiceConfigs: function(){
-    var configs = this.get('preDefinedConfigProperties');
-    var services = [];
-    require('data/service_configs').forEach(function(service){
-      service.configs = configs.filterProperty('serviceName', service.serviceName);
-      services.push(service);
-    });
-    return services;
-  }.property('preDefinedConfigProperties'),
-  configMapping: function() {
-      if (stringUtils.compareVersions(App.get('currentStackVersionNumber'), "2.0") === 1 ||
-        stringUtils.compareVersions(App.get('currentStackVersionNumber'), "2.0") === 0) {
-        return require('data/HDP2/config_mapping');
-      }
-    return require('data/config_mapping');
-  }.property('App.currentStackVersionNumber'),
-  preDefinedConfigProperties: function() {
-    if (stringUtils.compareVersions(App.get('currentStackVersionNumber'), "2.0") === 1 ||
-      stringUtils.compareVersions(App.get('currentStackVersionNumber'), "2.0") === 0) {
-      return require('data/HDP2/config_properties').configProperties;
-    }
-    return require('data/config_properties').configProperties;
-  }.property('App.currentStackVersionNumber'),
+  preDefinedServiceConfigs: require('data/service_configs'),
+  configMapping: require('data/config_mapping'),
+  preDefinedConfigProperties: require('data/config_properties').configProperties,
   preDefinedCustomConfigs: require('data/custom_configs'),
   //categories which contain custom configs
   categoriesWithCustom: ['CapacityScheduler'],
@@ -154,16 +133,15 @@ App.config = Em.Object.create({
       properties = (properties.length) ? properties.objectAt(0).properties : {};
       for (var index in properties) {
         var configsPropertyDef = preDefinedConfigs.findProperty('name', index) || null;
-        var serviceConfigObj = App.ServiceConfig.create({
+        var serviceConfigObj = {
           name: index,
           value: properties[index],
           defaultValue: properties[index],
           filename: _tag.siteName + ".xml",
           isUserProperty: false,
           isOverridable: true,
-          serviceName: serviceName,
-          belongsToService: []
-        });
+          serviceName: serviceName
+        };
 
         if (configsPropertyDef) {
           serviceConfigObj.displayType = configsPropertyDef.displayType;
@@ -175,7 +153,6 @@ App.config = Em.Object.create({
           serviceConfigObj.isOverridable = configsPropertyDef.isOverridable === undefined ? true : configsPropertyDef.isOverridable;
           serviceConfigObj.serviceName = configsPropertyDef ? configsPropertyDef.serviceName : null;
           serviceConfigObj.index = configsPropertyDef.index;
-          serviceConfigObj.belongsToService = configsPropertyDef.belongsToService;
         }
         // MAPREDUCE contains core-site properties but doesn't show them
         if(serviceConfigObj.serviceName === 'MAPREDUCE' && serviceConfigObj.filename === 'core-site.xml'){
@@ -271,13 +248,13 @@ App.config = Em.Object.create({
    * @param serviceName
    */
   addAdvancedConfigs: function (serviceConfigs, advancedConfigs, serviceName) {
-    var configsToVerifying = (serviceName) ? serviceConfigs.filterProperty('serviceName', serviceName) : serviceConfigs;
+    serviceConfigs = (serviceName) ? serviceConfigs.filterProperty('serviceName', serviceName) : serviceConfigs;
     advancedConfigs.forEach(function (_config) {
       var configCategory = 'Advanced';
       var categoryMetaData = null;
       if (_config) {
         if (this.get('configMapping').computed().someProperty('name', _config.name)) {
-        } else if (!(configsToVerifying.someProperty('name', _config.name))) {
+        } else if (!(serviceConfigs.someProperty('name', _config.name))) {
           if(this.get('customFileNames').contains(_config.filename)){
             categoryMetaData = this.identifyCategory(_config);
             if (categoryMetaData != null) {
@@ -369,14 +346,6 @@ App.config = Em.Object.create({
         break;
     }
   },
-
-  miscConfigVisibleProperty: function (configs, serviceToShow) {
-    configs.forEach(function(item) {
-      item.set("isVisible", item.belongsToService.some(function(cur){return serviceToShow.contains(cur)}));
-    });
-    return configs;
-  },
-
   /**
    * render configs, distribute them by service
    * and wrap each in ServiceConfigProperty object
@@ -453,7 +422,7 @@ App.config = Em.Object.create({
    * @param serviceName
    */
   createServiceConfig: function (serviceName) {
-    var preDefinedServiceConfig = App.config.get('preDefinedServiceConfigs').findProperty('serviceName', serviceName);
+    var preDefinedServiceConfig = App.config.preDefinedServiceConfigs.findProperty('serviceName', serviceName);
     var serviceConfig = App.ServiceConfig.create({
       filename: preDefinedServiceConfig.filename,
       serviceName: preDefinedServiceConfig.serviceName,
@@ -514,8 +483,7 @@ App.config = Em.Object.create({
       sender: this,
       data: {
         serviceName: serviceName,
-        stack2VersionUrl: App.get('stack2VersionURL'),
-        stackVersion: App.get('currentStackVersionNumber')
+        stack2VersionUrl: App.get('stack2VersionURL')
       },
       success: 'loadAdvancedConfigSuccess'
     });

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/date.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/date.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/date.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/date.js Thu May 30 22:14:29 2013
@@ -38,6 +38,24 @@ module.exports = {
     return days[date.getDay()] + ', ' + months[date.getMonth()] + ' ' + this.dateFormatZeroFirst(date.getDate()) + ', ' + date.getFullYear() + ' ' + this.dateFormatZeroFirst(date.getHours()) + ':' + this.dateFormatZeroFirst(date.getMinutes());
   },
   /**
+   * Convert date-string 'DAY_OF_THE_WEEK, MONTH DAY, YEAR HOURS:MINUTES' to timestamp
+   * @param date_string
+   * @return {String}
+   */
+  dateUnformat: function(date_string) {
+    var date = date_string.substring(4);
+    var month = date.substring(1, 4);
+    var day = date.substring(5, 7);
+    var year = date.substring(9, 13);
+    var hours = date.substring(14, 16);
+    var minutes = date.substring(17, 19);
+
+    var months = this.dateMonths;
+    month = months.indexOf(month) + 1;
+    if (month < 10) month = '0' + month;
+    return year + month + day + hours + minutes;
+  },
+  /**
    * Convert timestamp to date-string 'DAY_OF_THE_WEEK MONTH DAY YEAR'
    * @param timestamp
    * @return {*}
@@ -53,6 +71,60 @@ module.exports = {
     return date.toDateString();
   },
   /**
+   * Convert date-string 'DAY_OF_THE_WEEK MONTH DAY YEAR' to the timestamp
+   * @param date_string
+   * @return {Number}
+   */
+  dateUnformatShort: function(date_string) {
+    var date = new Date(date_string);
+    return date.getTime();
+  },
+  /**
+   * Convert time in mseconds to 'HOURS:MINUTES:SECONDS'
+   * @param ms_interval
+   * @return string formatted date
+   */
+  dateFormatInterval:function (ms_interval) {
+    if (!validator.isValidInt(ms_interval)) return ms_interval;
+    var hours = Math.floor(ms_interval / (60 * 60000));
+    var divisor_for_minutes = ms_interval % (60 * 60000);
+    var minutes = Math.floor(divisor_for_minutes / 60000);
+    var divisor_for_seconds = divisor_for_minutes % 60000;
+    var seconds = (divisor_for_seconds / 1000).toFixed(2);
+
+    return (hours < 10 ? '0' : '') + hours + ':' + (minutes < 10 ? '0' : '') + minutes + ':' + (seconds < 10 ? '0' : '') + seconds;
+  },
+  /**
+   * Convert 'HOURS:MINUTES:SECONDS' to time in mseconds
+   * @param formattedDate date string
+   * @return time in mseconds
+   */
+  dateUnformatInterval: function(formattedDate) {
+    var formattedDateArray = formattedDate.split(' ');
+
+    if (Object.prototype.toString.call( formattedDateArray ) === '[object Array]' && formattedDateArray.length == 2) {
+      var oneMinMs = 60000;
+      var oneHourMs = 3600000;
+      var oneDayMs = 86400000;
+
+      if (formattedDateArray['1'] == 'ms') {
+        return formattedDateArray['0'];
+      } else if (formattedDateArray['1'] == 'secs') {
+        return formattedDateArray['0'] * 1000;
+      } else if (formattedDateArray['1'] == 'mins') {
+        return formattedDateArray['0'] * oneMinMs;
+      } else if (formattedDateArray['1'] == 'hours') {
+        return formattedDateArray['0'] * oneHourMs;
+      } else if (formattedDateArray['1'] == 'days') {
+        return formattedDateArray['0'] * oneDayMs;
+      } else {
+        console.warn('function dateUnformatInterval: Undefined format');
+      }
+    } else {
+      console.warn('function dateUnformatInterval: formattedDateArray');
+    }
+  },
+  /**
    * Convert time in mseconds to
    * 30 ms = 30 ms
    * 300 ms = 300 ms
@@ -69,7 +141,6 @@ module.exports = {
    */
   timingFormat:function (time) {
     var intTime  = parseInt(time);
-    if (!intTime) return null;
     var timeStr = intTime.toString();
     var lengthOfNumber = timeStr.length;
     var oneMinMs = 60000;

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/db.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/db.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/db.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/db.js Thu May 30 22:14:29 2013
@@ -232,6 +232,12 @@ App.db.setSlaveComponentHosts = function
   localStorage.setObject('ambari', App.db.data);
 };
 
+App.db.setSlaveProperties = function (slaveProperties) {
+  App.db.data = localStorage.getObject('ambari');
+  App.db.data.Installer.slaveProperties = slaveProperties;
+  localStorage.setObject('ambari', App.db.data);
+};
+
 App.db.setServiceConfigs = function (serviceConfigs) {
   App.db.data = localStorage.getObject('ambari');
   App.db.data.Installer.serviceConfigs = serviceConfigs;
@@ -466,6 +472,11 @@ App.db.getServiceConfigProperties = func
   return App.db.data.Installer.configProperties;
 };
 
+App.db.getSlaveProperties = function () {
+  App.db.data = localStorage.getObject('ambari');
+  return App.db.data.Installer.slaveProperties;
+};
+
 App.db.getCluster = function () {
   console.log('TRACE: Entering db:getClusterStatus function');
   App.db.data = localStorage.getObject('ambari');

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/helper.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/helper.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/helper.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/helper.js Thu May 30 22:14:29 2013
@@ -203,8 +203,6 @@ Number.prototype.long2ip = function () {
  * @param {String} testUrl  URL to be used if app is not in test mode (!App.testMode)
  * @return {String} Formatted URL
  */
-App = require('app');
-
 App.formatUrl = function (urlTemplate, substitutes, testUrl) {
   var formatted = urlTemplate;
   if (urlTemplate) {
@@ -278,7 +276,7 @@ App.format = {
         return 'Resource Manager';
       case 'TEZ_CLIENT':
         return 'Tez Client';
-      case 'MAPREDUCE2_CLIENT':
+      case 'MAPREDUCEv2_CLIENT':
         return 'MapReduce2 Client';
       case 'YARN_CLIENT':
         return 'YARN Client';
@@ -363,4 +361,12 @@ App.format = {
   taskStatus:function (_taskStatus) {
     return _taskStatus.toLowerCase();
   }
-};
\ No newline at end of file
+};
+
+Array.prototype.removeAll = function(array){
+  var temp = array;
+  for(var i = 0 ; i < array.length ; i++ ){
+    temp = temp.without(array[i]);
+  }
+  return temp;
+};

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/string_utils.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/string_utils.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/string_utils.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/utils/string_utils.js Thu May 30 22:14:29 2013
@@ -59,45 +59,5 @@ module.exports = {
       return str[1].toUpperCase();
     }
     return new_name;
-  },
-  /**
-   * Compare two versions by following rules:
-   * first higher than second then return 1
-   * first lower than second then return -1
-   * first equal to second then return 0
-   * @param first {string}
-   * @param second {string}
-   * @return {number}
-   */
-  compareVersions: function(first, second){
-    if (!(typeof first === 'string' && typeof second === 'string')) {
-      return false;
-    }
-    var firstNumbers = first.split('.');
-    var secondNumbers = second.split('.');
-    var length = 0;
-    var i = 0;
-    var result = false;
-    if(firstNumbers.length === secondNumbers.length) {
-      length = firstNumbers.length;
-    } else if(firstNumbers.length < secondNumbers.length){
-      length = secondNumbers.length;
-    } else {
-      length = firstNumbers.length;
-    }
-
-    while(i < length && !result){
-      firstNumbers[i] = (firstNumbers[i] === undefined) ? 0 : window.parseInt(firstNumbers[i]);
-      secondNumbers[i] = (secondNumbers[i] === undefined) ? 0 : window.parseInt(secondNumbers[i]);
-      if(firstNumbers[i] > secondNumbers[i]){
-        result = 1;
-      } else if(firstNumbers[i] === secondNumbers[i]){
-        result = 0;
-      } else if(firstNumbers[i] < secondNumbers[i]){
-        result = -1;
-      }
-      i++;
-    }
-    return result;
   }
 }

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views.js Thu May 30 22:14:29 2013
@@ -75,7 +75,6 @@ require('views/main/dashboard');
 require('views/main/dashboard/service');
 require('views/main/dashboard/service/hdfs');
 require('views/main/dashboard/service/mapreduce');
-require('views/main/dashboard/service/mapreduce2');
 require('views/main/dashboard/service/hbase');
 require('views/main/dashboard/service/hive');
 require('views/main/dashboard/service/zookeeper');

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/configs/services_config.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/configs/services_config.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/configs/services_config.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/configs/services_config.js Thu May 30 22:14:29 2013
@@ -189,7 +189,7 @@ App.ServiceConfigsByCategoryView = Ember
         var name = this.get('name');
         if(name.trim() != ""){
           if(validator.isValidConfigKey(name)){
-            var configMappingProperty = App.config.get('configMapping').all().findProperty('name', name);
+            var configMappingProperty = App.config.configMapping.all().findProperty('name', name);
             if((configMappingProperty == null) && (!serviceConfigNames.contains(name))){
               this.set("isKeyError", false);
               this.set("errorMessage", "");
@@ -213,7 +213,7 @@ App.ServiceConfigsByCategoryView = Ember
     serviceConfigObj.category = category.get('name');
 
     var serviceName = this.get('service.serviceName');
-    var serviceConfigsMetaData = App.config.get('preDefinedServiceConfigs');
+    var serviceConfigsMetaData = require('data/service_configs');
     var serviceConfigMetaData = serviceConfigsMetaData.findProperty('serviceName', serviceName);
     var categoryMetaData = serviceConfigMetaData == null ? null : serviceConfigMetaData.configCategories.findProperty('name', category.get('name'));
     if (categoryMetaData != null) {

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/quick_view_link_view.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/quick_view_link_view.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/quick_view_link_view.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/common/quick_view_link_view.js Thu May 30 22:14:29 2013
@@ -29,18 +29,13 @@ App.QuickViewLinks = Em.View.extend({
     var host;
 
     if (serviceName === 'HDFS') {
-      host = App.singleNodeInstall ? App.singleNodeAlias : components.findProperty('componentName', 'NAMENODE').get('host.publicHostName');
+      host = components.findProperty('componentName', 'NAMENODE').get('host.publicHostName');
     } else if (serviceName === 'MAPREDUCE') {
-      host = App.singleNodeInstall ? App.singleNodeAlias : components.findProperty('componentName', 'JOBTRACKER').get('host.publicHostName');
+      host = components.findProperty('componentName', 'JOBTRACKER').get('host.publicHostName');
     } else if (serviceName === 'HBASE') {
       var component = components.filterProperty('componentName', 'HBASE_MASTER').findProperty('haStatus', 'active');
       if(component){
-        if(App.singleNodeInstall){
-          host = App.singleNodeAlias;
-        }else{
-          host = component.get('host.publicHostName');
-        }
-
+        host = component.get('host.publicHostName');
       }
     }
     if (!host) {

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/admin/cluster.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/admin/cluster.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/admin/cluster.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/admin/cluster.js Thu May 30 22:14:29 2013
@@ -17,12 +17,11 @@
  */
 
 var App = require('app');
-var stringUtils = require('utils/string_utils');
 
 App.MainAdminClusterView = Em.View.extend({
   templateName: require('templates/main/admin/cluster'),
 
   isUpgradeAvailable: function(){
-    return stringUtils.compareVersions(this.get('controller.upgradeVersion').replace(/HDP(Local)?-/, ''), App.get('currentStackVersionNumber')) === 1;
+    return this.get('controller.upgradeVersion').replace(/HDP-/, '') > App.currentStackVersion.replace(/HDP-/, '');
   }.property('controller.upgradeVersion', 'App.currentStackVersion')
 });
\ No newline at end of file

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard.js Thu May 30 22:14:29 2013
@@ -60,9 +60,6 @@ App.MainDashboardView = Em.View.extend({
           vName = App.MainDashboardServiceMapreduceView;
           item2 = App.MapReduceService.find(item.get('id'));
           break;
-        case "MAPREDUCE2":
-          vName = App.MainDashboardServiceMapreduce2View;
-          break;
         case "HBASE":
           vName = App.MainDashboardServiceHbaseView;
           item2 = App.HBaseService.find(item.get('id'));

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hbase.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hbase.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hbase.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hbase.js Thu May 30 22:14:29 2013
@@ -80,7 +80,7 @@ App.MainDashboardServiceHbaseView = App.
 
   hbaseMasterWebUrl: function () {
     if (this.get('activeMaster.host') && this.get('activeMaster.host').get('publicHostName')) {
-      return "http://" + (App.singleNodeInstall ? App.singleNodeAlias : this.get('activeMaster.host').get('publicHostName')) + ":60010";
+      return "http://" + this.get('activeMaster.host').get('publicHostName') + ":60010";
     }
   }.property('activeMaster'),
 

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hdfs.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hdfs.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hdfs.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/hdfs.js Thu May 30 22:14:29 2013
@@ -70,7 +70,7 @@ App.MainDashboardServiceHdfsView = App.M
   }.property("service.nameNodeStartTime"),
 
   nodeWebUrl: function () {
-    return "http://" + (App.singleNodeInstall ? App.singleNodeAlias :  this.get('service').get('nameNode').get('publicHostName')) + ":50070";
+    return "http://" + this.get('service').get('nameNode').get('publicHostName') + ":50070";
   }.property('service.nameNode'),
 
   nodeHeap: function () {

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/mapreduce.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/mapreduce.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/mapreduce.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/mapreduce.js Thu May 30 22:14:29 2013
@@ -22,7 +22,7 @@ App.MainDashboardServiceMapreduceView = 
   templateName: require('templates/main/dashboard/service/mapreduce'),
   serviceName: 'MAPREDUCE',
   jobTrackerWebUrl: function () {
-    return "http://" + (App.singleNodeInstall ? App.singleNodeAlias : this.get('service').get('jobTracker').get('publicHostName')) + ":50030";
+    return "http://" + this.get('service').get('jobTracker').get('publicHostName') + ":50030";
   }.property('service.nameNode'),
 
   Chart: App.ChartLinearView.extend({

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/oozie.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/oozie.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/oozie.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/dashboard/service/oozie.js Thu May 30 22:14:29 2013
@@ -23,7 +23,7 @@ App.MainDashboardServiceOozieView = App.
   templateName: require('templates/main/dashboard/service/oozie'),
 
   webUi: function () {
-    var hostName = App.singleNodeInstall ? App.singleNodeAlias : this.get('service.hostComponents').findProperty('componentName', 'OOZIE_SERVER').get('host.publicHostName');
+    var hostName = this.get('service.hostComponents').findProperty('componentName', 'OOZIE_SERVER').get('host.publicHostName');
     return "http://{0}:11000/oozie".format(hostName);
   }.property('service')
 });
\ No newline at end of file

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/host/summary.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/host/summary.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/host/summary.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/host/summary.js Thu May 30 22:14:29 2013
@@ -91,14 +91,14 @@ App.MainHostSummaryView = Em.View.extend
   didInsertElement: function () {
     this.loadDecommissionNodesList();
   },
-  sortedComponents: function () {
+  sortedComponents: function() {
     var slaveComponents = [];
     var masterComponents = [];
-    this.get('content.hostComponents').forEach(function (component) {
-      if (component.get('workStatus') != 'INSTALLING') {
-        if (component.get('isMaster')) {
+    this.get('content.hostComponents').forEach(function(component){
+      if(component.get('workStatus') != 'INSTALLING'){
+        if(component.get('isMaster')){
           masterComponents.push(component);
-        } else if (component.get('isSlave')) {
+        } else if(component.get('isSlave')) {
           slaveComponents.push(component);
         }
       }
@@ -106,16 +106,16 @@ App.MainHostSummaryView = Em.View.extend
     }, this);
     return masterComponents.concat(slaveComponents);
   }.property('content', 'content.hostComponents.length'),
-  clients: function () {
+  clients: function(){
     var clients = [];
-    this.get('content.hostComponents').forEach(function (component) {
-      if (!component.get('componentName')) {
+    this.get('content.hostComponents').forEach(function(component){
+      if(!component.get('componentName')){
         //temporary fix because of different data in hostComponents and serviceComponents
         return;
       }
       if (!component.get('isSlave') && !component.get('isMaster')) {
         if (clients.length) {
-          clients[clients.length - 1].set('isLast', false);
+          clients[clients.length-1].set('isLast', false);
         }
         component.set('isLast', true);
         clients.push(component);
@@ -126,21 +126,21 @@ App.MainHostSummaryView = Em.View.extend
 
   addableComponentObject: Em.Object.extend({
     componentName: '',
-    displayName: function () {
+    displayName: function(){
       return App.format.role(this.get('componentName'));
     }.property('componentName')
   }),
-  isAddComponent: function () {
+  isAddComponent: function(){
     return this.get('content.healthClass') !== 'health-status-DEAD-YELLOW';
   }.property('content.healthClass'),
-  addableComponents: function () {
+  addableComponents:function(){
     var components = [];
     var services = App.Service.find();
     var dataNodeExists = false;
     var taskTrackerExists = false;
     var regionServerExists = false;
 
-    this.get('content.hostComponents').forEach(function (component) {
+    this.get('content.hostComponents').forEach(function(component) {
       switch (component.get('componentName')) {
         case 'DATANODE':
           dataNodeExists = true;
@@ -173,96 +173,86 @@ App.MainHostSummaryView = Em.View.extend
         this.doBlinking();
       }
     },
-    hostComponent: function () {
+    hostComponent: function(){
       var hostComponent = null;
       var serviceComponent = this.get('content');
       var host = App.router.get('mainHostDetailsController.content');
-      if (host) {
+      if(host){
         hostComponent = host.get('hostComponents').findProperty('componentName', serviceComponent.get('componentName'));
       }
       return hostComponent;
     }.property('content', 'App.router.mainHostDetailsController.content'),
-    workStatus: function () {
+    workStatus: function(){
       var workStatus = this.get('content.workStatus');
       var hostComponent = this.get('hostComponent');
-      if (hostComponent) {
+      if(hostComponent){
         workStatus = hostComponent.get('workStatus');
       }
       return workStatus;
-    }.property('content.workStatus', 'hostComponent.workStatus'),
-
-    /**
-     * Return host component text status
-     */
-    componentTextStatus: function () {
-      var workStatus = this.get("workStatus");
-      var componentTextStatus = this.get('content.componentTextStatus');
-      var hostComponent = this.get('hostComponent');
-      if (hostComponent) {
-        componentTextStatus = hostComponent.get('componentTextStatus');
-        if(this.get("isDataNode"))
-          if(this.get('isDataNodeRecommissionAvailable')){
-            if(App.HostComponentStatus.started == workStatus){
-              componentTextStatus = "Decommissioning...";
-            }else if(App.HostComponentStatus.stopped == workStatus){
-              componentTextStatus = "Decommissioned";
-            }
-          }
-      }
-      return componentTextStatus;
-    }.property('workStatus','isDataNodeRecommissionAvailable'),
-
-    statusClass: function () {
+    }.property('content.workStatus','hostComponent.workStatus'),
+    statusClass: function(){
       var statusClass = null;
 
       //If the component is DataNode
-      if (this.get('isDataNode')) {
-        if (this.get('isDataNodeRecommissionAvailable') && (this.get('isStart') || this.get('workStatus') == 'INSTALLED')) {
+      if(this.get('isDataNode')){
+        if(this.get('isDataNodeRecommissionAvailable') && (this.get('isStart') || this.get('workStatus') == 'INSTALLED')){
+          // Orange is shown only when service is started/starting and it is decommissioned.
           return 'health-status-DEAD-ORANGE';
         }
       }
 
       //Class when install failed
-      if (this.get('workStatus') === App.HostComponentStatus.install_failed) {
+      if(this.get('workStatus') === App.HostComponentStatus.install_failed){
         return 'health-status-color-red icon-cog';
       }
 
       //Class when installing
-      if (this.get('workStatus') === App.HostComponentStatus.installing) {
+      if(this.get('workStatus') === App.HostComponentStatus.installing){
         return 'health-status-color-blue icon-cog';
       }
 
       //For all other cases
       return 'health-status-' + App.HostComponentStatus.getKeyName(this.get('workStatus'));
-    }.property('workStatus', 'isDataNodeRecommissionAvailable', 'this.content.isDecommissioning'),
+    }.property('workStatus', 'isDataNodeRecommissionAvailable','this.content.isDecommissioning'),
     /**
      * For Upgrade failed state
      */
-    isUpgradeFailed: function () {
+    isUpgradeFailed:function(){
       return App.HostComponentStatus.getKeyName(this.get('workStatus')) === "upgrade_failed";
     }.property("workStatus"),
     /**
      * For Install failed state
      */
-    isInstallFailed: function () {
+    isInstallFailed:function(){
       return App.HostComponentStatus.getKeyName(this.get('workStatus')) === "install_failed";
     }.property("workStatus"),
     /**
+     * Disable element while component is starting/stopping
+     */
+    disabledClass:function(){
+      var workStatus = this.get('workStatus');
+      if([App.HostComponentStatus.starting, App.HostComponentStatus.stopping, App.HostComponentStatus.unknown].contains(workStatus) ){
+        return 'disabled';
+      } else {
+        return '';
+      }
+    }.property('workStatus'),
+    /**
      * Do blinking for 1 minute
      */
-    doBlinking: function () {
+    doBlinking : function(){
       var workStatus = this.get('workStatus');
       var self = this;
       var pulsate = [ App.HostComponentStatus.starting, App.HostComponentStatus.stopping ].contains(workStatus);
       if (!pulsate && this.get('isDataNode')) {
         var dataNodeComponent = this.get('content');
-        if (dataNodeComponent && workStatus != "INSTALLED") {
+        if (dataNodeComponent && workStatus != "INSTALLED")  {
           pulsate = this.get('isDataNodeRecommissionAvailable');
         }
       }
       if (pulsate && !self.get('isBlinking')) {
         self.set('isBlinking', true);
-        uiEffects.pulsate(self.$('.components-health'), 1000, function () {
+        uiEffects.pulsate(self.$('.components-health'), 1000, function(){
           !self.get('isDestroyed') && self.set('isBlinking', false);
           self.doBlinking();
         });
@@ -271,42 +261,26 @@ App.MainHostSummaryView = Em.View.extend
     /**
      * Start blinking when host component is starting/stopping
      */
-    startBlinking: function () {
+    startBlinking:function(){
       this.$('.components-health').stop(true, true);
       this.$('.components-health').css({opacity: 1.0});
       this.doBlinking();
-    }.observes('workStatus','isDataNodeRecommissionAvailable'),
+    }.observes('workStatus'),
 
-    isStart: function () {
-      return (this.get('workStatus') == App.HostComponentStatus.started || this.get('workStatus') == App.HostComponentStatus.starting);
+    isStart : function() {
+      return (this.get('workStatus') === App.HostComponentStatus.started || this.get('workStatus') === App.HostComponentStatus.starting);
     }.property('workStatus'),
 
-    /**
-     * No action available while component is starting/stopping/unknown
-     */
-    noActionAvailable: function () {
-      var workStatus = this.get('workStatus');
-      if ([App.HostComponentStatus.starting, App.HostComponentStatus.stopping, App.HostComponentStatus.unknown].contains(workStatus)) {
-        return "hidden";
-      }else{
-        return "";
-      }
+    isInProgress : function() {
+      return (this.get('workStatus') === App.HostComponentStatus.stopping || this.get('workStatus') === App.HostComponentStatus.starting);
     }.property('workStatus'),
-
-    isInProgress: function () {
-      return (this.get('workStatus') === App.HostComponentStatus.stopping || this.get('workStatus') === App.HostComponentStatus.starting) || this.get('isDataNodeRecommissionAvailable');
-    }.property('workStatus', 'isDataNodeRecommissionAvailable'),
     /**
      * Shows whether we need to show Decommision/Recomission buttons
      */
-    isDataNode: function () {
+    isDataNode: function() {
       return this.get('content.componentName') === 'DATANODE';
     }.property('content'),
 
-    isDecommissioning: function () {
-      return this.get('isDataNode') &&  this.get("isDataNodeRecommissionAvailable");
-    }.property("workStatus", "isDataNodeRecommissionAvailable"),
-
     /**
      * Set in template via binding from parent view
      */
@@ -325,7 +299,7 @@ App.MainHostSummaryView = Em.View.extend
     isDataNodeRecommissionAvailable: function () {
       var decommissionHostNames = this.get('decommissionDataNodeHostNames');
       var hostName = App.router.get('mainHostDetailsController.content.hostName');
-      return decommissionHostNames != null && decommissionHostNames.contains(hostName);
+      return decommissionHostNames!=null && decommissionHostNames.contains(hostName);
     }.property('App.router.mainHostDetailsController.content', 'decommissionDataNodeHostNames')
 
   }),

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/menu.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/menu.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/menu.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/menu.js Thu May 30 22:14:29 2013
@@ -17,7 +17,6 @@
  */
 
 var App = require('app');
-var stringUtils = require('utils/string_utils');
 
 /**
  * this menu extended by other with modifying content and itemViewClass.template
@@ -31,17 +30,14 @@ App.MainMenuView = Em.CollectionView.ext
       { label:Em.I18n.t('menu.item.dashboard'), routing:'dashboard', active:'active'},
       { label:Em.I18n.t('menu.item.heatmaps'), routing:'charts'},
       { label:Em.I18n.t('menu.item.services'), routing:'services'},
-      { label:Em.I18n.t('menu.item.hosts'), routing:'hosts'}
+      { label:Em.I18n.t('menu.item.hosts'), routing:'hosts'},
+      { label:Em.I18n.t('menu.item.jobs'), routing:'apps'}
     ];
 
     if (App.supports.mirroring) {
       result.push({ label:Em.I18n.t('menu.item.mirroring'), routing:'mirroring'});
     }
 
-    if (stringUtils.compareVersions(App.get('currentStackVersionNumber'), "2.0") === -1) {
-      result.push({ label:Em.I18n.t('menu.item.jobs'), routing:'apps'});
-    }
-
     if (App.get('isAdmin')) {
       result.push({ label:Em.I18n.t('menu.item.admin'), routing:'admin'});
     }

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/info/summary.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/info/summary.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/info/summary.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/info/summary.js Thu May 30 22:14:29 2013
@@ -37,7 +37,6 @@ App.MainServiceInfoSummaryView = Em.View
   serviceStatus:{
     hdfs:false,
     mapreduce:false,
-    mapreduce2:false,
     hbase:false,
     zookeeper:false,
     oozie:false,
@@ -49,7 +48,7 @@ App.MainServiceInfoSummaryView = Em.View
 
   clients: function () {
     var service = this.get('controller.content');
-    if (["OOZIE", "ZOOKEEPER", "HIVE", "MAPREDUCE2"].contains(service.get("id"))) {
+    if (["OOZIE", "ZOOKEEPER", "HIVE"].contains(service.get("id"))) {
       return service.get('hostComponents').filterProperty('isClient');
     }
     return [];
@@ -150,7 +149,7 @@ App.MainServiceInfoSummaryView = Em.View
    */
   clientObj: function() {
     var service = this.get('controller.content');
-    if (["OOZIE", "ZOOKEEPER", "HIVE", "MAPREDUCE2"].contains(service.get("id"))) {
+    if (["OOZIE", "ZOOKEEPER", "HIVE"].contains(service.get("id"))) {
       var clients = service.get('hostComponents').filterProperty('isClient', true);
       if (clients.length > 0) {
         return clients[0];
@@ -174,7 +173,7 @@ App.MainServiceInfoSummaryView = Em.View
   getServer: function(serviceName) {
     var service=this.get('controller.content');
     if(service.get("id") == serviceName) {
-      return (App.singleNodeInstall ? App.singleNodeAlias : service.get("hostComponents").findProperty('isMaster', true).get("host").get("publicHostName"));
+      return service.get("hostComponents").findProperty('isMaster', true).get("host").get("publicHostName");
     }
     else {
       return '';

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/reconfigure.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/reconfigure.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/reconfigure.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/app/views/main/service/reconfigure.js Thu May 30 22:14:29 2013
@@ -19,7 +19,7 @@ var App = require('app');
 
 App.MainServiceReconfigureView = Em.View.extend({
 
-  templateName: require('templates/main/service/reconfigure')
+  templateName: require('templates/main/service/reconfigure'),
 
 });
 

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step2_test.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step2_test.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step2_test.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step2_test.js Thu May 30 22:14:29 2013
@@ -20,7 +20,6 @@ var App = require('app');
 var Ember = require('ember');
 require('controllers/wizard/step2_controller');
 require('models/host');
-require('models/host_component');
 require('messages');
 
 describe('App.WizardStep2Controller', function () {

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step5_test.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step5_test.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step5_test.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step5_test.js Thu May 30 22:14:29 2013
@@ -19,88 +19,166 @@
 var Ember = require('ember');
 var App = require('app');
 require('controllers/wizard/step5_controller');
-var components = require('data/service_components');
 
-
-describe('App.WizardStep5Controller', function () {
+/*
+describe('App.InstallerStep5Controller', function () {
+  var controller = App.InstallerStep5Controller.create();
+  controller.get("selectedServices").pushObject({service_name: 'ZOOKEEPER'});
   var cpu = 2, memory = 4;
+  var HOST = ['host1', 'host2', 'host3', 'host4', 'host5'];
+  var hosts = [];
+  HOST.forEach(function (_host) {
+    controller.get('hosts').pushObject(Ember.Object.create({
+      host_name: _host,
+      cpu: cpu,
+      memory: memory
+    }));
+  });
+
+  var componentObj = Ember.Object.create({
+    component_name: 'ZooKeeper',
+    selectedHost: 'host2', // call the method that plays selectNode algorithm or fetches from server
+    availableHosts: []
+  });
+  componentObj.set('availableHosts', controller.get('hosts').slice(0));
+  componentObj.set('zId', 1);
+  componentObj.set("showAddControl", true);
+  componentObj.set("showRemoveControl", false);
+  controller.get("selectedServicesMasters").pushObject(componentObj);
+
+
+  describe('#getAvailableHosts()', function () {
+    it('should generate available hosts for a new zookeeper service', function () {
+      var hostsForNewZookeepers = controller.getAvailableHosts("ZooKeeper"),
+        ok = true, i = 0, masters = null;
+
+      //test that the hosts found, do not have Zookeeper master assigned to them
+      for (i = 0; i < hostsForNewZookeepers.get("length"); i++) {
+        masters = controller.get("selectedServicesMasters").filterProperty(hostsForNewZookeepers[i].get("host_name"));
+        if (masters.findProperty("component_name", "ZooKeeper")) {
+          ok = false;
+          break;
+        }
+      }
 
-  var methods = ['getKerberosServer', 'getNameNode', 'getSNameNode', 'getJobTracker', 'getResourceManager', 'getHistoryServer', 'getHBaseMaster', 'getOozieServer', 'getHiveServer', 'getHiveMetastore', 'getWebHCatServer'];
+      expect(ok).to.equal(true);
+    })
 
-  var test_config = [
-    {
-      title: '1 host',
-      hosts: ['host0'],
-      equals: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
-    },
-    {
-      title: '2 hosts',
-      hosts: ['host0', 'host1'],
-      equals: [1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1]
-    },
-    {
-      title: '3 hosts',
-      hosts: ['host0', 'host1', 'host2'],
-      equals: [1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1]
-    },
-    {
-      title: '5 hosts',
-      hosts: ['host0', 'host1', 'host2', 'host3', 'host4'],
-      equals: [1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1]
-    },
-    {
-      title: '6 hosts',
-      hosts: ['host0', 'host1', 'host2', 'host3', 'host4', 'host6'],
-      equals: [3, 0, 1, 1, 1, 1, 2, 2, 2, 2, 2]
-    },
-    {
-      title: '10 hosts',
-      hosts: ['host0', 'host1', 'host2', 'host3', 'host4', 'host5', 'host6', 'host7', 'host8', 'host9'],
-      equals: [3, 0, 1, 1, 1, 1, 2, 2, 2, 2, 2]
-    },
-    {
-      title: '31 hosts',
-      hosts: ['host0', 'host1', 'host2', 'host3', 'host4', 'host5', 'host6', 'host7', 'host8', 'host9', 'host0', 'host1', 'host2', 'host3', 'host4', 'host5', 'host6', 'host7', 'host8', 'host9', 'host0', 'host1', 'host2', 'host3', 'host4', 'host5', 'host6', 'host7', 'host8', 'host9', 'host0'],
-      equals: [5, 0, 1, 2, 2, 2, 3, 3, 4, 4, 4]
-    }
-  ];
-
-  test_config.forEach(function(test) {
-    describe(test.title, function() {
-      var controller = App.WizardStep5Controller.create();
-      controller.clearStep();
-
-      test.hosts.forEach(function(_host) {
-        controller.get('hosts').pushObject(Em.Object.create({
-          host_name: _host,
-          cpu: cpu,
-          memory: memory
-        }));
-      });
+    it('should return all hosts for services other than ZooKeeper', function () {
+      var hostsForNewZookeepers = controller.getAvailableHosts("");
 
-      methods.forEach(function(method, index) {
-        it('#' + method + '()', function() {
-          expect(controller[method](test.hosts.length).host_name).to.equal(test.hosts[test.equals[index]]);
-        });
+      expect(hostsForNewZookeepers.get("length")).to.equal(controller.get("hosts.length"));
+    })
+  })
+
+  describe('#assignHostToMaster()', function () {
+    it('should assign the selected host to the non-ZooKeeper master service', function () {
+      //test non-zookeeper master
+      var SERVICE_MASTER = "NameNode",
+        HOST = "host4", ZID, status;
+      var nonZookeeperObj = Ember.Object.create({
+        component_name: SERVICE_MASTER,
+        selectedHost: HOST, // call the method that plays selectNode algorithm or fetches from server
+        availableHosts: []
       });
+      controller.get("selectedServicesMasters").pushObject(nonZookeeperObj);
+      controller.assignHostToMaster(SERVICE_MASTER, HOST);
+      expect(controller.get("selectedServicesMasters").findProperty("component_name", SERVICE_MASTER).get("selectedHost")).to.equal(HOST);
+    })
 
-    });
+    it('should assign the selected host to the ZooKeeper master service', function () {
+      //test non-zookeeper master
+      var SERVICE_MASTER = "ZooKeeper",
+        HOST = "host4", ZID = 2;
+
+      //test zookeeper master assignment with
+      if (controller.addZookeepers()) {
+        controller.assignHostToMaster(SERVICE_MASTER, HOST, ZID);
+        expect(controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").findProperty("zId", ZID).get("selectedHost")).to.equal(HOST);
+      }
+    })
+  })
 
-  });
+  describe('#addZookeepers()', function () {
+
+    it('should add a new ZooKeeper', function () {
+      var newLength = 0;
+      if (controller.get("selectedServices").mapProperty("service_name").contains("ZOOKEEPER")
+        && controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("length") < controller.get("hosts.length")) {
+        newLength = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("length");
+        controller.addZookeepers();
+        expect(controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("length")).to.equal(newLength + 1);
+      }
+    })
+
+    it('should add ZooKeepers up to the number of hosts', function () {
 
+      var currentZooKeepers = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").length,
+        success = true;
 
-  var controller = App.WizardStep5Controller.create();
-  controller.set('content', {});
+      //add ZooKeepers as long as possible
+      if (currentZooKeepers) {
 
-  describe('#isReassignWizard', function() {
-    it('true if content.controllerName is reassignMasterController', function() {
-      controller.set('content.controllerName', 'reassignMasterController');
-      expect(controller.get('isReassignWizard')).to.equal(true);
-    })
-    it('false if content.controllerName is not reassignMasterController', function() {
-      controller.set('content.controllerName', 'mainController');
-      expect(controller.get('isReassignWizard')).to.equal(false);
+        while (success) {
+          success = controller.addZookeepers();
+        }
+        var services = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper");
+        var length = services.length;
+        expect(controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").length).to.equal(controller.get("hosts.length"));
+      }
     })
-  });
+  })
+
+  describe('#removeZookeepers()', function () {
+    it('should remove a ZooKeeper', function () {
+      if (controller.get("selectedServices").mapProperty("service_name").contains("ZOOKEEPER")) {
+        if (controller.addZookeepers()) {
+          newLength = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("length");
+          controller.removeZookeepers(2);
+          expect(controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("length")).to.equal(newLength - 1);
+        }
+      }
+    })
+
+    it('should fail to remove a ZooKeeper if there is only 1', function () {
+      var currentZooKeepers = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").length,
+        success = true;
+      //remove ZooKeepers as long as possible
+
+      if (currentZooKeepers) {
+        while (success) {
+          success = controller.removeZookeepers(controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("lastObject.zId"));
+        }
+        expect(controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").get("length")).to.equal(1);
+      }
+    })
+
+  })
+
+  describe('#rebalanceZookeeperHosts()', function () {
+
+    it('should rebalance hosts for ZooKeeper', function () {
+      //assign a host to a zookeeper and then rebalance the available hosts for the other zookeepers
+      var zookeepers = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper"),
+        aZookeeper = null, aHost = null, i = 0, ok = true;
+
+      if (zookeepers.get("length") > 1) {
+        aZookeeper = controller.get("selectedServicesMasters").filterProperty("component_name", "ZooKeeper").findProperty("zId", 1);
+        aHost = aZookeeper.get("availableHosts")[0];
+        aZookeeper.set("selectedHost", aHost.get("host_name"));
+
+        controller.rebalanceZookeeperHosts();
+
+        for (i = 0; i < zookeepers.get("length"); i++) {
+          if (zookeepers[i].get("availableHosts").mapProperty("host_name").contains(aHost)) {
+            ok = false;
+            break;
+          }
+        }
+
+        expect(ok).to.equal(true);
+      }
+    })
+  })
 
-});
+})*/

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step6_test.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step6_test.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step6_test.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/test/installer/step6_test.js Thu May 30 22:14:29 2013
@@ -20,183 +20,135 @@ var Ember = require('ember');
 var App = require('app');
 require('controllers/wizard/step6_controller');
 
-describe('App.WizardStep6Controller', function () {
+/*
+describe('App.InstallerStep6Controller', function () {
 
-  var controller = App.WizardStep6Controller.create();
+  var HOSTS = [ 'host1', 'host2', 'host3', 'host4' ];
+  //App.InstallerStep6Controller.set.rawHosts = HOSTS;
+  var controller = App.InstallerStep6Controller.create();
+  controller.set('showHbase', false);
+  HOSTS.forEach(function (_hostName) {
+    controller.get('hosts').pushObject(Ember.Object.create({
+      hostname: _hostName,
+      isDataNode: true,
+      isTaskTracker: true,
+      isRegionServer: true
+    }));
+  });
+
+
+
+describe('#selectAllDataNodes()', function () {
+  controller.get('hosts').setEach('isDataNode', false);
+
+  it('should set isDataNode to true on all hosts', function () {
+    controller.selectAllDataNodes();
+    expect(controller.get('hosts').everyProperty('isDataNode', true)).to.equal(true);
+  })
+})
+
+describe('#selectAllTaskTrackers()', function () {
+  it('should set isTaskTracker to true on all hosts', function () {
+    controller.selectAllTaskTrackers();
+    expect(controller.get('hosts').everyProperty('isTaskTracker', true)).to.equal(true);
+  })
+})
+
+describe('#selectAllRegionServers()', function () {
+  it('should set isRegionServer to true on all hosts', function () {
+    controller.selectAllRegionServers();
+    expect(controller.get('hosts').everyProperty('isRegionServer', true)).to.equal(true);
+  })
+})
+
+describe('#isAllDataNodes()', function () {
+
+  beforeEach(function () {
+    controller.get('hosts').setEach('isDataNode', true);
+  })
+
+  it('should return true if isDataNode is true for all services', function () {
+    expect(controller.get('isAllDataNodes')).to.equal(true);
+  })
+
+  it('should return false if isDataNode is false for one host', function () {
+    controller.get('hosts')[0].set('isDataNode', false);
+    expect(controller.get('isAllDataNodes')).to.equal(false);
+  })
+})
+
+describe('#isAllTaskTrackers()', function () {
+
+  beforeEach(function () {
+    controller.get('hosts').setEach('isTaskTracker', true);
+  })
+
+  it('should return true if isTaskTracker is true for all hosts', function () {
+    expect(controller.get('isAllTaskTrackers')).to.equal(true);
+  })
+
+  it('should return false if isTaskTracker is false for one host', function () {
+    controller.get('hosts')[0].set('isTaskTracker', false);
+    expect(controller.get('isAllTaskTrackers')).to.equal(false);
+  })
+
+})
+
+describe('#isAllRegionServers()', function () {
+
+  beforeEach(function () {
+    controller.get('hosts').setEach('isRegionServer', true);
+  });
+
+  it('should return true if isRegionServer is true for all hosts', function () {
+    expect(controller.get('isAllRegionServers')).to.equal(true);
+  })
+
+  it('should return false if isRegionServer is false for one host', function () {
+    controller.get('hosts')[0].set('isRegionServer', false);
+    expect(controller.get('isAllRegionServers')).to.equal(false);
+  })
+
+})
+
+describe('#validate()', function () {
+
+  beforeEach(function () {
+    controller.get('hosts').setEach('isDataNode', true);
+    controller.get('hosts').setEach('isTaskTracker', true);
+    controller.get('hosts').setEach('isRegionServer', true);
+  });
+
+  it('should return false if isDataNode is false for all hosts', function () {
+    controller.get('hosts').setEach('isDataNode', false);
+    expect(controller.validate()).to.equal(false);
+  })
+
+  it('should return false if isTaskTracker is false for all hosts', function () {
+    controller.get('hosts').setEach('isTaskTracker', false);
+    expect(controller.validate()).to.equal(false);
+  })
+
+  it('should return false if isRegionServer is false for all hosts', function () {
+    controller.get('hosts').setEach('isRegionServer', false);
+    expect(controller.validate()).to.equal(false);
+  })
+
+  it('should return true if isDataNode, isTaskTracker, and isRegionServer is true for all hosts', function () {
+    expect(controller.validate()).to.equal(true);
+  })
+
+  it('should return true if isDataNode, isTaskTracker, and isRegionServer is true for only one host', function () {
+    controller.get('hosts').setEach('isDataNode', false);
+    controller.get('hosts').setEach('isTaskTracker', false);
+    controller.get('hosts').setEach('isRegionServer', false);
+    var host = controller.get('hosts')[0];
+    host.set('isDataNode', true);
+    host.set('isTaskTracker', true);
+    host.set('isRegionServer', true);
+    expect(controller.validate()).to.equal(true);
+  })
 
-  controller.set('content', {
-    hosts: {},
-    masterComponentHosts: {},
-    services: [
-      Em.Object.create({
-        serviceName: 'MAPREDUCE',
-        isSelected: true
-      }),
-      Em.Object.create({
-        serviceName: 'YARN',
-        isSelected: true
-      }),
-      Em.Object.create({
-        serviceName: 'HBASE',
-        isSelected: true
-      })
-    ]
-  });
-
-  var HOSTS = [ 'host0', 'host1', 'host2', 'host3' ];
-
-  var h = {};
-  var m = [];
-  HOSTS.forEach(function (hostName) {
-    var obj = Em.Object.create({
-      name: hostName,
-      hostName: hostName,
-      bootStatus: 'REGISTERED'
-    });
-    h[hostName] = obj;
-    m.push(obj);
-  });
-
-  controller.set('content.hosts', h);
-  controller.set('content.masterComponentHosts', m);
-  controller.set('isMasters', false);
-
-
-  describe('#loadStep', function() {
-    controller.loadStep();
-    it('Hosts are loaded', function() {
-      expect(controller.get('hosts').length).to.equal(HOSTS.length);
-    });
-
-    it('Headers are loaded', function() {
-      expect(controller.get('headers').length).not.to.equal(0);
-    });
-  });
-
-  describe('#isAddHostWizard', function() {
-    it('true if content.controllerName is addHostController', function() {
-      controller.set('content.controllerName', 'addHostController');
-      expect(controller.get('isAddHostWizard')).to.equal(true);
-    });
-    it('false if content.controllerName is not addHostController', function() {
-      controller.set('content.controllerName', 'mainController');
-      expect(controller.get('isAddHostWizard')).to.equal(false);
-    });
-  });
-
-  describe('#isInstallerWizard', function() {
-    it('true if content.controllerName is addHostController', function() {
-      controller.set('content.controllerName', 'installerController');
-      expect(controller.get('isInstallerWizard')).to.equal(true);
-    });
-    it('false if content.controllerName is not addHostController', function() {
-      controller.set('content.controllerName', 'mainController');
-      expect(controller.get('isInstallerWizard')).to.equal(false);
-    });
-  });
-
-  describe('#hasMasterComponents', function() {
-    HOSTS.forEach(function(host) {
-      it('Host ' + host + ' is master', function() {
-        expect(controller.hasMasterComponents(host)).to.equal(true);
-      });
-    });
-    var notMasterHost = 'NotMasterHost';
-    it('Host ' + notMasterHost + ' is not master', function() {
-      expect(controller.hasMasterComponents(notMasterHost)).to.equal(false);
-    });
-  });
-
-  describe('#setAllNodes', function() {
-
-    var test_config = [
-      {
-        title: 'DataNode',
-        state: false
-      },
-      {
-        title: 'DataNode',
-        state: true
-      },
-      {
-        title: 'TaskTracker',
-        state: false
-      },
-      {
-        title: 'TaskTracker',
-        state: true
-      }
-    ];
-
-    test_config.forEach(function(test) {
-      it((test.state?'Select':'Deselect') + ' all ' + test.title, function() {
-        controller.setAllNodes(test.title, test.state);
-        var hosts = controller.get('hosts');
-        hosts.forEach(function(host) {
-          expect(host.get('checkboxes').findProperty('title', test.title).get('checked')).to.equal(test.state);
-        });
-      });
-    });
-
-
-  });
-
-  describe('#isServiceSelected', function() {
-    controller.get('content.services').forEach(function(service) {
-      it(service.serviceName + ' is selected', function() {
-        expect(controller.isServiceSelected(service.serviceName)).to.equal(true);
-      });
-    });
-    var unselectedService = 'FAKESERVICE';
-    it(unselectedService + ' is not selected', function() {
-      expect(controller.isServiceSelected(unselectedService)).to.equal(false);
-    });
-  });
-
-  describe('#validateEachComponent', function() {
-    it('Nothing checked', function() {
-      controller.get('hosts').forEach(function(host) {
-        host.get('checkboxes').setEach('checked', false);
-      });
-      expect(controller.validateEachComponent('')).to.equal(false);
-    });
-    it('One slave is not selected for no one host', function() {
-      controller.get('hosts').forEach(function(host) {
-        host.get('checkboxes').forEach(function(checkbox, index) {
-          checkbox.set('checked', index === 0);
-        });
-      });
-      expect(controller.validateEachComponent('')).to.equal(false);
-    });
-    it('All checked', function() {
-      controller.get('hosts').forEach(function(host) {
-        host.get('checkboxes').forEach(function(checkbox) {
-          checkbox.set('checked', true);
-        });
-      });
-      expect(controller.validateEachComponent('')).to.equal(true);
-    });
-  });
-
-  describe('#validateEachHost', function() {
-    it('Nothing checked', function() {
-      controller.get('hosts').forEach(function(host) {
-        host.get('checkboxes').setEach('checked', false);
-      });
-      expect(controller.validateEachHost('')).to.equal(false);
-    });
-    it('One host doesn\'t have assigned slaves', function() {
-      controller.get('hosts').forEach(function(host, index) {
-        host.get('checkboxes').setEach('checked', index === 0);
-      });
-      expect(controller.validateEachHost('')).to.equal(false);
-    });
-    it('All checked', function() {
-      controller.get('hosts').forEach(function(host) {
-        host.get('checkboxes').setEach('checked', true);
-      });
-      expect(controller.validateEachHost('')).to.equal(true);
-    });
-  });
+})
 
-});
+})*/

Modified: incubator/ambari/branches/branch-1.2.4/ambari-web/test/utils/string_utils_test.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/ambari-web/test/utils/string_utils_test.js?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/ambari-web/test/utils/string_utils_test.js (original)
+++ incubator/ambari/branches/branch-1.2.4/ambari-web/test/utils/string_utils_test.js Thu May 30 22:14:29 2013
@@ -53,20 +53,4 @@ describe('string_utils', function () {
     });
   });
 
-  describe('#compareVersions', function () {
-    var tests = [
-      {m: '1.2 equal to 1.2', v1:'1.2', v2:'1.2', e: 0},
-      {m: '1.2 lower than 1.3', v1:'1.2', v2:'1.3', e: -1},
-      {m: '1.3 higher than 1.2', v1:'1.3', v2:'1.2', e: 1},
-      {m: '1.2.1 higher than 1.2', v1:'1.2.1', v2:'1.2', e: 1},
-      {m: '11.2 higher than 2.2', v1:'11.2', v2:'2.2', e: 1},
-      {m: '0.9 higher than 0.8', v1:'0.9', v2:'0.8', e: 1}
-    ];
-    tests.forEach(function(test) {
-      it(test.m + ' ', function () {
-        expect(string_utils.compareVersions(test.v1, test.v2)).to.equal(test.e);
-      });
-    });
-  });
-
 });

Modified: incubator/ambari/branches/branch-1.2.4/docs/pom.xml
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/docs/pom.xml?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/docs/pom.xml (original)
+++ incubator/ambari/branches/branch-1.2.4/docs/pom.xml Thu May 30 22:14:29 2013
@@ -28,7 +28,7 @@
     <modelVersion>4.0.0</modelVersion>
 
     <groupId>org.apache.ambari</groupId>
-    <version>1.2.2-SNAPSHOT</version>
+    <version>1.2.0-SNAPSHOT</version>
     <artifactId>ambari</artifactId>
     <packaging>pom</packaging>
 
@@ -118,18 +118,6 @@
                 <role>PMC</role>
             </roles>
         </developer>
-        <developer>
-            <id>billie</id>
-            <name>Billie Rinaldi</name>
-            <email>billie@apache.org</email>
-            <timezone>-8</timezone>
-            <roles>
-                <role>Committer</role>
-            </roles>
-            <organization>
-                Hortonworks
-            </organization>
-        </developer>
         <developer>            
             <id>ddas</id>
             <name>Devaraj Das</name>
@@ -237,19 +225,7 @@
             <organization>
                 Hortonworks                
             </organization>            
-        </developer>
-        <developer>
-            <id>ncole</id>
-            <name>Nate Cole</name>
-            <email>ncole@apache.org</email>
-            <timezone>-8</timezone>
-            <roles>
-                <role>Committer</role>
-            </roles>
-            <organization>
-                Hortonworks
-            </organization>
-        </developer>
+        </developer>              
         <developer>
             <id>ramya</id>
             <name>Ramya Sunil</name>
@@ -275,30 +251,6 @@
             </organization>            
         </developer>
         <developer>
-            <id>smohanty</id>
-            <name>Sumit Mohanty</name>
-            <email>smohanty@apache.org</email>
-            <timezone>-8</timezone>
-            <roles>
-                <role>Committer</role>
-            </roles>
-            <organization>
-                Hortonworks
-            </organization>
-        </developer>
-        <developer>
-            <id>swagle</id>
-            <name>Siddharth Wagle</name>
-            <email>swagle@apache.org</email>
-            <timezone>-8</timezone>
-            <roles>
-                <role>Committer</role>
-            </roles>
-            <organization>
-                Hortonworks
-            </organization>
-        </developer>
-        <developer>
             <id>srimanth</id>
             <name>Srimanth Gunturi</name>
             <email>srimanth@apache.org</email>

Modified: incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/index.apt
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/index.apt?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/index.apt (original)
+++ incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/index.apt Thu May 30 22:14:29 2013
@@ -15,20 +15,26 @@
 ~~
 Introduction
 
-  The Apache Ambari project is aimed at making Hadoop management simpler by developing software for provisioning, managing, and monitoring Apache Hadoop clusters.
-  Ambari provides an intuitive, easy-to-use Hadoop management web UI backed by its RESTful APIs.
+  Apache Ambari is a web-based tool for provisioning, managing, and monitoring Apache Hadoop clusters. The set of
+  Hadoop components that are currently supported by Ambari includes:
 
-  The set of Hadoop components that are currently supported by Ambari includes:
+  * {{{http://hadoop.apache.org/docs/hdfs} Apache Hadoop - HDFS}}
 
-  {{{http://hadoop.apache.org/docs/hdfs} HDFS}},
-  {{{http://hadoop.apache.org/docs/mapreduce} MapReduce}},
-  {{{http://hive.apache.org} Hive}},
-  {{{http://incubator.apache.org/hcatalog} HCatalog}},
-  {{{http://hbase.apache.org} HBase}},
-  {{{http://zookeeper.apache.org} ZooKeeper}},
-  {{{http://incubator.apache.org/oozie/} Oozie}},
-  {{{http://pig.apache.org} Pig}},
-  {{{http://sqoop.apache.org} Sqoop}}
+  * {{{http://hadoop.apache.org/docs/mapreduce} Apache Hadoop - MapReduce}}
+
+  * {{{http://hive.apache.org} Apache Hive}}
+
+  * {{{http://incubator.apache.org/hcatalog} Apache HCatalog}}
+
+  * {{{http://hbase.apache.org} Apache HBase}}
+
+  * {{{http://zookeeper.apache.org} Apache Zookeeper}}
+
+  * {{{http://incubator.apache.org/oozie/} Apache Oozie}}
+
+  * {{{http://pig.apache.org} Apache Pig}}
+
+  * {{{http://sqoop.apache.org} Apache Sqoop}}
 
   []
 
@@ -36,7 +42,7 @@ Introduction
 
   * Provision a Hadoop Cluster
   
-    * Ambari provides a step-by-step wizard for installing Hadoop services across any number of hosts.
+    * Ambari provides an easy-to-use, step-by-step wizard for installing Hadoop services across any number of hosts.
     
     * Ambari handles configuration of Hadoop services for the cluster.
 
@@ -55,41 +61,52 @@ Introduction
     * Ambari leverages {{{http://ganglia.sourceforge.net/} Ganglia}} for metrics collection.
 
     * Ambari leverages {{{http://www.nagios.org/} Nagios}} for system alerting and will send emails when your attention is needed (e.g., a node goes down, remaining disk space is low, etc).
-
+  
   []
 
-  Ambari enables Application Developers and System Integrators to:
+Ambari Source
 
-  * Easily integrate Hadoop provisioning, management, and monitoring capabilities to their own applications with the {{{https://github.com/apache/ambari/blob/trunk/ambari-server/docs/api/v1/index.md} Ambari REST APIs}}.
+  Follow the  {{{./1.2.0/installing-hadoop-using-ambari/content/index.html} installation guide for 1.2.0 (stable)}} or check out the work going on in {{{./whats-new.html} trunk}} for the upcoming 1.2.1 release.
 
-Getting Started with Ambari
+Roadmap
 
-  Follow the {{{./1.2.2/installing-hadoop-using-ambari/content/index.html} installation guide for Ambari 1.2.2}}.
+  * Support for additional Operating Systems
 
-  Note: Ambari currently supports the 64-bit version of the following Operating Systems:
+    * Ambari currently supports 64-bit RHEL/CentOS 5 + 6 and SLES 11
 
-  * RHEL (Redhat Enterprise Linux) 5 and 6
+  []
+
+  * RESTful API for integration
+  
+    * Ambari will expose a unified, RESTful API to enable third-party applications to integrate
+      Hadoop cluster management and monitoring capabilities (1.2.0)
+
+  []
 
-  * CentOS 5 and 6
+  * Granular configurations
 
-  * OEL (Oracle Enterprise Linux) 5 and 6
+      * Ambari currently applies service configurations at the cluster-level. For more
+        flexibility, Ambari will allow for configurations in a more granular manner, such as
+        applying a set of configurations to a specific group of hosts.
 
-  * SLES (SuSE Linux Enterprise Server) 11
+  []
 
-Get Involved
+  * Security
 
-  Visit the {{{https://cwiki.apache.org/confluence/display/AMBARI/Ambari} Ambari Wiki}} for design documents, roadmap, development guidelines, etc.
+      * Installation of secure Hadoop clusters (Kerberos-based)
 
-  {{{http://www.meetup.com/Apache-Ambari-User-Group} Join the Ambari User Meetup Group}}.  You can {{{http://www.meetup.com/Apache-Ambari-User-Group/events/109316812/} see the slides and WebEx session from the last Meetup}}.
+      * Role-based user authentication, authorization, and auditing
 
-  On June 25, 2013, Ambari BoF session will be held at San Jose Convention Center. {{{http://www.meetup.com/Apache-Ambari-User-Group/events/119184782/} RSVP now to reserve your spot}}.
+      * Support for LDAP and Active Directory (1.2.0)
 
-What's New?
+  []
 
-  Check out the work going on for the {{{./whats-new.html} upcoming releases}}.
+  * Visualization
 
-Disclaimer
+      * Interactive visualization of the current state of the cluster for a number of key metrics (1.2.0)
 
-  Apache Ambari is an effort undergoing incubation at The Apache Software Foundation (ASF) sponsored by the Apache Incubator PMC. Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects. While incubation status is not necessarily a reflection of the completeness or stability of the code, it does indicate that the project has yet to be fully endorsed by the ASF.
+      * Interactive visualization of historical states of the cluster for a number of key metrics
 
+      * Interactive visualization of Pig, Hive, and MapReduce jobs (1.2.0)
 
+  []

Modified: incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/whats-new.apt
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/whats-new.apt?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/whats-new.apt (original)
+++ incubator/ambari/branches/branch-1.2.4/docs/src/site/apt/whats-new.apt Thu May 30 22:14:29 2013
@@ -14,55 +14,28 @@
 ~~ limitations under the License.
 ~~
 
-What's New with Ambari?
+What's New?
 
- * Upcoming 1.2.3 release features the following:
+  There’s a lot of activity occurring in trunk. We’ve had a great response from the
+  community and received a lot of input into the direction. To date, we have added
+  many new features. To highlight a few...
 
-   * Improved general stability
+  * Added more options on provisioning so you can better target your cluster
+    setup for your needs
 
-   * Ability to update core-site.xml properties
+  * More service controls, including the ability to run ad hoc smoke tests
 
-   * Add + remove custom configuration properties
+  * Exposed a RESTful API for cluster metrics (with management and
+    provisioning to follow)
 
-   * New Heatmaps (Host > CPU WIO %, HBase > RegionServer Reads/Writes/Regions/QueueSize/MemstoreSize)
+  * Moved to a JavaScript front-end for Ambari Web and refreshed the entire UI
+    experience
 
-   * Add host components on existing hosts
+  * Used that RESTful API and added more charts and heatmaps to the dashboard
 
-   * Filter hosts by host health status
-
-   * Mixed OS support
-
-   * init.d scripts
-
-   * Support for Oracle Enterprise Linux 5 and 6
-
-
- * Ambari 1.2.4 will feature:
-
-   * Ability to use a non-root, sudo user to install Ambari agents
-
-   * MySQL and Oracle database support for Ambari (in addition to Postgres)
-
-   * Oracle database support for Hive Metastore (in addition to MySQL)
-
-   * MySQL and Oracle database support for Oozie (in addition to Derby)
-
-   * Ability to select which stack to deploy
-
-
- * Ambari 1.2.5 will feature:
-
-   * A wizard to configure and manage a secure cluster via Kerberos
-
-   * Support for configuring and running Ambari Web Server https
-
-   * Run Ambari Server as a non-root user
-
-   * Audit capture of login and config changes
-
-
- * Ambari 1.4.0 will support Hadoop 2.0.  This work is going on under the {{{https://svn.apache.org/repos/asf/incubator/ambari/branches/branch-1.4.0} 1.4.0 branch}}.
+  * Reduced the number of dependencies on the Ambari Server + Ambari Agent
 
+  * Added support for SLES 11
 
 Getting Ambari Source
 
@@ -74,14 +47,14 @@ $ svn checkout http://svn.apache.org/rep
 
 JIRA
 
-  You can follow all the work going on by watching the Ambari JIRA project. You can see the
-  JIRA details for Ambari here:
+  You can follow all the work going on by watching the Ambari JIRA project. The next release of Apache Ambari will be version 1.2.1. You can see the
+  JIRA details for this release here:
 
-  {{{https://issues.apache.org/jira/issues/?jql=project%20%3D%20AMBARI} https://issues.apache.org/jira/issues/?jql=project%20%3D%20AMBARI}}
+  {{{https://issues.apache.org/jira/issues/?jql=fixVersion%20%3D%20%221.2.1%22%20AND%20project%20%3D%20AMBARI} https://issues.apache.org/jira/issues/?jql=fixVersion%20%3D%20%221.2.1%22%20AND%20project%20%3D%20AMBARI}}
 
 User Guide
 
-  Take a look at {{{http://incubator.apache.org/ambari/1.2.3/installing-hadoop-using-ambari/content/index.html} how to install a Hadoop cluster using Ambari 1.2.3}}.
+  {{{http://incubator.apache.org/ambari/1.2.1/installing-hadoop-using-ambari/content/index.html} See how to install a Hadoop cluster using Ambari 1.2.1}}
 
 Stay Tuned
 

Modified: incubator/ambari/branches/branch-1.2.4/docs/src/site/site.xml
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/branch-1.2.4/docs/src/site/site.xml?rev=1488039&r1=1488038&r2=1488039&view=diff
==============================================================================
--- incubator/ambari/branches/branch-1.2.4/docs/src/site/site.xml (original)
+++ incubator/ambari/branches/branch-1.2.4/docs/src/site/site.xml Thu May 30 22:14:29 2013
@@ -28,9 +28,7 @@
   <custom>
     <fluidoSkin>
       <topBarEnabled>true</topBarEnabled>
-      <sideBarEnabled>true</sideBarEnabled>
-      <leftColumnClass>span2</leftColumnClass>
-      <bodyColumnClass>span10</bodyColumnClass>
+      <sideBarEnabled>false</sideBarEnabled>
     </fluidoSkin>
   </custom>
   <bannerLeft>
@@ -61,63 +59,38 @@
           })();
        </script>
        <!-- End of Google analytics -->
-       <style>
-           .well.sidebar-nav {
-             background-color: #fff;
-           }
-           a.externalLink[href^=http] {
-             background-image: none;
-             padding-right: 0;
-           }
-           body.topBarEnabled {
-             padding-top: 40px;
-           }
-           #leftColumn .nav-list .active a {
-             background-color: #a0a0a0;
-           }
-           .nav-list .active a:hover {
-             background-color: #a0a0a0;
-           }
-       </style>
     </head>
 
     <links>
       <item name="JIRA" href="https://issues.apache.org/jira/browse/AMBARI" />
       <item name="SVN" href="https://svn.apache.org/repos/asf/incubator/ambari/" />
-      <item name="Wiki" href="https://cwiki.apache.org/confluence/display/AMBARI/Ambari" />
+      <item name="WIKI" href="https://cwiki.apache.org/confluence/display/AMBARI/Ambari" />
     </links>
 
     <breadcrumbs>
-      <item name="Incubator" href="../"/>
-      <item name="Ambari" href="http://incubator.apache.org/ambari/"/>
+      <item name="Ambari" href="index.html"/>
     </breadcrumbs>
 
     <menu name="Ambari">
-      <item name="Overview" href="index.html"/>
       <item name="What's New?" href="whats-new.html"/>
+      <item name="About" href="index.html"/>
+      <item name="Wiki" href="https://cwiki.apache.org/confluence/display/AMBARI/Ambari"/>
       <item name="Project Team" href="team-list.html"/>
-      <item name="IRC Channel" href="irc.html"/>
       <item name="Mailing Lists" href="mail-lists.html"/>
       <item name="Issue Tracking" href="issue-tracking.html"/>
-      <item name="User Group" href="http://www.meetup.com/Apache-Ambari-User-Group"/>
-      <item name="Project License" href="http://www.apache.org/licenses/"/>
+      <item name="Project License" href="license.html"/>
     </menu>
 
     <menu name="Releases">
-        <item name="1.2.2" href="http://www.apache.org/dist/incubator/ambari/ambari-1.2.2/"/>
-        <item name="1.2.1" href="http://www.apache.org/dist/incubator/ambari/ambari-1.2.1/"/>
+        <item name="1.2.1 (coming soon)" href="whats-new.html"/>
         <item name="1.2.0" href="http://www.apache.org/dist/incubator/ambari/ambari-1.2.0/"/>
         <item name="0.9" href="http://www.apache.org/dist/incubator/ambari/ambari-0.9-incubating/"/>
     </menu>
 
     <menu name="Documentation">
-        <item name="Install Guide for 1.2.3 RC" href="1.2.3/installing-hadoop-using-ambari/content/index.html"/>
-        <item name="Install Guide for 1.2.2" href="1.2.2/installing-hadoop-using-ambari/content/index.html"/>
         <item name="Install Guide for 1.2.1" href="1.2.1/installing-hadoop-using-ambari/content/index.html"/>
         <item name="Install Guide for 1.2.0" href="1.2.0/installing-hadoop-using-ambari/content/index.html"/>
         <item name="Install Guide for 0.9" href="install-0.9.html"/>
-        <item name="API Reference" href="https://github.com/apache/ambari/blob/trunk/ambari-server/docs/api/v1/index.md"/>
-        <item name="Wiki" href="https://cwiki.apache.org/confluence/display/AMBARI/Ambari"/>
     </menu>
 
     <footer>