Browse Source

AMBARI-4361. Rolling restart failure tolerance should be percentage values. (srimanth)

Srimanth Gunturi 11 years ago
parent
commit
18c04fa8ca
2 changed files with 2 additions and 2 deletions
  1. 1 1
      ambari-web/app/utils/ajax.js
  2. 1 1
      ambari-web/app/utils/batch_scheduled_requests.js

+ 1 - 1
ambari-web/app/utils/ajax.js

@@ -1286,7 +1286,7 @@ var urls = {
             }, {
               "batch_settings" : {
                 "batch_separation_in_seconds" : data.intervalTimeSeconds,
-                "task_failure_tolerance" : data.tolerateSize
+                "task_failure_tolerance" : data.toleratePercentage
               }
             } ]
           }

+ 1 - 1
ambari-web/app/utils/batch_scheduled_requests.js

@@ -143,7 +143,7 @@ module.exports = {
       },
       data: {
         intervalTimeSeconds: intervalTimeSeconds,
-        tolerateSize: tolerateSize,
+        toleratePercentage : String(Math.round((100 * tolerateSize) / restartHostComponents.length)),
         batches: this.getBatchesForRollingRestartRequest(restartHostComponents, batchSize)
       },
       success: 'successCallback',