incubator-ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yus...@apache.org
Subject svn commit: r1363204 - in /incubator/ambari/trunk: ./ hmc/html/ hmc/html/upgradeStack/ hmc/js/ hmc/php/frontend/
Date Thu, 19 Jul 2012 02:01:57 GMT
Author: yusaku
Date: Thu Jul 19 02:01:56 2012
New Revision: 1363204

URL: http://svn.apache.org/viewvc?rev=1363204&view=rev
Log:
AMBARI-650. Issues with Reconfigure Service
 (Contributed by yusaku)

Modified:
    incubator/ambari/trunk/CHANGES.txt
    incubator/ambari/trunk/hmc/html/_bootstrapJs.php
    incubator/ambari/trunk/hmc/html/initializeCluster.php
    incubator/ambari/trunk/hmc/html/manageServices.php
    incubator/ambari/trunk/hmc/html/upgradeStack/deploy.php
    incubator/ambari/trunk/hmc/html/upgradeStack/index.php
    incubator/ambari/trunk/hmc/html/upgradeStack/reconfigure.php
    incubator/ambari/trunk/hmc/html/upgradeStack/showUpgradeProgress.php
    incubator/ambari/trunk/hmc/html/upgradeStack/uninstall.php
    incubator/ambari/trunk/hmc/js/configureServicesUtils.js
    incubator/ambari/trunk/hmc/js/utils.js
    incubator/ambari/trunk/hmc/php/frontend/manageServices.php

Modified: incubator/ambari/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/CHANGES.txt?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/CHANGES.txt (original)
+++ incubator/ambari/trunk/CHANGES.txt Thu Jul 19 02:01:56 2012
@@ -81,6 +81,8 @@ Trunk (unreleased changes)
 
   BUG FIXES
 
+    AMBARI-650. Issues with Reconfigure Service (yusaku)
+
     AMBARI-647. Change back log level to INFO from DEBUG (hitesh)
 
     AMBARI-644. Fix various markup issues (yusaku) 

Modified: incubator/ambari/trunk/hmc/html/_bootstrapJs.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/_bootstrapJs.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/_bootstrapJs.php (original)
+++ incubator/ambari/trunk/hmc/html/_bootstrapJs.php Thu Jul 19 02:01:56 2012
@@ -21,6 +21,8 @@
 <link type="text/css" rel="stylesheet" href="/hmc/css/yuiCombined.css">
 <script src="/hmc/js/ext/yui-min.js"></script>
 <script src="/hmc/js/ext/yuiCombined.js"></script>
+<script src="/hmc/js/ext/jquery.min.js"></script>
+<script src="/hmc/js/ext/bootstrap.min.js"></script>
 
 <script type="text/javascript">
   var globalYui, Y;

Modified: incubator/ambari/trunk/hmc/html/initializeCluster.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/initializeCluster.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/initializeCluster.php (original)
+++ incubator/ambari/trunk/hmc/html/initializeCluster.php Thu Jul 19 02:01:56 2012
@@ -23,8 +23,6 @@
 <html>
 <head>
   <?php require "./_head.php" ?>
-  <script src="../js/ext/jquery.min.js"></script>
-  <script src="../js/ext/bootstrap.min.js"></script>
 </head>
 
 <body class="yui3-skin-sam">

Modified: incubator/ambari/trunk/hmc/html/manageServices.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/manageServices.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/manageServices.php (original)
+++ incubator/ambari/trunk/hmc/html/manageServices.php Thu Jul 19 02:01:56 2012
@@ -56,7 +56,7 @@
       /* Minimal data required to bootstrap manageServices.js. */
       var clusterName = '<?php echo $clusterName; ?>';
 
