incubator-ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From srima...@apache.org
Subject git commit: AMBARI-3708. Reconfigure of dynamic configs not showing modified values. (srimanth)
Date Thu, 07 Nov 2013 00:00:36 GMT
Updated Branches:
  refs/heads/trunk 66dd2e84b -> 9530083bb


AMBARI-3708. Reconfigure of dynamic configs not showing modified values. (srimanth)


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

Branch: refs/heads/trunk
Commit: 9530083bb8795951aacfe7a3c55c3b683795a553
Parents: 66dd2e8
Author: Srimanth Gunturi <sgunturi@hortonworks.com>
Authored: Wed Nov 6 15:53:07 2013 -0800
Committer: Srimanth Gunturi <sgunturi@hortonworks.com>
Committed: Wed Nov 6 15:53:07 2013 -0800

----------------------------------------------------------------------
 .../app/controllers/main/service/info/configs.js | 19 +++++++++++--------
 .../validators/mapreduce2_configs_validator.js   |  6 +++---
 2 files changed, 14 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/9530083b/ambari-web/app/controllers/main/service/info/configs.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/service/info/configs.js b/ambari-web/app/controllers/main/service/info/configs.js
index f6fa803..994ead5 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -536,14 +536,17 @@ App.MainServiceInfoConfigsController = Em.Controller.extend({
       }
       if (serviceConfigProperty.get('serviceName') === this.get('content.serviceName')) {
 
-        defaults.forEach(function(defaults) {
-          for(var name in defaults) {
-            if (serviceConfigProperty.name == name) {
-              serviceConfigProperty.set('value', defaults[name]);
-              serviceConfigProperty.set('defaultValue', defaults[name]);
-            }
-          }
-        });
+        // Do not reset values when reconfiguring.
+        // This might be useful to setting better descriptions
+        // or default values sometime in the future.
+        // defaults.forEach(function(defaults) {
+        //   for(var name in defaults) {
+        //    if (serviceConfigProperty.name == name) {
+        //       serviceConfigProperty.set('value', defaults[name]);
+        //       serviceConfigProperty.set('defaultValue', defaults[name]);
+        //     }
+        //   }
+        // });
 
         if (s.configsValidator) {
           var validators = s.configsValidator.get('configValidators');

http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/9530083b/ambari-web/app/utils/configs/validators/mapreduce2_configs_validator.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/utils/configs/validators/mapreduce2_configs_validator.js b/ambari-web/app/utils/configs/validators/mapreduce2_configs_validator.js
index d2f30d2..b1e2583 100644
--- a/ambari-web/app/utils/configs/validators/mapreduce2_configs_validator.js
+++ b/ambari-web/app/utils/configs/validators/mapreduce2_configs_validator.js
@@ -39,11 +39,11 @@ App.MapReduce2ConfigsValidator = App.ServiceConfigsValidator.create({
   configProperties: [],
 
   mapreduceMapJavaOpts: function(config) {
-    return this.validatorLessThenDefaultValue(config);
+    return null;
   },
 
   mapreduceReduceJavaOpts: function(config) {
-	return this.validatorLessThenDefaultValue(config);
+    return null;
   },
 
   mapreduceTaskIoSortMb: function(config) {
@@ -63,7 +63,7 @@ App.MapReduce2ConfigsValidator = App.ServiceConfigsValidator.create({
   },
 
   yarnAppMapreduceAmCommandOpts: function(config) {
-    return this.validatorLessThenDefaultValue(config);
+    return null;
   }
 
 });


Mime
View raw message