ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From atk...@apache.org
Subject ambari git commit: AMBARI-9194 Description for Finalize needs to be more specific. Finalize action needs to have a confirmation. (atkach)
Date Mon, 19 Jan 2015 15:07:04 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk bcae2e893 -> 6121d56df


AMBARI-9194 Description for Finalize needs to be more specific. Finalize action needs to have
a confirmation. (atkach)


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

Branch: refs/heads/trunk
Commit: 6121d56df94db25cc8d69ac4e24f96690281906d
Parents: bcae2e8
Author: Andrii Tkach <atkach@hortonworks.com>
Authored: Mon Jan 19 15:31:55 2015 +0200
Committer: Andrii Tkach <atkach@hortonworks.com>
Committed: Mon Jan 19 17:06:33 2015 +0200

----------------------------------------------------------------------
 ambari-web/app/messages.js                      |  5 ++
 .../stack_upgrade/stack_upgrade_wizard.hbs      | 53 ++++++++++++++------
 .../admin/stack_upgrade/upgrade_wizard_view.js  | 16 +++---
 3 files changed, 50 insertions(+), 24 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/6121d56d/ambari-web/app/messages.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index c97f334..cb53d1b 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1330,6 +1330,11 @@ Em.I18n.translations = {
 
   'admin.stackVersions.details.install.hosts.popup.title': "Install {0} version",
 
+  'admin.stackUpgrade.finalize.later': "Finalize Later",
+  'admin.stackUpgrade.finalize.message': "Your cluster version has been upgraded. " +
+  "Click on <b>Finalize</b> when you are ready to finalize the upgrade and commit
to the new version." +
+  " You are strongly encouraged to run tests on your cluster to ensure it is fully operational
before finalizing." +
+  " <b>You cannot go back to the original version once the upgrade is finalized.</b>",
   'admin.stackUpgrade.doThisLater': "Do This Later",
   'admin.stackUpgrade.downgrade.proceed': "Proceed with Downgrade",
   'admin.stackUpgrade.downgrade.title': "Downgrade to {0}",

http://git-wip-us.apache.org/repos/asf/ambari/blob/6121d56d/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
index 5eec60c..93b9177 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/stack_upgrade_wizard.hbs
@@ -67,7 +67,7 @@
                 {{#if view.isDowngradeAvailable}}
                   <button class="btn btn-danger" {{action confirmDowngrade target="controller"}}>{{t
common.downgrade}}</button>
                 {{/if}}
-                {{#if view.isSkipable}}
+                {{#if view.failedItem.skippable}}
                   <button class="btn btn-warning" {{action continue view.failedItem target="view"}}>{{t
admin.stackUpgrade.dialog.continue}}</button>
                 {{else}}
                   <button class="btn btn-danger" {{action cancel view.failedItem target="view"}}>{{t
admin.stackUpgrade.dialog.cancel}}</button>
@@ -78,24 +78,45 @@
           </div>
         {{/if}}
         {{#if view.manualItem}}
-          <div class="box details-box">
-            <p><strong>{{t admin.stackUpgrade.dialog.manual}}</strong></p>
-            <p>{{view.manualItem.text}}</p>
+          {{#if view.isFinalizeItem}}
+            <div class="box details-box">
+              <p><strong>{{t admin.stackUpgrade.dialog.manual}}</strong></p>
+              <p>{{t admin.stackUpgrade.finalize.message}}</p>
 
-            <div class="message">
-              {{view Em.Checkbox checkedBinding="view.isManualDone"}}
-              {{t admin.stackUpgrade.dialog.manualDone}}
+              <div class="message">
+                {{view Em.Checkbox checkedBinding="view.isManualDone"}}
+                {{t admin.stackUpgrade.dialog.manualDone}}
+              </div>
+              <div class="button-row">
+                {{#if view.isDowngradeAvailable}}
+                  <button class="btn btn-danger" {{action confirmDowngrade target="controller"}}>{{t
common.downgrade}}</button>
+                {{/if}}
+                <button class="btn" {{action closeWizard target="view.parentView"}}>{{t
admin.stackUpgrade.finalize.later}}</button>
+                <button class="btn btn-success" {{bindAttr disabled="view.isManualProceedDisabled"}}
{{action complete view.manualItem target="view"}}>
+                  {{t common.finalize}}
+                </button>
+              </div>
             </div>
-            <div class="button-row">
-              {{#if view.isDowngradeAvailable}}
-                <button class="btn btn-danger" {{action confirmDowngrade target="controller"}}>{{t
common.downgrade}}</button>
-              {{/if}}
-              <button class="btn" {{action closeWizard target="view.parentView"}}>{{t
admin.stackUpgrade.doThisLater}}</button>
-              <button class="btn btn-success" {{bindAttr disabled="view.isManualProceedDisabled"}}
{{action complete view.manualItem target="view"}}>
-                {{t common.proceed}}
-              </button>
+          {{else}}
+            <div class="box details-box">
+              <p><strong>{{t admin.stackUpgrade.dialog.manual}}</strong></p>
+              <p>{{view.manualItem.text}}</p>
+
+              <div class="message">
+                {{view Em.Checkbox checkedBinding="view.isManualDone"}}
+                {{t admin.stackUpgrade.dialog.manualDone}}
+              </div>
+              <div class="button-row">
+                {{#if view.isDowngradeAvailable}}
+                  <button class="btn btn-danger" {{action confirmDowngrade target="controller"}}>{{t
common.downgrade}}</button>
+                {{/if}}
+                <button class="btn" {{action closeWizard target="view.parentView"}}>{{t
admin.stackUpgrade.doThisLater}}</button>
+                <button class="btn btn-success" {{bindAttr disabled="view.isManualProceedDisabled"}}
{{action complete view.manualItem target="view"}}>
+                  {{t common.proceed}}
+                </button>
+              </div>
             </div>
-          </div>
+          {{/if}}
         {{/if}}
       </div>
       {{#each group in view.upgradeGroups}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/6121d56d/ambari-web/app/views/main/admin/stack_upgrade/upgrade_wizard_view.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/admin/stack_upgrade/upgrade_wizard_view.js b/ambari-web/app/views/main/admin/stack_upgrade/upgrade_wizard_view.js
index cd1d344..faa35b9 100644
--- a/ambari-web/app/views/main/admin/stack_upgrade/upgrade_wizard_view.js
+++ b/ambari-web/app/views/main/admin/stack_upgrade/upgrade_wizard_view.js
@@ -138,14 +138,6 @@ App.upgradeWizardView = Em.View.extend({
   }.property('failedItem.status'),
 
   /**
-   * indicate whether failed item can be skipped or retried in order to continue Upgrade
-   * @type {boolean}
-   */
-  isSkipable: function () {
-    return this.get('failedItem.skippable');
-  }.property('failedItem.skippable'),
-
-  /**
    * @type {boolean}
    */
   isManualDone: false,
@@ -166,6 +158,14 @@ App.upgradeWizardView = Em.View.extend({
   }.property('activeGroup.upgradeItems.@each.status'),
 
   /**
+   * indicate whether the step is Finalize
+   * @type {boolean}
+   */
+  isFinalizeItem: function () {
+    return this.get('manualItem.context') === 'Confirm Finalize';
+  }.property('manualItem.context'),
+
+  /**
    * label of Upgrade status
    * @type {string}
    */


Mime
View raw message