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/04/06 03:55:47 UTC

svn commit: r1465166 [11/15] - in /incubator/ambari/trunk: ./ ambari-web/app/ ambari-web/app/assets/data/background_operations/ ambari-web/app/assets/data/clusters/ ambari-web/app/assets/data/configurations/ ambari-web/app/assets/data/dashboard/ ambari...

Modified: incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js (original)
+++ incubator/ambari/trunk/ambari-web/app/routes/add_service_routes.js Sat Apr  6 01:55:42 2013
@@ -51,6 +51,30 @@ module.exports = Em.Route.extend({
             this.fitHeight();
           }
         });
+
+        App.clusterStatus.updateFromServer();
+        var currentClusterStatus = App.clusterStatus.get('value');
+
+        if (currentClusterStatus) {
+          switch (currentClusterStatus.clusterState) {
+            case 'ADD_SERVICES_DEPLOY_PREP_2' :
+              addServiceController.setCurrentStep('5');
+              App.db.data = currentClusterStatus.localdb;
+              break;
+            case 'ADD_SERVICES_INSTALLING_3' :
+            case 'SERVICE_STARTING_3' :
+              addServiceController.setCurrentStep('6');
+              App.db.data = currentClusterStatus.localdb;
+              break;
+            case 'ADD_SERVICES_INSTALLED_4' :
+              addServiceController.setCurrentStep('7');
+              App.db.data = currentClusterStatus.localdb;
+              break;
+            default:
+              break;
+          }
+        }
+
         router.transitionTo('step' + addServiceController.get('currentStep'));
       });
     } else {
@@ -121,6 +145,8 @@ module.exports = Em.Route.extend({
       controller.dataLoading().done(function () {
         controller.loadAllPriorSteps();
         controller.connectOutlet('wizardStep6', controller.get('content'));
+        var wizardStep6Controller = router.get('wizardStep6Controller');
+        wizardStep6Controller.set('isMasters', false);
       })
     },
     back: function(router){
@@ -192,6 +218,9 @@ module.exports = Em.Route.extend({
       var wizardStep8Controller = router.get('wizardStep8Controller');
       addServiceController.installServices();
       addServiceController.setInfoForStep9();
+
+      addServiceController.saveClusterState('ADD_SERVICES_INSTALLING_3');
+      wizardStep8Controller.set('servicesInstalled', true);
       router.transitionTo('step6');
     }
   }),
@@ -214,12 +243,13 @@ module.exports = Em.Route.extend({
     retry: function(router,context) {
       var addServiceController = router.get('addServiceController');
       var wizardStep9Controller = router.get('wizardStep9Controller');
-      if (!wizardStep9Controller.get('isSubmitDisabled')) {
-        if (wizardStep9Controller.get('content.cluster.status') !== 'START FAILED') {
-        addServiceController.installServices(true);
-        addServiceController.setInfoForStep9();
-        } else {
-          wizardStep9Controller.set('content.cluster.isCompleted', false);
+      if (wizardStep9Controller.get('showRetry')) {
+        if (wizardStep9Controller.get('content.cluster.status') === 'INSTALL FAILED') {
+          var isRetry = true;
+          addServiceController.installServices(isRetry);
+          addServiceController.setInfoForStep9();
+          // We need to do recovery based on whether we are in Add Host or Installer wizard
+          addServiceController.saveClusterState('ADD_SERVICES_INSTALLING_3');
         }
         wizardStep9Controller.navigateStep();
       }
@@ -231,6 +261,10 @@ module.exports = Em.Route.extend({
       var addServiceController = router.get('addServiceController');
       var wizardStep9Controller = router.get('wizardStep9Controller');
       addServiceController.saveInstalledHosts(wizardStep9Controller);
+
+      // We need to do recovery based on whether we are in Add Host or Installer wizard
+      addServiceController.saveClusterState('ADD_SERVICES_INSTALLED_4');
+
       router.transitionTo('step7');
     }
   }),
@@ -249,8 +283,13 @@ module.exports = Em.Route.extend({
     back: Em.Router.transitionTo('step6'),
     complete: function (router, context) {
       if (true) {   // this function will be moved to installerController where it will validate
-        router.get('addServiceController').finish();
+        var addServiceController = router.get('addServiceController');
+        App.router.get('updateController').updateAll();
+        addServiceController.finish();
         $(context.currentTarget).parents("#modal").find(".close").trigger('click');
+
+        // We need to do recovery based on whether we are in Add Host or Installer wizard
+        addServiceController.saveClusterState('ADD_SERVICES_COMPLETED_5');
       }
     }
   }),

Modified: incubator/ambari/trunk/ambari-web/app/routes/installer.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/installer.js?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/routes/installer.js (original)
+++ incubator/ambari/trunk/ambari-web/app/routes/installer.js Sat Apr  6 01:55:42 2013
@@ -287,12 +287,7 @@ module.exports = Em.Route.extend({
       installerController.installServices();
       installerController.setInfoForStep9();
       // We need to do recovery based on whether we are in Add Host or Installer wizard
-      App.clusterStatus.setClusterStatus({
-        clusterName: this.get('clusterName'),
-        clusterState: 'CLUSTER_INSTALLING_3',
-        wizardControllerName: App.router.get('installerController.name'),
-        localdb: App.db.data
-      });
+      installerController.saveClusterState('CLUSTER_INSTALLING_3');
       wizardStep8Controller.set('servicesInstalled', true);
       router.transitionTo('step9');
     }
@@ -321,12 +316,7 @@ module.exports = Em.Route.extend({
           installerController.setInfoForStep9();
           wizardStep9Controller.resetHostsForRetry();
           // We need to do recovery based on whether we are in Add Host or Installer wizard
-          App.clusterStatus.setClusterStatus({
-            clusterName: this.get('clusterName'),
-            clusterState: 'CLUSTER_INSTALLING_3',
-            wizardControllerName: App.router.get('installerController.name'),
-            localdb: App.db.data
-          });
+          installerController.saveClusterState('CLUSTER_INSTALLING_3');
         }
         wizardStep9Controller.navigateStep();
       }
@@ -339,12 +329,7 @@ module.exports = Em.Route.extend({
       var wizardStep9Controller = router.get('wizardStep9Controller');
       installerController.saveInstalledHosts(wizardStep9Controller);
 
-      App.clusterStatus.setClusterStatus({
-        clusterName: this.get('clusterName'),
-        clusterState: 'CLUSTER_INSTALLED_4',
-        wizardControllerName: App.router.get('installerController.name'),
-        localdb: App.db.data
-      });
+      installerController.saveClusterState('CLUSTER_INSTALLED_4');
       router.transitionTo('step10');
     }
   }),
@@ -368,12 +353,7 @@ module.exports = Em.Route.extend({
         controller.finish();
 
         // We need to do recovery based on whether we are in Add Host or Installer wizard
-        App.clusterStatus.setClusterStatus({
-          clusterName: this.get('clusterName'),
-          clusterState: 'CLUSTER_STARTED_5',
-          wizardControllerName: App.router.get('installerController.name'),
-          localdb: App.db.data
-        });
+        controller.saveClusterState('CLUSTER_STARTED_5');
 
         router.transitionTo('main.index');
       } else {

Modified: incubator/ambari/trunk/ambari-web/app/routes/main.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/main.js?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/routes/main.js (original)
+++ incubator/ambari/trunk/ambari-web/app/routes/main.js Sat Apr  6 01:55:42 2013
@@ -30,7 +30,8 @@ module.exports = Em.Route.extend({
       });
     }
   },
-  /*routePath: function(router,event) {
+  /*
+   routePath: function(router,event) {
    if (router.getAuthenticated()) {
    App.router.get('clusterController').loadClusterName(false);
    router.get('mainController').initialize();
@@ -102,11 +103,311 @@ module.exports = Em.Route.extend({
 
   mirroring: Em.Route.extend({
     route: '/mirroring',
-    connectOutlets: function (router) {
-      router.get('mainController').connectOutlet('mainMirroring');
+    index: Ember.Route.extend({
+      route: '/',
+      enter: function () {
+        this.setupController()
+      },
+      setupController: function () {
+        var controller = App.router.get('mainMirroringController');
+        var datasets = App.Dataset.find();
+        controller.set('datasets', datasets);
+      },
+      connectOutlets: function (router, context) {
+        console.debug('Inside connectOutlets in ' + App.get('router.currentState.path'));
+        router.get('mainController').connectOutlet('mainMirroring');
+      }
+    }),
+
+    addNewDataset: function (router) {
+      router.transitionTo('addNewDatasetRoute');
+    },
+
+    addTargetCluster: function (router, event) {
+      router.transitionTo('addTargetClusterRoute');
+    },
+
+    gotoShowJobs: function (router, event) {
+      router.transitionTo('showDatasetJobs', event.context);
+    },
+
+    showDatasetJobs: Em.Route.extend({
+      route: '/dataset/:dataset_id',
+      connectOutlets: function (router, dataset) {
+        router.get('mainController').connectOutlet('mainJobs', dataset);
+      }
+    }),
+
+    addNewDatasetRoute: Em.Route.extend({
+      route: '/dataset/add',
+
+      setupController: function (controller) {
+        controller.createNewDataSet();
+      },
+      enter: function (router) {
+        var controller = router.get('mainMirroringDataSetController');
+        // if we are coming from closing AddCluster popup
+        if (controller.isReturning) {
+          controller.isReturning = false;
+          return;
+        }
+
+        controller.set('isPopupForEdit', false);
+        this.setupController(controller);
+
+        var self = this;
+        App.ModalPopup.show({
+          classNames: ['sixty-percent-width-modal', 'hideCloseLink'],
+          header: Em.I18n.t('mirroring.dataset.newDataset'),
+          primary: Em.I18n.t('mirroring.dataset.save'),
+          secondary: Em.I18n.t('common.cancel'),
+          onPrimary: function () {
+            newDataSet = controller.getNewDataSet();
+            var schedule = newDataSet.get('schedule');
+            var targetCluster = newDataSet.get('targetCluster');
+            console.debug('Before setting, schedule = ' + schedule + " , targetCluster = " + targetCluster);
+            var scheduleRecord = App.Dataset.Schedule.createRecord(schedule);
+            var dataSetRecord = App.Dataset.createRecord(newDataSet);
+            scheduleRecord.set('dataset', dataSetRecord);
+            dataSetRecord.set('schedule', scheduleRecord);
+
+            console.debug('After setting, schedule = ' + dataSetRecord.get('schedule') + " , targetCluster = " + dataSetRecord.get('targetCluster'));
+            this.hide();
+            router.transitionTo('main.mirroring.index');
+          },
+          onSecondary: function () {
+            this.hide();
+            router.transitionTo('main.mirroring.index');
+          },
+          bodyClass: App.MainMirroringDataSetView.extend({
+            controller: router.get('mainMirroringDataSetController')
+          })
+        });
+      }
+    }),
+
+    editDataset: Em.Route.extend({
+      route: '/dataset/:dataset_id/edit',
+      setupController: function (controller, dataset) {
+        controller.setOriginalDataSetRecord(dataset);
+        controller.setDataSet(dataset);
+      },
+
+
+      connectOutlets: function (router, dataset) {
+        var controller = router.get('mainMirroringDataSetController');
+        // if we are coming from closing AddCluster popup
+        if (controller.isReturning) {
+          controller.isReturning = false;
+          return;
+        }
+        // for showing delete button
+        controller.set('isPopupForEdit', true);
+        this.setupController(controller, dataset);
+
+        var self = this;
+        controller.set('popup', App.ModalPopup.show({
+          classNames: ['sixty-percent-width-modal'],
+          header: Em.I18n.t('mirroring.dataset.editDataset'),
+          primary: Em.I18n.t('mirroring.dataset.save'),
+          secondary: Em.I18n.t('common.cancel'),
+          onPrimary: function () {
+            newDataSet = controller.getNewDataSet();
+
+            var originalRecord = controller.get('model.originalRecord');
+
+            originalRecord.set('name', newDataSet.get('name'));
+            originalRecord.set('sourceDir', newDataSet.get('sourceDir'));
+            originalRecord.set('targetCluster', newDataSet.get('targetCluster'));
+            originalRecord.set('targetDir', newDataSet.get('targetDir'));
+            originalRecord.set('schedule', newDataSet.get('schedule'));
+            this.hide();
+            router.transitionTo('main.mirroring.index');
+          },
+          onSecondary: function () {
+            this.hide();
+            router.transitionTo('main.mirroring.index');
+          },
+          bodyClass: App.MainMirroringDataSetView.extend({
+            controller: router.get('mainMirroringDataSetController')
+          })
+        })
+        );
+      }
+    }),
+
+    gotoEditDataset: function (router, event) {
+      router.transitionTo('editDataset', event.context);
+    },
+
+    addTargetClusterRoute: Ember.Route.extend({
+      route: '/targetCluster/add',
+      initialState: 'testConnectionRoute',
+      testConnectionRoute: Ember.Route.extend({
+        setupController: function (controller) {
+          controller.createTargetCluster();
+          controller.set('model.isPopupForEdit', false);
+
+        },
+
+        enter: function (router, context) {
+
+          console.debug('Inside connectOutlets in ' + App.get('router.currentState.path'));
+          var self = this;
+          var controller = App.router.get('mainMirroringTargetClusterController');
+          this.setupController(controller);
+
+          controller.set('popup', App.ModalPopup.show({
+            classNames: ['sixty-percent-width-modal', 'hideCloseLink'],
+            header: Em.I18n.t('mirroring.targetcluster.addCluster'),
+            primary: Em.I18n.t('mirroring.targetcluster.testConnection'),
+            onPrimary: function () {
+              App.router.transitionTo('testConnectionResultsRoute');
+            },
+            onSecondary: function () {
+              this.hide();
+
+              var dscontroller = App.router.get('mainMirroringDataSetController');
+              var tccontroller = App.router.get('mainMirroringTargetClusterController');
+              var returnRoute = tccontroller.get('returnRoute');
+              // if we have come from addNewDatasetRoute
+              if (returnRoute) {
+                dscontroller.isReturning = true;
+                App.router.transitionTo(returnRoute);
+              }
+              else
+                App.router.transitionTo('main.mirroring.index');
+            },
+            bodyClass: App.MainMirroringAddTargetClusterView.extend({
+              controller: App.router.get('mainMirroringTargetClusterController')
+            })
+          }));
+        },
+
+        connectOutlets: function (router, context) {
+          console.log("entering the connectOutlets method of testConnectionRoute.")
+          var parentController = router.get('mainMirroringTargetClusterController');
+          parentController.connectOutlet('testConnection', parentController.get('model'));
+        },
+
+        exit: function (stateManager) {
+          console.log("exiting the testConnectionRoute state")
+        }
+      }),
+      testConnectionResultsRoute: Ember.Route.extend({
+        enter: function (stateManager) {
+          console.log("entering the testConnectionResultsRoute state.")
+          // lets change the primary button
+          var controller = App.router.get('mainMirroringTargetClusterController');
+          var popup = controller.get('popup');
+          popup.set('primary', Em.I18n.t('common.save'));
+          popup.set('onPrimary',
+            function () {
+              var controller = App.router.get('testConnectionResultsController');
+              controller.saveClusterName();
+            }
+          );
+
+        },
+
+        connectOutlets: function (router, context) {
+          console.log("entering the connectOutlets method of testConnectionResultsRoute.")
+          var parentController = router.get('mainMirroringTargetClusterController');
+          parentController.connectOutlet('testConnectionResults', parentController.get('model'));
+        },
+
+        exit: function (stateManager) {
+          console.log("exiting the connectionSuccessRoute state")
+        }
+
+      })
+    }),
+    editTargetClusterRoute: Em.Route.extend({
+      route: '/targetCluster/:targetCluster_id/edit',
+
+      initialState: 'testConnectionRoute',
+
+      setupController: function (controller, targetCluster) {
+        controller.setOriginalRecord(targetCluster);
+        controller.setTargetCluster(targetCluster);
+      },
+
+      connectOutlets: function (router, targetCluster) {
+        // this connectOutlets is mainly to receive the 'targetCluster' argument
+        var controller = router.get('mainMirroringTargetClusterController');
+        // for showing delete button
+        controller.set('model.isPopupForEdit', true);
+        this.setupController(controller, targetCluster);
+      },
+
+      testConnectionRoute: Em.Route.extend({
+        connectOutlets: function (router, targetCluster) {
+          var controller = router.get('mainMirroringTargetClusterController');
+          controller.set('popup', App.ModalPopup.show({
+            classNames: ['sixty-percent-width-modal'],
+            header: Em.I18n.t('mirroring.dataset.editDataset'),
+            primary: Em.I18n.t('mirroring.targetcluster.testConnection'),
+            onPrimary: function () {
+              App.router.transitionTo('testConnectionResultsRoute');
+            },
+            secondary: Em.I18n.t('common.cancel'),
+            onSecondary: function () {
+              this.hide();
+              router.transitionTo('main.mirroring.index');
+            },
+            bodyClass: App.MainMirroringAddTargetClusterView.extend({
+              controller: App.router.get('mainMirroringTargetClusterController')
+            })
+          }));
+
+          console.log("entering the connectOutlets method of testConnectionRoute.")
+          var parentController = router.get('mainMirroringTargetClusterController');
+          parentController.connectOutlet('testConnection', parentController.get('model'));
+
+        }
+
+      }),
+      testConnection: function () {
+        App.router.transitionTo('testConnectionResultsRoute');
+      },
+      testConnectionResultsRoute: Ember.Route.extend({
+        enter: function (stateManager) {
+          console.log("entering the testConnectionResultsRoute state.")
+          // lets change the primary button
+          var controller = App.router.get('mainMirroringTargetClusterController');
+          var popup = controller.get('popup');
+          popup.set('primary', Em.I18n.t('common.save'));
+          popup.set('onPrimary',
+            function () {
+              var controller = App.router.get('testConnectionResultsController');
+              controller.saveClusterName();
+            }
+          );
+
+        },
+
+        connectOutlets: function (router, context) {
+          console.log("entering the connectOutlets method of testConnectionResultsRoute.");
+          var parentController = router.get('mainMirroringTargetClusterController');
+          parentController.connectOutlet('testConnectionResults', parentController.get('model'));
+        },
+
+        exit: function (stateManager) {
+          console.log("exiting the connectionSuccessRoute state")
+        }
+
+      })
+
+    }),
+
+    editTargetCluster: function (router, event) {
+      router.transitionTo('editTargetClusterRoute', event.context);
     }
+
+
   }),
 
+
   hosts: Em.Route.extend({
     route: '/hosts',
     index: Ember.Route.extend({
@@ -134,6 +435,13 @@ module.exports = Em.Route.extend({
         }
       }),
 
+      configs: Em.Route.extend({
+        route: '/configs',
+        connectOutlets: function (router, context) {
+          router.get('mainHostDetailsController').connectOutlet('mainHostConfigs');
+        }
+      }),
+
       metrics: Em.Route.extend({
         route: '/metrics',
         connectOutlets: function (router, context) {
@@ -354,6 +662,14 @@ module.exports = Em.Route.extend({
       }
     }),
 
+    adminMisc: Em.Route.extend({
+      route: '/misc',
+      connectOutlets: function(router) {
+        router.set('mainAdminController.category', "misc");
+        router.get('mainAdminController').connectOutlet('mainAdminMisc');
+      }
+    }),
+
     adminAudit: Em.Route.extend({
       route: '/audit',
       connectOutlets: function (router) {
@@ -373,7 +689,7 @@ module.exports = Em.Route.extend({
     },
 
     //events
-    goToAdmin: function(router, event) {
+    goToAdmin: function (router, event) {
       router.transitionTo(event.context);
     }
 
@@ -462,8 +778,8 @@ module.exports = Em.Route.extend({
   }),
 
 
-  serviceAdd:require('routes/add_service_routes'),
-  reassignMaster:require('routes/reassign_master_routes'),
+  serviceAdd: require('routes/add_service_routes'),
+  reassignMaster: require('routes/reassign_master_routes'),
 
 
   selectService: Em.Route.transitionTo('services.service'),

Modified: incubator/ambari/trunk/ambari-web/app/routes/reassign_master_routes.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/reassign_master_routes.js?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/routes/reassign_master_routes.js (original)
+++ incubator/ambari/trunk/ambari-web/app/routes/reassign_master_routes.js Sat Apr  6 01:55:42 2013
@@ -48,6 +48,15 @@ module.exports = Em.Route.extend({
             this.fitHeight();
           }
         });
+
+        App.clusterStatus.updateFromServer();
+        var currentClusterStatus = App.clusterStatus.get('value');
+        if (currentClusterStatus && currentClusterStatus.clusterState == 'REASSIGN_MASTER_INSTALLING') {
+          reassignMasterController.setCurrentStep('5');
+          App.db.data = currentClusterStatus.localdb;
+        } else {
+          reassignMasterController.setCurrentStep('1');
+        }
         router.transitionTo('step' + reassignMasterController.get('currentStep'));
       });
   },
@@ -95,12 +104,16 @@ module.exports = Em.Route.extend({
     connectOutlets: function (router) {
       console.log('in reassignMaster.step3:connectOutlets');
       var controller = router.get('reassignMasterController');
-      controller.setCurrentStep('3');
-      controller.dataLoading().done(function () {
-        controller.loadAllPriorSteps();
-        controller.set('content.serviceName', controller.get('content.reassign.service_id'));
-        controller.connectOutlet('wizardStep12', controller.get('content'));
-      })
+      if (controller.get('skipStep3')) {
+        router.transitionTo('step4');
+      } else {
+        controller.setCurrentStep('3');
+        controller.dataLoading().done(function () {
+          controller.loadAllPriorSteps();
+          controller.set('content.serviceName', controller.get('content.reassign.service_id'));
+          controller.connectOutlet('wizardStep12', controller.get('content'));
+        })
+      }
     },
     back: Em.Router.transitionTo('step2'),
     next: function (router) {
@@ -125,6 +138,13 @@ module.exports = Em.Route.extend({
     },
     back: Em.Router.transitionTo('step3'),
     next: function (router) {
+      App.db.setReassignTasksStatuses(['INITIALIZE', 'INITIALIZE', 'INITIALIZE', 'INITIALIZE', 'INITIALIZE', 'INITIALIZE', 'INITIALIZE', 'INITIALIZE']);
+      App.clusterStatus.setClusterStatus({
+        clusterName: router.get('reassignMasterController.content.cluster.name'),
+        clusterState: 'REASSIGN_MASTER_INSTALLING',
+        wizardControllerName: 'reassignMasterController',
+        localdb: App.db.data
+      });
       router.transitionTo('step5');
     }
   }),
@@ -141,8 +161,20 @@ module.exports = Em.Route.extend({
       })
     },
     back: Em.Router.transitionTo('step3'),
-    next: function (router) {
-      //router.transitionTo('step6');
+    complete: function (router, context) {
+      var controller = router.get('reassignMasterController');
+      var wizardStep14Controller = router.get('wizardStep14Controller');
+      if (!wizardStep14Controller.get('isSubmitDisabled')) {
+        controller.finish();
+        $(context.currentTarget).parents("#modal").find(".close").trigger('click');
+        App.clusterStatus.setClusterStatus({
+          clusterName: router.get('reassignMasterController.content.cluster.name'),
+          clusterState: 'REASSIGN_MASTER_COMPLETED',
+          wizardControllerName: 'reassignMasterController',
+          localdb: App.db.data
+        });
+        router.transitionTo('main.index');
+      }
     }
   }),
 

Modified: incubator/ambari/trunk/ambari-web/app/routes/stack_upgrade.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/routes/stack_upgrade.js?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/routes/stack_upgrade.js (original)
+++ incubator/ambari/trunk/ambari-web/app/routes/stack_upgrade.js Sat Apr  6 01:55:42 2013
@@ -21,7 +21,6 @@ module.exports = Em.Route.extend({
 
   enter: function (router) {
     console.log('in /admin/cluster/upgrade:enter');
-    var self = this;
     Ember.run.next(function () {
       var stackUpgradeController = router.get('stackUpgradeController');
       App.router.get('updateController').set('isWorking', false);
@@ -41,7 +40,12 @@ module.exports = Em.Route.extend({
           this.fitHeight();
         }
       });
-
+      var statuses = ['STOPPING_SERVICES', 'STACK_UPGRADING', 'STACK_UPGRADE_FAILED', 'STACK_UPGRADED'];
+      var currentClusterStatus = App.clusterStatus.get('value');
+      App.db.data = currentClusterStatus.localdb;
+      if (statuses.contains(currentClusterStatus.clusterState)) {
+        stackUpgradeController.setCurrentStep(3);
+      }
       router.transitionTo('step' + stackUpgradeController.get('currentStep'));
     });
   },
@@ -73,17 +77,13 @@ module.exports = Em.Route.extend({
       var stepController = router.get('stackUpgradeStep3Controller');
       controller.save('upgradeOptions');
       router.transitionTo('step3');
-      if(App.testMode){
-        stepController.simulateStopService();
-      } else {
-        controller.stopServices();
-      }
       App.clusterStatus.setClusterStatus({
         clusterName: controller.get('content.cluster.name'),
         clusterState: 'PENDING',
         wizardControllerName: 'stackUpgradeController',
         localdb: App.db.data
       });
+      stepController.stopServices();
     }
   }),
 
@@ -100,7 +100,6 @@ module.exports = Em.Route.extend({
     finish: function (router, context) {
       var controller = router.get('stackUpgradeController');
       var stepController = router.get('stackUpgradeStep3Controller');
-      stepController.clearStep();
       controller.finish();
       $(context.currentTarget).parents("#modal").find(".close").trigger('click');
       App.clusterStatus.setClusterStatus({
@@ -110,7 +109,7 @@ module.exports = Em.Route.extend({
         localdb: App.db.data
       });
       App.router.get('updateController').updateAll();
-      //App.set('currentStackVersion', controller.get('content.upgradeVersion'));
+      App.set('currentStackVersion', controller.get('content.upgradeVersion'));
     }
   }),
   backToCluster: function(router, context){

Modified: incubator/ambari/trunk/ambari-web/app/styles/application.less
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/styles/application.less?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/styles/application.less (original)
+++ incubator/ambari/trunk/ambari-web/app/styles/application.less Sat Apr  6 01:55:42 2013
@@ -377,6 +377,29 @@ h1 {
   #deploy {
     #overallProgress {
     }
+    #host-filter {
+      margin-top: 3px;
+      ul {
+        margin: 3px;
+        font-size: 12px;
+        li {
+          list-style: none;
+          display: block;
+          float: left;
+          padding: 0 2px;
+          a {
+            text-decoration: underline;
+          }
+        }
+        li.first {
+          font-weight: bold;
+        }
+        li.active a {
+          text-decoration: none;
+          color: #000000;
+        }
+      }
+    }
     #deploy-status-by-host {
       th.host {
         width: 30%;
@@ -446,13 +469,22 @@ h1 {
   }
 }
 
+.spinner {
+  width: 36px;
+  height: 36px;
+  background: url("/img/spinner.gif");
+  margin: 0 auto;
+}
+
 #serviceConfig {
   margin-top: 20px;
-  .spinner {
-    width: 36px;
-    height: 36px;
-    background: url("/img/spinner.gif");
-    margin: 0 auto;
+  .alert{
+    .icon-refresh{
+      margin-left:10px;
+    }
+  }
+  .icon-refresh {
+    color: #FDB82F;
   }
   .directories {
     min-width: 280px;
@@ -466,6 +498,11 @@ h1 {
       text-align: left;
       word-wrap: break-word;
     }
+    .service-config-section{
+      .overridden-property{
+        background-color: rgba(211, 237, 247, 0.39);
+      }
+    }
     .entry-row {
       margin: 10px 0;
       .control-label-span{
@@ -482,6 +519,9 @@ h1 {
           margin-top: 5px;
           margin-bottom: 5px;
         }
+        .overridden-hosts-view {
+          display: inline-block;
+        }
         .error {
         }
       }
@@ -555,6 +595,43 @@ h1 {
       }
     }
   }
+  .capacity-scheduler {
+    .header {
+      margin-bottom: 10px;
+      .span1 {
+        padding-top: 10px;
+        font-weight: bold;
+      }
+    }
+    form.form-horizontal {
+      margin-left: 20px;
+      .control-label {
+        text-align: left;
+      }
+    }
+    table tr, svg {
+      cursor: pointer;
+    }
+    .marker {
+      margin: 0 5px;
+      display: inline-block;
+      width: 12px;
+      height: 12px;
+    }
+    #section_label{
+      display: none;
+      border: 1px solid black;
+      padding: 2px 5px;
+      position: absolute;
+      border-radius: 3px;
+      background-color: #f9f9f9;
+    }
+    .frame{
+      position:relative;
+      width: 200px;
+      height: 200px;
+    }
+  }
 }
 
 a:focus {
@@ -622,7 +699,62 @@ a:focus {
 /*90% width modal window start*/
 .full-width-modal {
   .modal {
+    .modal-body {
+
+      .add-cluster-1{
+        width: 100%;
+        height : 500px;
+        margin: 0 auto;
+
+        .each-row{
+          margin-top: 10px;
+        }
+
+        .add-cluster-1-1{
+          width: 45%;
+          height : 100%;
+          float: left;
+        }
+        .add-cluster-1-3{
+          width: 45%;
+          height : 100%;
+          float: left;
+        }
+        .add-cluster-1-2{
+          width: 10%;
+          height : 100%;
+          float: left;
+
+          .add-cluster-1-2-1{
+            width: 100%;
+            height : 40%;
+          }
+          .add-cluster-1-2-2{
+            width: 100%;
+            height : 10%;
+          }
+          .add-cluster-1-2-3{
+            width: 100%;
+            height : 50%;
+          }
+          .middle-line{
+            width : 2%;
+            margin : 0 auto;
+            height : 100%;
+            background-color: #000000;
+          }
+          .add-cluster-center-most-div{
+            height : 30%;
+            text-align: center;
+            position: relative;
+            top: 30%;
+          }
+        }
+      }
+
 
+
+    }
   }
 
   .clear {
@@ -651,6 +783,13 @@ a:focus {
 /*90% width modal window end*/
 
 /*60% width modal window start*/
+.sixty-percent-width-modal.hideCloseLink{
+  .modal-header{
+    .close{
+      display:none
+    }
+  }
+}
 .sixty-percent-width-modal {
 
   .modal {
@@ -661,8 +800,107 @@ a:focus {
   }
 
   .modal-body {
+
     max-height: 403px;
+
     .form-horizontal{
+
+      .add-cluster-1{
+          width: 100%;
+          height : auto;
+          min-height : 350px;
+          margin: 0 auto;
+
+        .each-row{
+          margin-top: 10px;
+        }
+
+          .add-cluster-1-1{
+            width: 50%;
+            height : 100%;
+            float: left;
+          }
+          .add-cluster-1-3{
+            width: 45%;
+            height : 100%;
+            float: right;
+          }
+          .add-cluster-1-2{
+            width: 10%;
+            height : 100%;
+            float: left;
+
+            .add-cluster-1-2-1{
+              width: 100%;
+              height : 40%;
+            }
+            .add-cluster-1-2-2{
+              width: 100%;
+              height : 10%;
+            }
+            .add-cluster-1-2-3{
+              width: 100%;
+              height : 50%;
+            }
+            .middle-line{
+              width : 2%;
+              margin : 0 auto;
+              height : 100%;
+              background-color: #000000;
+            }
+            .add-cluster-center-most-div{
+              height : 30%;
+              text-align: center;
+              position: relative;
+              top: 30%;
+            }
+          }
+        }
+
+      .add-cluster-2{
+        margin : 0 auto;
+        height : 500px;
+        table{
+          width : 60%;
+          margin : 0 20%;
+
+          .spacer{
+            height: 20px;
+          }
+          td {
+            width : 50%;
+            a.btn-success{
+              margin-left: 30%;
+            }
+          }
+
+        }
+
+      }
+
+
+      .add-data-set{
+        width: 80%;
+        margin: 0 auto;
+        table{
+          width: 100%;
+        }
+        td.percent25 {
+          width: 25%;
+        }
+        td.spacer{
+          height: 10px;
+        }
+
+        input.hyper-mini{
+          width: 20px;
+        }
+
+        .targetClusterDD{
+          min-width : 170px;
+        }
+
+      }
       .each-row{
         margin-top: 10px;
       }
@@ -1346,9 +1584,18 @@ a:focus {
       }
     }
   }
+  
+  .icon-refresh {
+    color: #FDB82F;
+  }
+  
   .add-service-button {
     margin: 20px 20px 10px;
   }
+
+  .start-stop-all-service-button {
+    margin: 5px 5px 10px 10px;
+  }
   .operations-count {
     background: #953B39;
   }
@@ -1775,6 +2022,10 @@ url-prefix
   width: 13px;
 }
 
+.components-health.icon-arrow-up{
+  color:red;
+}
+
 .health-status-started, .health-status-starting {
   background-image: @status-live-marker;
   .marker;
@@ -1901,10 +2152,10 @@ hr {
 /*End Hosts*/
 
 /*Start Admin*/
+.header {
+  margin-bottom: 20px;
+}
 .admin-cluster {
-  .header {
-    margin-bottom: 20px;
-  }
   a.inactive {
     cursor: default;
     color: #333333;
@@ -1916,6 +2167,12 @@ hr {
    margin-left: 20px
  }
 
+.admin-misc {
+  .span6 {
+    margin-left: 0 !important;
+  }
+}
+
 /*End Admin*/
 
 /*assign masters*/
@@ -1976,6 +2233,7 @@ hr {
   }
 
   .form-horizontal .control-label {
+    white-space: normal;
     width: 120px;
     padding-right: 10px;
   }
@@ -2288,6 +2546,14 @@ ul.filter {
 
 /*Start Mirroring*/
 
+.mirroring-top-nav {
+  margin-bottom: 20px;
+}
+
+.schedule-toggle {
+  min-width: 190px;
+}
+
 #mirroring {
 
   .page-bar {
@@ -2455,6 +2721,29 @@ ul.filter {
   }
 }
 
+.dataset-delete {
+  width: 15%;
+}
+.dataset-form {
+  width: 85%;
+}
+
+.mirroring-sidebar {
+  hr {
+    margin: 0;
+  }
+  ul {
+    margin: 0 0 20px 0;
+    li {
+      list-style: none;
+      margin: 8px 0;
+      a {
+        cursor: pointer;
+      }
+    }
+  }
+}
+
 /*End Mirroring*/
 
 .noDisplay {

Modified: incubator/ambari/trunk/ambari-web/app/templates.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates.js?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates.js (original)
+++ incubator/ambari/trunk/ambari-web/app/templates.js Sat Apr  6 01:55:42 2013
@@ -24,3 +24,4 @@ require('templates/main/service/info/sum
 require('templates/main/service/info/summary/oozie');
 require('templates/main/service/info/summary/zookeeper');
 require('templates/main/service/info/summary/hive');
+require('templates/main/service/info/summary/hue');

Modified: incubator/ambari/trunk/ambari-web/app/templates/application.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/application.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/application.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/application.hbs Sat Apr  6 01:55:42 2013
@@ -26,7 +26,7 @@
 
           {{#if isClusterDataLoaded}}
               <a class="brand cluster-name" href="javascript:void(null);" {{bindAttr title="clusterName"}}>
-                {{clusterDisplayName}}
+                <span {{action "showPopup" target="App.router.backgroundOperationsController"}} >{{clusterDisplayName}} </span>
 
                 {{#with App.router.backgroundOperationsController}}
                   {{#if allOperationsCount}}

Modified: incubator/ambari/trunk/ambari-web/app/templates/common/configs/addPropertyWindow.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/configs/addPropertyWindow.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/configs/addPropertyWindow.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/configs/addPropertyWindow.hbs Sat Apr  6 01:55:42 2013
@@ -22,7 +22,7 @@
         {{view.serviceConfigProperty.filename}}
       </div>
     </div>
-    <div {{bindAttr class="view.serviceConfigProperty.isKeyEmpty:error :each-row :control-group"}}>
+    <div {{bindAttr class="view.serviceConfigProperty.isKeyError:error :each-row :control-group"}}>
       <label class="control-label">Key</label>
       <div class="controls">
         {{view Ember.TextField valueBinding="view.serviceConfigProperty.name" class="span4"}}

Added: incubator/ambari/trunk/ambari-web/app/templates/common/configs/capacity_scheduler.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/configs/capacity_scheduler.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/configs/capacity_scheduler.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/configs/capacity_scheduler.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,101 @@
+{{!
+* 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="accordion-heading" {{action "onToggleBlock" view.category target="view"}}>
+    <i class="pull-left accordion-toggle" {{bindAttr class="view.category.isCollapsed:icon-caret-right:icon-caret-down "}}></i>
+    <a class="accordion-toggle">{{view.category.displayName}}</a>
+</div>
+
+<div {{bindAttr id="view.category.name"}} class="accordion-body collapse in">
+    <div class="accordion-inner capacity-scheduler">
+        <div class="row-fluid header">
+            <div class="span1">{{t services.mapReduce.config.queue.header}}</div>
+            <div class="offset9 span2">
+                <div class="btn pull-right" {{action queuePopup target="view"}}>{{t services.mapReduce.config.addQueue}}</div>
+            </div>
+        </div>
+        <div>
+            <table class="table table-bordered table-striped">
+                <thead>
+                <tr>
+                    <th>{{t services.mapReduce.config.queue.name}}</th>
+                    <th>{{t common.users}}</th>
+                    <th>{{t services.mapReduce.config.queue.groups}}</th>
+                    <th>{{t services.mapReduce.config.queue.capacity}}</th>
+                    <th>{{t services.mapReduce.config.queue.maxCapacity}}</th>
+                    <th>{{t services.mapReduce.config.queue.minUserLimit}}</th>
+                    <th>{{t services.mapReduce.config.queue.userLimitFactor}}</th>
+                    <th>{{t services.mapReduce.config.queue.supportsPriority}}</th>
+                </tr>
+                </thead>
+                <tbody>
+                  {{#each queue in view.tableContent}}
+                  <tr {{action queuePopup queue.name target="view"}}>
+                      <td><a href="javascript:void(0)">
+                          <i {{bindAttr style="queue.color"}} class="marker"></i>{{queue.name}}</a>
+                      </td>
+                      <td>{{queue.users}}</td>
+                      <td>{{queue.groups}}</td>
+                      <td>{{queue.capacity}}&#37;</td>
+                      <td>{{queue.maxCapacity}}&#37;</td>
+                      <td>{{queue.minUserLimit}}&#37;</td>
+                      <td>{{queue.userLimitFactor}}</td>
+                      <td>{{queue.supportsPriority}}</td>
+                  </tr>
+                  {{/each}}
+                </tbody>
+            </table>
+        </div>
+        <div class="row-fluid">
+            <div class="span8">
+                <div><strong>{{t admin.advanced.title}}</strong></div>
+                <form class="form-horizontal">
+                  {{#each view.advancedConfigs}}
+                    {{#if isVisible}}
+                        <div class="row-fluid">
+                            <div {{bindAttr class="errorMessage:error :control-label-span :span4"}}>
+                                <label class="control-label">{{displayName}}</label>
+                            </div>
+                            <div class="span8">
+                                <div {{bindAttr class="errorMessage:error: :control-group"}}>
+                                  {{view viewClass serviceConfigBinding="this" categoryConfigsBinding="view.categoryConfigs" }}
+                                    <span class="help-inline">{{errorMessage}}</span>
+                                </div>
+                            </div>
+                        </div>
+                    {{/if}}
+                  {{/each}}
+                </form>
+            </div>
+            <div class="span4">
+                <div class="frame">
+                  <div id="section_label"></div>
+                  {{view view.pieChart queuesBinding="view.queues"}}
+                </div>
+            </div>
+        </div>
+      {{! For Advanced, Advanced Core Site, Advanced HDFS Site sections, show the 'Add Property' link.}}
+      {{#if view.canEdit}}
+          {{#if view.category.canAddProperty }}
+              <div>
+                  <a href="#" {{action "showAddPropertyWindow" this target="view" }} >{{t installer.step7.config.addProperty}}...</a>
+              </div>
+          {{/if}}
+      {{/if}}
+    </div>
+</div>

Modified: incubator/ambari/trunk/ambari-web/app/templates/common/configs/overriddenProperty.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/configs/overriddenProperty.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/configs/overriddenProperty.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/configs/overriddenProperty.hbs Sat Apr  6 01:55:42 2013
@@ -20,7 +20,7 @@
     {{! Here serviceConfigBinding should ideally be serviceConfigPropertyBinding }}
     <div {{bindAttr class="overriddenSCP.errorMessage:error: :control-group :overrideField"}}>
       {{view overriddenSCP.viewClass serviceConfigBinding="overriddenSCP" categoryConfigsBinding="view.categoryConfigs"}}
-      <a class="action" href="#" {{action showOverrideWindow overriddenSCP controller target="view" }} >{{overriddenSCP.selectedHostOptions.length}} hosts </a>
+      {{view view.hostsCountView overriddenSCPBinding="overriddenSCP"}}
       {{#if isNotDefaultValue}}
         <a class="action" {{action "doRestoreDefaultValue" this target="view" }} ><i class="icon-undo"></i>Undo</a>
       {{/if}}

Modified: incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs Sat Apr  6 01:55:42 2013
@@ -19,8 +19,12 @@
 {{! #with view.categoryConfigProperty}}
   <form class="form-horizontal">
       <div class="override-controls">
-        <h4 class="message">Select hosts from the list of available hosts</h4>
-        
+        <h4 class="message">{{t hosts.selectHostsDialog.message}}</h4>
+        {{#if view.parentView.warningMessage}}
+	        <div class="text-warning">
+	          {{view.parentView.warningMessage}}
+	        </div>
+        {{/if}}
         <table style="width: 100%;">
           <tr>
             <td>
@@ -31,7 +35,7 @@
                 <div class="span2">
                   <!-- Filter text box with drop-down -->
 		              <div class="input-append">
-		                {{view Ember.TextField valueBinding="view.filterText" id="appendedDropdownButton" placeholder="Filter..." class="span2"}}
+		                {{view Ember.TextField valueBinding="view.filterText" id="appendedDropdownButton" placeholderBinding="view.filterTextPlaceholder" class="span2"}}
 		                <div class="btn-group">
 		                  <button class="btn dropdown-toggle" data-toggle="dropdown">
 		                    <span class="caret"></span>

Modified: incubator/ambari/trunk/ambari-web/app/templates/common/configs/service_config.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/configs/service_config.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/configs/service_config.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/configs/service_config.hbs Sat Apr  6 01:55:42 2013
@@ -16,9 +16,40 @@
 * limitations under the License.
 }}
 
+{{#if selectedService.restartRequired}}
+<div class="alert">
+  <div class="clearfix like_pointer" {{action toggleRestartMessageView target="view"}}>
+      {{#if view.isRestartMessageCollapsed}}
+        <i class="icon-caret-down pull-left"></i>
+      {{else}}
+        <i class="icon-caret-right pull-left"></i>
+      {{/if}}
+      <i class="icon-refresh"></i>
+      <strong>Restart Service</strong> {{selectedService.restartRequiredMessage}}
+  </div>
+  <div class="service-body">
+    <ul>
+    {{#each host in selectedService.restartRequiredHostsAndComponents}}
+      <li>
+        <a href="#" {{action showDetails host.hostData}}>{{host.hostData.publicHostName}}</a>
+        <ul>
+          {{#each component in host.components}}
+            <li>{{component.name}}</li>
+          {{/each}}
+        </ul>
+      </li>
+    {{/each}}
+    </ul>
+  </div>
+</div>
+{{/if}}
+          
 <div class="accordion">
   {{#each category in selectedService.configCategories}}
-    {{#view App.ServiceConfigsByCategoryView categoryBinding="category" serviceBinding="selectedService" serviceConfigsBinding="selectedService.configs"}}
+    {{#if category.isCustomView}}
+      {{view category.customView categoryBinding="category" serviceBinding="selectedService" serviceConfigsBinding="selectedService.configs"}}
+    {{else}}
+    {{#view App.ServiceConfigsByCategoryView categoryBinding="category" canEditBinding="view.canEdit" serviceBinding="selectedService" serviceConfigsBinding="selectedService.configs"}}
 
             <div class="accordion-heading" {{action "onToggleBlock" category target="view"}}>
                 <i {{bindAttr class=":pull-left :accordion-toggle category.isCollapsed:icon-caret-right:icon-caret-down"}}></i>
@@ -26,29 +57,36 @@
             </div>
 
             <div class="accordion-body collapse in">
-              <div class="accordion-inner">
+              <div class="accordion-inner service-config-section">
                 <form class="form-horizontal">
 
                   {{#each view.filteredCategoryConfigs}}
-                      <div class="entry-row">
+                      <div {{bindAttr class=":entry-row isOverridden:overridden-property"}}>
                           <span {{bindAttr class="errorMessage:error: :control-group :control-label-span"}}>
-                            <label class="control-label">{{displayName}}</label>
+                            <label class="control-label">
+	                            {{#if isRestartRequired}}
+	                              <i class="icon-refresh restart-required-property" rel="tooltip" {{bindAttr title="restartRequiredMessage"}}></i>
+	                            {{/if}}
+                              {{displayName}}
+                            </label>
                           </span>
                           <div class="controls">
                             {{! Here serviceConfigBinding should ideally be serviceConfigPropertyBinding }}
                               <div {{bindAttr class="errorMessage:error: :control-group"}}>
-                                {{view viewClass serviceConfigBinding="this" categoryConfigsBinding="view.categoryConfigs" }}
-                                {{#if isOverridable}}
-                                  <a class="action" {{action "createOverrideProperty" this target="view" }} ><i class="icon-plus-sign"></i>{{t common.exception}}</a>
-                                {{/if}}
-                                {{#if cantBeUndone}}
-                                {{else}}
-                                  {{#if isNotDefaultValue}}
-                                    <a class="action" {{action "doRestoreDefaultValue" this target="view" }} ><i class="icon-undo"></i>{{t common.undo}}</a>
-                                  {{/if}}
-                                {{/if}}
-                                {{#if isRemovable}}
-                                  <a class="action" {{action "removeProperty" this target="view" }} ><i class="icon-minus-sign"></i>{{t common.remove}}</a>
+                                {{view viewClass serviceConfigBinding="this" categoryConfigsAllBinding="view.categoryConfigsAll" }}
+                                {{#if view.canEdit}}
+	                                {{#if isPropertyOverridable}}
+	                                    <a class="action" {{action "createOverrideProperty" this target="view" }} ><i class="icon-plus-sign"></i>{{t common.exception}}</a>
+	                                {{/if}}
+	                                {{#if cantBeUndone}}
+	                                {{else}}
+	                                  {{#if isNotDefaultValue}}
+	                                      <a class="action" {{action "doRestoreDefaultValue" this target="view" }} ><i class="icon-undo"></i>{{t common.undo}}</a>
+	                                  {{/if}}
+	                                {{/if}}
+	                                {{#if isRemovable}}
+	                                    <a class="action" {{action "removeProperty" this target="view" }} ><i class="icon-minus-sign"></i>{{t common.remove}}</a>
+	                                {{/if}}
                                 {{/if}}
                                   <span class="help-inline">{{errorMessage}}</span>
                               </div>
@@ -60,16 +98,19 @@
                   {{/each}}
 
                   {{! For Advanced, Advanced Core Site, Advanced HDFS Site sections, show the 'Add Property' link.}}
-                  {{#if category.canAddProperty }}
-                      <div>
-                          <a href="#" {{action "showAddPropertyWindow" this target="view" }} >{{t installer.step7.config.addProperty}}...</a>
-                      </div>
-                  {{/if}}
+                  {{#if view.canEdit}}
+	                  {{#if category.canAddProperty }}
+	                      <div>
+	                          <a href="#" {{action "showAddPropertyWindow" this target="view" }} >{{t installer.step7.config.addProperty}}...</a>
+	                      </div>
+	                  {{/if}}
+	                {{/if}}
                 </form>
               </div>
             </div>
 
 
     {{/view}}
+    {{/if}}
   {{/each}}
 </div>
\ No newline at end of file

Modified: incubator/ambari/trunk/ambari-web/app/templates/common/host_progress_popup.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/host_progress_popup.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/host_progress_popup.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/host_progress_popup.hbs Sat Apr  6 01:55:42 2013
@@ -44,7 +44,7 @@
               </a>
             </div>
             <div class="progress-bar span2">
-                <div {{bindAttr class="progress-striped active servicesInfo.barColor :progress"}}>
+                <div {{bindAttr class="servicesInfo.isInProgress:progress-striped :active servicesInfo.barColor :progress"}}>
                     <div class="bar" {{bindAttr style="servicesInfo.barWidth"}}></div>
                 </div>
             </div>
@@ -93,7 +93,7 @@
             </a>
           </div>
           <div class="progress-bar span2">
-              <div {{bindAttr class="progress-striped active hostInfo.barColor :progress"}}>
+              <div {{bindAttr class="hostInfo.isInProgress:progress-striped :active hostInfo.barColor :progress"}}>
                   <div class="bar" {{bindAttr style="hostInfo.barWidth"}}></div>
               </div>
           </div>

Added: incubator/ambari/trunk/ambari-web/app/templates/main/admin/misc.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/admin/misc.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/admin/misc.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/admin/misc.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,48 @@
+{{!
+* Licensed to the Apache Software Foundation (ASF) under one
+* or more contributor license agreements.  See the NOTICE file
+* distributed with this work for additional information
+* regarding copyright ownership.  The ASF licenses this file
+* to you under the Apache License, Version 2.0 (the
+* "License"); you may not use this file except in compliance
+* with the License.  You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+}}
+<div class="admin-misc">
+  <div class="header">
+    <strong>{{t admin.misc.header}}</strong>
+  </div>
+  {{#if controller.dataIsLoaded}}
+    {{#if controller.users}}
+      <div class="span6">
+        <table class="table table-bordered table-striped">
+          <thead>
+            <tr>
+              <th>{{t common.name}}</th>
+              <th>{{t common.value}}</th>
+            </tr>
+          </thead>
+          <tbody>
+            {{#each user in controller.users}}
+              <tr>
+                <td>{{user.displayName}}</td>
+                <td>{{user.value}}</td>
+              </tr>
+            {{/each}}
+          </tbody>
+        </table>
+      </div>
+    {{else}}
+      <p>{{t admin.misc.nothingToShow}}</p>
+    {{/if}}
+  {{else}}
+    <div class="spinner"></div>
+  {{/if}}
+</div>

Modified: incubator/ambari/trunk/ambari-web/app/templates/main/admin/security/add/step2.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/admin/security/add/step2.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/admin/security/add/step2.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/admin/security/add/step2.hbs Sat Apr  6 01:55:42 2013
@@ -1,3 +1,21 @@
+{{!
+* 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 id="serviceConfig">
   <h2>{{t admin.security.step2.header}}</h2>
 

Modified: incubator/ambari/trunk/ambari-web/app/templates/main/dashboard/service/hbase.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/dashboard/service/hbase.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/dashboard/service/hbase.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/dashboard/service/hbase.hbs Sat Apr  6 01:55:42 2013
@@ -44,7 +44,12 @@
       <!-- HBase Master Server -->
       <tr>
         <td>{{t dashboard.services.hbase.masterServer}}</td>
-        <td><a href="#" {{action showDetails view.service.master}}>{{view.service.master.publicHostName}}</a></td>
+        <td>
+            <a href="#" {{action showDetails view.activeMaster.host}}>{{t service.hbase.activeMaster}}</a>
+            {{#if view.passiveMasters.length}}
+                {{view.passiveMasterOutput}}
+            {{/if}}
+        </td>
       </tr>
       <!-- RegionServers -->
       <tr>
@@ -59,7 +64,7 @@
       <!-- HBaseMaster Web UI -->
       <tr>
         <td>{{t dashboard.services.hbase.masterWebUI}}</td>
-        <td><a {{bindAttr href="view.hbaseMasterWebUrl"}} target="_blank">{{view.service.master.publicHostName}}:60010</a>
+        <td><a {{bindAttr href="view.hbaseMasterWebUrl"}} target="_blank">{{view.activeMaster.host.publicHostName}}:60010</a>
         </td>
       </tr>
       <!-- Regions in Transition -->

Modified: incubator/ambari/trunk/ambari-web/app/templates/main/host.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/host.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/host.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/host.hbs Sat Apr  6 01:55:42 2013
@@ -74,11 +74,6 @@
     {{#view view.HostView contentBinding="host"}}
 
       <td class="first">
-        <script type="text/javascript">
-          $(function () {
-            $("[rel='HealthTooltip']").tooltip();
-          });
-        </script>
         <span rel="HealthTooltip" {{bindAttr class="host.healthClass"}} {{bindAttr title="host.healthToolTip" }}></span>
       </td>
 
@@ -93,11 +88,6 @@
       <td>{{host.memoryFormatted}}</td>
 
       <td>
-        <script type="text/javascript">
-          $(function () {
-            $("[rel='UsageTooltip']").tooltip();
-          });
-        </script>
         <div class="progress progress-info" title="{{unbound host.diskInfoBar}}" rel="UsageTooltip">
           <div class="bar" {{bindAttr style="view.usageStyle"}}></div>
         </div>
@@ -122,7 +112,7 @@
 
   <div class="page-bar">
     <div class="items-on-page">
-      <label>{{t common.show}}: {{view view.hostPerPageSelectView selectionBinding="view.displayLength"}}</label>
+      <label>{{t common.show}}: {{view view.rowsPerPageSelectView selectionBinding="view.displayLength"}}</label>
     </div>
     <div class="info">{{view.paginationInfo}}</div>
     <div class="paging_two_button">

Added: incubator/ambari/trunk/ambari-web/app/templates/main/host/configs.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/host/configs.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/host/configs.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/host/configs.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,26 @@
+{{!
+* 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="row-fluid">
+  <div id="services-menu" class="well span2" style="padding: 8px 0">
+    {{view App.MainHostServiceMenuView}}
+  </div>
+  <div class="span10">
+    {{outlet service_config_outlet}}
+  </div>
+</div>

Added: incubator/ambari/trunk/ambari-web/app/templates/main/host/configs_service.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/host/configs_service.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/host/configs_service.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/host/configs_service.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,29 @@
+{{!
+* 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 id="serviceConfig">
+  {{#if dataIsLoaded}}
+    <div class="pull-right">
+      {{view App.FilterComboboxView filterBinding="controller.filter" columnsBinding="controller.filterColumns" }}
+    </div>
+    <div class="clearfix"></div>
+    {{view App.ServiceConfigView canEditBinding="false" filterBinding="controller.filter" columnsBinding="controller.filterColumns"}}
+  {{else}}
+    <div class="spinner"></div>
+  {{/if}}
+</div>
\ No newline at end of file

Modified: incubator/ambari/trunk/ambari-web/app/templates/main/host/details.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/host/details.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/host/details.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/host/details.hbs Sat Apr  6 01:55:42 2013
@@ -17,7 +17,7 @@
 }}
 
 <div id="host-details">
-  <span {{bindAttr class="view.content.healthClass"}} {{bindAttr title="view.content.healthToolTip" }}></span><span class='host-title'>{{unbound view.content.publicHostName}}</span>
+  <span rel="HealthTooltip" {{bindAttr class="view.content.healthClass"}} {{bindAttr title="view.content.healthToolTip" }}></span><span class='host-title'>{{unbound view.content.publicHostName}}</span>
   {{#if view.content.criticalAlertsCount}}
     <span class="label label-important alerts-count" {{action "showAlertsPopup" content target="App.router.mainHostController"}}>{{view.content.criticalAlertsCount}}</span>
   {{else}}

Modified: incubator/ambari/trunk/ambari-web/app/templates/main/host/summary.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/host/summary.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/host/summary.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/host/summary.hbs Sat Apr  6 01:55:42 2013
@@ -49,7 +49,15 @@
           <div class="row-fluid">
           {{#view view.ComponentView contentBinding="component" decommissionDataNodeHostNamesBinding="view.decommissionDataNodeHostNames"}}
             <div class="span7">
-              <span {{bindAttr class="view.statusClass :components-health"}}></span>&nbsp;
+              {{#if view.isUpgradeFailed}}
+                {{#if App.isAdmin}}
+                  <a href="#" {{action "upgradeComponent" view.content target="controller"}} >
+                    <i title="Component upgrade failed" class="components-health icon-arrow-up"></i>
+                  </a>
+                {{/if}}
+              {{else}}
+                <span {{bindAttr class="view.statusClass :components-health"}}></span>&nbsp;
+              {{/if}}
               {{component.displayName}}&nbsp;/&nbsp;
               <a href="#" {{action routeToService component.service target="controller"  }}>{{component.service.displayName}}</a>
             </div>
@@ -83,6 +91,11 @@
                       {{t common.start}}
                     </a>
                   </li>
+                  <li {{bindAttr class="view.isUpgradeFailed::hidden"}}>
+                    <a href="javascript:void(null)" data-toggle="modal" {{action "upgradeComponent" view.content target="controller"}}>
+                      {{t common.upgrade}}
+                    </a>
+                  </li>
                 </ul>
               </div>
               {{/if}}

Modified: incubator/ambari/trunk/ambari-web/app/templates/main/mirroring.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/mirroring.hbs?rev=1465166&r1=1465165&r2=1465166&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/mirroring.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/mirroring.hbs Sat Apr  6 01:55:42 2013
@@ -16,73 +16,5 @@
 * limitations under the License.
 }}
 
-<div id="mirroring">
-
-  <table class="datatable table table-bordered table-striped">
-    <thead>
-    <tr>
-        {{#view view.sortView contentBinding="view.filteredContent"}}
-          <th class="first"> </th>
-          {{view view.parentView.nameSort}}
-          {{view view.parentView.dataSetSourceSort}}
-          {{view view.parentView.lastSuccessSort}}
-          {{view view.parentView.lastFailSort}}
-          {{view view.parentView.lastDurationSort}}
-          {{view view.parentView.avgDataSort}}
-        {{/view}}
-    </tr>
-    <tr>
-      <th class="first"> </th>
-      <th>{{view view.nameFilterView}}</th>
-      <th>{{view view.datasetSourceFilterView}}</th>
-      <th>{{view view.lastSuccessFilterView}}</th>
-      <th>{{view view.lastFailFilterView}}</th>
-      <th>{{view view.lastDurationFilterView}}</th>
-      <th>{{view view.avgDataFilterView}}</th>
-    </tr>
-    </thead>
-    <tbody>
-    {{#if view.pageContent}}
-      {{#each dataset in view.pageContent}}
-        {{#view view.DatasetView contentBinding="dataset"}}
-
-          <td class="first">
-          </td>
-
-          <td class="name">
-            <a title="{{unbound dataset.name}}" href="#">{{unbound dataset.name}}</a>
-          </td>
-          <td>{{dataset.sourceDir}}</td>
-          <td>{{view.lastSucceededDateFormatted}}</td>
-          <td>{{view.lastFailedDateFormatted}}</td>
-
-          <td>
-            {{view.lastDurationFormatted}}
-          </td>
-
-          <td>{{dataset.avgData}}</td>
-        {{/view}}
-      {{/each}}
-    {{else}}
-      <tr>
-          <td class="first"></td>
-          <td colspan="6">
-              {{t mirroring.table.noDatasets}}
-          </td>
-      </tr>
-    {{/if}}
-    </tbody>
-  </table>
-
-  <div class="page-bar">
-    <div class="items-on-page">
-      <label>{{t common.show}}: {{view view.datasetsPerPageSelectView selectionBinding="view.displayLength"}}</label>
-    </div>
-    <div class="info">{{view.paginationInfo}}</div>
-    <div class="paging_two_button">
-      {{view view.paginationLeft}}
-      {{view view.paginationRight}}
-    </div>
-  </div>
-</div>
 
+  {{view App.MainDatasetsView}}

Added: incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/addTargetCluster.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/addTargetCluster.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/addTargetCluster.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/addTargetCluster.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,19 @@
+{{!
+* 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.
+}}
+
+{{outlet}}
\ No newline at end of file

Added: incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dataset.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dataset.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dataset.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dataset.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,101 @@
+{{!
+* 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="pull-left dataset-form">
+  <form class="form-horizontal">
+    <div class="add-data-set">
+      <table>
+        <tr>
+          <td class="percent25" colspan="1">
+            {{t mirroring.dataset.name}}
+          </td>
+          <td colspan="2" style="text-align: left">
+            {{view Ember.TextField valueBinding="model.newDataSet.name" class="span4"}}
+          </td>
+        </tr>
+        <tr>
+          <td class="spacer" colspan="3"></td>
+        </tr>
+        <tr>
+          <td colspan="1">
+            {{t mirroring.dataset.sourceDir}}
+          </td>
+          <td colspan="2" style="text-align: left">
+            {{view Ember.TextField valueBinding="model.newDataSet.sourceDir" class="span4"}}
+          </td>
+        </tr>
+        <tr>
+          <td class="spacer" colspan="3"></td>
+        </tr>
+        <tr>
+          <td colspan="1">
+            {{t mirroring.dataset.target}}
+          </td>
+          <td colspan="2" style="text-align: left">
+            {{view view.targetClusterSelect }}
+          </td>
+        </tr>
+        <tr>
+          <td class="spacer" colspan="3"></td>
+        </tr>
+        <tr>
+          <td class="spacer" colspan="1">
+            {{t mirroring.dataset.targetDir}}
+          </td>
+          <td colspan="2" style="text-align: left">
+            {{view Ember.TextField valueBinding="model.newDataSet.targetDir" class="span4"}}
+          </td>
+        </tr>
+        <tr>
+          <td class="spacer" colspan="3"></td>
+        </tr>
+        <tr>
+          <td colspan="1"> {{t mirroring.dataset.schedule}} </td>
+          <td colspan="2" style="text-align: left">
+            <div>
+              {{view Ember.TextField valueBinding="model.newDataSet.schedule.startDate" class="input-small datepicker"}}
+              {{view Ember.Select contentBinding="view.hourOptions.content" selectionBinding="view.hourOptions.selectedForStart" class="input-mini" optionLabelPath="content.value" optionValuePath="content.value"}}
+              {{view Ember.Select contentBinding="view.minuteOptions.content" selectionBinding="view.minuteOptions.selectedForStart" class="input-mini" optionLabelPath="content.value" optionValuePath="content.value"}}
+              {{view Ember.Select contentBinding="view.dayOrNightOptions.content" selectionBinding="view.dayOrNightOptions.selectedForStart" class="input-mini" optionLabelPath="content.name" optionValuePath="content.name"}}
+            </div>
+            <div>
+              {{t mirroring.dataset.schedule.to}}
+            </div>
+            <div>
+              {{view Ember.TextField valueBinding="model.newDataSet.schedule.endDate" class="input-small datepicker"}}
+              {{view Ember.Select contentBinding="view.hourOptions.content" selectionBinding="view.hourOptions.selectedForEnd" class="input-mini" optionLabelPath="content.value" optionValuePath="content.value"}}
+              {{view Ember.Select contentBinding="view.minuteOptions.content" selectionBinding="view.minuteOptions.selectedForEnd" class="input-mini" optionLabelPath="content.value" optionValuePath="content.value"}}
+              {{view Ember.Select contentBinding="view.dayOrNightOptions.content" selectionBinding="view.dayOrNightOptions.selectedForEnd" class="input-mini" optionLabelPath="content.name" optionValuePath="content.name"}}
+
+            </div>
+
+            <div class="each-row">
+              {{t mirroring.dataset.schedule.repeatEvery}}
+              {{view Ember.TextField valueBinding="view.repeatNumberSelected" class="input-mini"}}
+              {{view Ember.Select contentBinding="view.repeatOptions.content" selectionBinding="view.repeatOptions.repeatOptionSelected" class="input-small" optionLabelPath="content.value" optionValuePath="content.value"}}
+            </div>
+          </td>
+        </tr>
+      </table>
+    </div>
+  </form>
+</div>
+{{#if isPopupForEdit}}
+  <div class="pull-right dataset-delete">
+    <a {{action deleteDatasetClick target="controller"}} class="btn btn-danger">{{t common.delete}}</a>
+  </div>
+{{/if}}
\ No newline at end of file

Added: incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/datasets.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/datasets.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/datasets.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/datasets.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,117 @@
+{{!
+* 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>
+{{#if App.isAdmin}}
+    <div class="mirroring-top-nav button-section pull-right">
+        <button class="btn btn-inverse add-host-button" {{action addNewDataset}}>
+            <i class="icon-plus icon-white"></i>
+          {{t mirroring.dataset.createNewDataset}}
+        </button>
+    </div>
+{{/if}}
+</div>
+
+<div class="row-fluid">
+  <div class="span2 mirroring-sidebar">
+    <h5>{{t mirroring.sidebar.header.history}}</h5>
+    <hr />
+    <ul>
+      {{#each job in view.jobs}}
+        <li><a href="#" {{action "gotoShowJobs" job.dataset}}>{{job.dataset.name}}</a><br />{{job.startDateFormatted}}</li>
+      {{/each}}
+    </ul>
+    <h5>{{t mirroring.sidebar.header.clusters}} <span class="pull-right"><a {{action addTargetCluster controller.name}}  href="#">{{t add}}</a></span></h5>
+    <hr />
+    <ul>
+      {{#each cluster in view.targetClusters}}
+        <li><a {{action "editTargetCluster" cluster}}>{{cluster.clusterName}}</a></li>
+      {{/each}}
+    </ul>
+  </div>
+  <div class="span10">
+    <div id="mirroring">
+      <table class="table table-bordered table-striped">
+        <thead>
+        <tr>
+          {{#view view.sortView contentBinding="view.filteredContent"}}
+            <th class="first"> </th>
+            {{view view.parentView.nameSort}}
+            {{view view.parentView.dataSetSourceSort}}
+            {{view view.parentView.lastSuccessSort}}
+            {{view view.parentView.lastFailSort}}
+            {{view view.parentView.lastDurationSort}}
+            {{view view.parentView.avgDataSort}}
+          {{/view}}
+        </tr>
+        <tr>
+          <th class="first"> </th>
+          <th>{{view view.nameFilterView}}</th>
+          <th>{{view view.datasetSourceFilterView}}</th>
+          <th>{{view view.lastSuccessFilterView}}</th>
+          <th>{{view view.lastFailFilterView}}</th>
+          <th>{{view view.lastDurationFilterView}}</th>
+          <th>{{view view.avgDataFilterView}}</th>
+        </tr>
+        </thead>
+        <tbody>
+        {{#if view.pageContent}}
+        {{!#each dataset in view.pageContent}}
+        {{#each dataset in datasets}}
+            {{#view view.DatasetView contentBinding="dataset"}}
+
+              <td class="first">
+              </td>
+
+              <td class="name">
+                <a title="{{unbound dataset.name}}" href="#" {{action "gotoShowJobs" dataset}}>{{unbound dataset.name}}</a>
+              </td>
+              <td>{{dataset.sourceDir}}</td>
+              <td>{{view.lastSucceededDateFormatted}}</td>
+              <td>{{view.lastFailedDateFormatted}}</td>
+
+              <td>
+                {{view.lastDurationFormatted}}
+              </td>
+
+              <td>{{dataset.avgData}}</td>
+            {{/view}}
+          {{/each}}
+        {{else}}
+          <tr>
+            <td class="first"></td>
+            <td colspan="6">
+              {{t mirroring.table.noDatasets}}
+            </td>
+          </tr>
+        {{/if}}
+        </tbody>
+      </table>
+
+      <div class="page-bar">
+        <div class="items-on-page">
+          <label>{{t common.show}}: {{view view.rowsPerPageSelectView selectionBinding="view.displayLength"}}</label>
+        </div>
+        <div class="info">{{view.paginationInfo}}</div>
+        <div class="paging_two_button">
+          {{view view.paginationLeft}}
+          {{view view.paginationRight}}
+        </div>
+      </div>
+    </div>
+  </div>
+</div>
\ No newline at end of file

Added: incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dropdown.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dropdown.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dropdown.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/dropdown.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,28 @@
+{{!
+* 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="btn-group" >
+  <button class="btn targetClusterDD">{{view.selected.title}}</button>
+  <button class="btn dropdown-toggle" data-toggle="dropdown" {{!action "dropdownToggle" target="view" on="click"}}>
+    <span class="caret"></span>
+  </button>
+  <ul class="dropdown-menu">
+    {{#each view.listOfOptions}}
+      <li {{!bindAttr class="view.isActive:active"   use this to hide the selected one in the drop down }}><a href="#" {{action "select" this target="view" on="click"}}>{{title}}</a></li>
+    {{/each}}
+   </ul>
+</div>
\ No newline at end of file

Added: incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/jobs.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/jobs.hbs?rev=1465166&view=auto
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/jobs.hbs (added)
+++ incubator/ambari/trunk/ambari-web/app/templates/main/mirroring/jobs.hbs Sat Apr  6 01:55:42 2013
@@ -0,0 +1,94 @@
+{{!
+* 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="row-fluid">
+    <div class="span2 mirroring-sidebar">
+      <h5>{{t common.details}} <span class="pull-right"><a href="#" {{action gotoEditDataset view.dataset}}>{{t common.edit}}</a></span></h5>
+      <hr />
+      <p>{{t mirroring.dataset.source}}: <span class="pull-right">{{view.dataset.sourceClusterName}}</span></p>
+      <p>{{t mirroring.dataset.target}}: <span class="pull-right">{{view.dataset.targetClusterName}}</span></p>
+      <h5>{{t common.stats}}</h5>
+      <hr />
+      <p>{{t mirroring.dataset.avgData}}: <span class="pull-right">{{view.dataset.avgData}}</span></p>
+      <p>{{t mirroring.dataset.dateCreated}}: <span class="pull-right">{{view.dataset.createdDate}}</span></p>
+    </div>
+    <div class="span10">
+    <div id="mirroring">
+      <table class="table table-bordered table-striped">
+        <thead>
+        <tr>
+            {{#view view.sortView contentBinding="view.filteredContent"}}
+              <th class="first"> </th>
+              {{view view.parentView.idSort}}
+              {{view view.parentView.startSort}}
+              {{view view.parentView.endSort}}
+              {{view view.parentView.durationSort}}
+              {{view view.parentView.dataSort}}
+            {{/view}}
+        </tr>
+        <tr>
+          <th class="first"> </th>
+          <th>{{view view.idFilterView}}</th>
+          <th>{{view view.startFilterView}}</th>
+          <th>{{view view.endFilterView}}</th>
+          <th>{{view view.durationFilterView}}</th>
+          <th>{{view view.dataFilterView}}</th>
+        </tr>
+        </thead>
+        <tbody>
+        {{#if view.pageContent}}
+          {{#each job in view.pageContent}}
+            {{#view view.JobView contentBinding="job"}}
+
+              <td class="first">
+              </td>
+
+              <td>{{unbound job.id}}</td>
+              <td>{{view.startFormatted}}</td>
+              <td>{{view.endFormatted}}</td>
+
+              <td>
+                {{view.durationFormatted}}
+              </td>
+
+              <td>{{job.data}}</td>
+            {{/view}}
+          {{/each}}
+        {{else}}
+          <tr>
+              <td class="first"></td>
+              <td colspan="6">
+                  {{t mirroring.table.noJobs}}
+              </td>
+          </tr>
+        {{/if}}
+        </tbody>
+      </table>
+
+      <div class="page-bar">
+        <div class="items-on-page">
+          <label>{{t common.show}}: {{view view.rowsPerPageSelectView selectionBinding="view.displayLength"}}</label>
+        </div>
+        <div class="info">{{view.paginationInfo}}</div>
+        <div class="paging_two_button">
+          {{view view.paginationLeft}}
+          {{view view.paginationRight}}
+        </div>
+      </div>
+    </div>
+  </div>
+</div>
\ No newline at end of file