-      var jsFilesToLoad = [ 
+      var jsFilesToLoad = [
         'js/utils.js',
         'js/txnUtils.js',
         'js/configureServicesUtils.js',

Modified: incubator/ambari/trunk/hmc/html/upgradeStack/deploy.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/upgradeStack/deploy.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/upgradeStack/deploy.php (original)
+++ incubator/ambari/trunk/hmc/html/upgradeStack/deploy.php Thu Jul 19 02:01:56 2012
@@ -23,7 +23,6 @@
 <html>
 <head>
   <?php require "../_head.php" ?>
-  <script src="/hmc/js/ext/jquery.min.js"></script>
 </head>
 
 <body class="yui3-skin-sam">

Modified: incubator/ambari/trunk/hmc/html/upgradeStack/index.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/upgradeStack/index.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/upgradeStack/index.php (original)
+++ incubator/ambari/trunk/hmc/html/upgradeStack/index.php Thu Jul 19 02:01:56 2012
@@ -23,7 +23,6 @@
 <html>
 <head>
   <?php require "../_head.php" ?>
-  <script src="/hmc/js/ext/jquery.min.js"></script>
 </head>
 <body class="yui3-skin-sam">
   <div id="container">

Modified: incubator/ambari/trunk/hmc/html/upgradeStack/reconfigure.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/upgradeStack/reconfigure.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/upgradeStack/reconfigure.php (original)
+++ incubator/ambari/trunk/hmc/html/upgradeStack/reconfigure.php Thu Jul 19 02:01:56 2012
@@ -23,8 +23,6 @@
 <html>
 <head>
   <?php require "../_head.php" ?>
-  <script src="/hmc/js/ext/jquery.min.js"></script>
-  <script src="/hmc/js/ext/bootstrap.min.js"></script>
 </head>
 
 <body class="yui3-skin-sam">

Modified: incubator/ambari/trunk/hmc/html/upgradeStack/showUpgradeProgress.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/upgradeStack/showUpgradeProgress.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/upgradeStack/showUpgradeProgress.php (original)
+++ incubator/ambari/trunk/hmc/html/upgradeStack/showUpgradeProgress.php Thu Jul 19 02:01:56
2012
@@ -23,7 +23,6 @@
 <html>
 <head>
   <?php require "../_head.php" ?>
-  <script src="/hmc/js/ext/jquery.min.js"></script>
 </head>
 <body class="yui3-skin-sam">
   <div id="container">

Modified: incubator/ambari/trunk/hmc/html/upgradeStack/uninstall.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/html/upgradeStack/uninstall.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/html/upgradeStack/uninstall.php (original)
+++ incubator/ambari/trunk/hmc/html/upgradeStack/uninstall.php Thu Jul 19 02:01:56 2012
@@ -23,7 +23,6 @@
 <html>
 <head>
   <?php require "../_head.php" ?>
-  <script src="/hmc/js/ext/jquery.min.js"></script>
 </head>
 <body class="yui3-skin-sam">
   <div id="container">

Modified: incubator/ambari/trunk/hmc/js/configureServicesUtils.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/js/configureServicesUtils.js?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/js/configureServicesUtils.js (original)
+++ incubator/ambari/trunk/hmc/js/configureServicesUtils.js Thu Jul 19 02:01:56 2012
@@ -326,17 +326,21 @@
         this.setErrorReason('#' + propKey, errorReason);
       }
 
-      var firstServiceName = null;
-      // show error counts in the tab for each service that had errors
-      for (serviceName in errorCounts) {
-        if (firstServiceName === null) {
-          firstServiceName = serviceName;
+      // if this is being invoked from cluster install wizard, update tabs with error counts.
+      // else this is being invoked from reconfigure services so there are no tabs to update.
+      var tabs = $('#configureServicesTabs');
+      if (tabs.length > 0) {
+        var firstServiceName = null;
+        // show error counts in the tab for each service that had errors
+        for (serviceName in errorCounts) {
+          if (firstServiceName === null) {
+            firstServiceName = serviceName;
+          }
+          this.updateServiceErrorCount(serviceName, errorCounts[serviceName]);
         }
-        this.updateServiceErrorCount(serviceName, errorCounts[serviceName]);
+        // open the first tab that has an error
+        tabs.find('a[href="#' + firstServiceName + '"]').tab('show');
       }
-      // open the first tab that has an error
-      $('#configureServicesTabs a[href="#' + firstServiceName + '"]').tab('show');
-
       Y.one('#formStatusDivId').scrollIntoView();
 
     }.bind(this);

Modified: incubator/ambari/trunk/hmc/js/utils.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/js/utils.js?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/js/utils.js (original)
+++ incubator/ambari/trunk/hmc/js/utils.js Thu Jul 19 02:01:56 2012
@@ -110,7 +110,6 @@ if (typeof clusterName !== 'undefined') 
       formStatusDivCssClass = 'statusOk';
     }
     var formStatusDiv = Y.all("#formStatusDivId");
-    formStatusDiv.setStyle("visibility", "visible");
     formStatusDiv.show();
     formStatusDiv.set('className', '');
     formStatusDiv.addClass("formStatusBar");
@@ -120,7 +119,6 @@ if (typeof clusterName !== 'undefined') 
 
   function clearFormStatus() {
     var formStatusDiv = Y.all("#formStatusDivId");
-    formStatusDiv.setStyle("visibility", "hidden");
     formStatusDiv.hide();
     formStatusDiv.set('className', '');
     formStatusDiv.addClass("formStatusBar");

Modified: incubator/ambari/trunk/hmc/php/frontend/manageServices.php
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/hmc/php/frontend/manageServices.php?rev=1363204&r1=1363203&r2=1363204&view=diff
==============================================================================
--- incubator/ambari/trunk/hmc/php/frontend/manageServices.php (original)
+++ incubator/ambari/trunk/hmc/php/frontend/manageServices.php Thu Jul 19 02:01:56 2012
@@ -80,7 +80,9 @@ function performServiceManagement( $hmc,
          * accordingly before attempting to call $hmc->reconfigureServices().
          */
         // re-using persistConfigs code
-        $serviceManagementResult = validateAndPersistConfigsFromUser($dbAccessor, $logger,
$clusterName, $requestObj['services']);
+
+        $finalProperties = sanitizeConfigs($requestObj['services'], $logger);
+        $serviceManagementResult = validateAndPersistConfigsFromUser($dbAccessor, $logger,
$clusterName, $finalProperties);
         if ($serviceManagementResult['result'] != 0) {
           $logger->log_error("Failed to validate configs from user, error=" . $serviceManagementResult["error"]);
           return $serviceManagementResult;



Mime
View raw message