You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by "timyuer (via GitHub)" <gi...@apache.org> on 2023/02/23 14:06:24 UTC

[GitHub] [ambari] timyuer opened a new pull request, #3646: AMBARI-25863: Fix a problem where the 'supported-refresh-commands' Element in configuration files for service was invalided

timyuer opened a new pull request, #3646:
URL: https://github.com/apache/ambari/pull/3646

   
   ## What changes were proposed in this pull request?
   
   (Please fill in changes proposed in this fix)
   
   ## How was this patch tested?
   Modify the properties prefixed with hadoop.proxyuser in the core-site.xml file and click the button in the red box in the image.
   ![image](https://user-images.githubusercontent.com/16263438/220930068-68d6b35d-e5c6-43a5-8a11-bc17d37cd386.png)
   
   
   (Please explain how this patch was tested. Ex: unit tests, manual tests)
   (If this patch involves UI changes, please attach a screen-shot; otherwise, remove this)
   
   Please review [Ambari Contributing Guide](https://cwiki.apache.org/confluence/display/AMBARI/How+to+Contribute) before opening a pull request.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org
For additional commands, e-mail: dev-help@ambari.apache.org


[GitHub] [ambari] timyuer commented on a diff in pull request #3646: AMBARI-25863: Fix a problem where the 'supported-refresh-commands' Element in configuration files for service was invalided

Posted by "timyuer (via GitHub)" <gi...@apache.org>.
timyuer commented on code in PR #3646:
URL: https://github.com/apache/ambari/pull/3646#discussion_r1215290800


##########
ambari-server/src/main/java/org/apache/ambari/server/state/ConfigHelper.java:
##########
@@ -1743,15 +1743,22 @@ public boolean checkStaleConfigsStatusForHostComponent(ServiceComponentHost sch,
       String type = changedConfigType.getKey();
       stale |= (serviceInfo.hasConfigDependency(type) || componentInfo.hasConfigType(type));
       if (stale) {
-        changedProperties.addAll(changedConfigType.getValue());
+        for (String propertyName : changedConfigType.getValue()) {
+          changedProperties.add(type + "/" + propertyName);
+        }
       }
     }
 
     String refreshCommand = calculateRefreshCommand(stackInfo.getRefreshCommandConfiguration(), sch, changedProperties);
 
+    Map<String, HostConfig> actual = sch.getActualConfigs();
+
+    Map<String, Map<String, String>> desired = getEffectiveDesiredTags(cluster, sch.getHostName(),cluster.getDesiredConfigs());
+

Review Comment:
   Yeah, that's a great idea. But I found logs missing all the way down the data link, not just this one. Maybe we should start a discussion to improve Ambari's logging?
   Thx.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org
For additional commands, e-mail: dev-help@ambari.apache.org


[GitHub] [ambari] timyuer commented on a diff in pull request #3646: AMBARI-25863: Fix a problem where the 'supported-refresh-commands' Element in configuration files for service was invalided

Posted by "timyuer (via GitHub)" <gi...@apache.org>.
timyuer commented on code in PR #3646:
URL: https://github.com/apache/ambari/pull/3646#discussion_r1213986845


##########
ambari-server/src/main/java/org/apache/ambari/server/state/ConfigHelper.java:
##########
@@ -1743,15 +1743,22 @@ public boolean checkStaleConfigsStatusForHostComponent(ServiceComponentHost sch,
       String type = changedConfigType.getKey();
       stale |= (serviceInfo.hasConfigDependency(type) || componentInfo.hasConfigType(type));
       if (stale) {
-        changedProperties.addAll(changedConfigType.getValue());
+        for (String propertyName : changedConfigType.getValue()) {
+          changedProperties.add(type + "/" + propertyName);
+        }
       }
     }
 
     String refreshCommand = calculateRefreshCommand(stackInfo.getRefreshCommandConfiguration(), sch, changedProperties);
 
+    Map<String, HostConfig> actual = sch.getActualConfigs();
+
+    Map<String, Map<String, String>> desired = getEffectiveDesiredTags(cluster, sch.getHostName(),cluster.getDesiredConfigs());
+

Review Comment:
   > nit: any logs could help improve debugging?
   
   @virajjasani 
   Logging alone may not be enough, but I recommend using remote debug mode.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org
For additional commands, e-mail: dev-help@ambari.apache.org


[GitHub] [ambari] virajjasani commented on a diff in pull request #3646: AMBARI-25863: Fix a problem where the 'supported-refresh-commands' Element in configuration files for service was invalided

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani commented on code in PR #3646:
URL: https://github.com/apache/ambari/pull/3646#discussion_r1213347669


##########
ambari-server/src/main/java/org/apache/ambari/server/state/ConfigHelper.java:
##########
@@ -1743,15 +1743,22 @@ public boolean checkStaleConfigsStatusForHostComponent(ServiceComponentHost sch,
       String type = changedConfigType.getKey();
       stale |= (serviceInfo.hasConfigDependency(type) || componentInfo.hasConfigType(type));
       if (stale) {
-        changedProperties.addAll(changedConfigType.getValue());
+        for (String propertyName : changedConfigType.getValue()) {
+          changedProperties.add(type + "/" + propertyName);
+        }
       }
     }
 
     String refreshCommand = calculateRefreshCommand(stackInfo.getRefreshCommandConfiguration(), sch, changedProperties);
 
+    Map<String, HostConfig> actual = sch.getActualConfigs();
+
+    Map<String, Map<String, String>> desired = getEffectiveDesiredTags(cluster, sch.getHostName(),cluster.getDesiredConfigs());
+

Review Comment:
   nit: any logs could help improve debugging?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org
For additional commands, e-mail: dev-help@ambari.apache.org


[GitHub] [ambari] timyuer merged pull request #3646: AMBARI-25863: Fix a problem where the 'supported-refresh-commands' Element in configuration files for service was invalided

Posted by "timyuer (via GitHub)" <gi...@apache.org>.
timyuer merged PR #3646:
URL: https://github.com/apache/ambari/pull/3646


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org
For additional commands, e-mail: dev-help@ambari.apache.org


[GitHub] [ambari] virajjasani commented on a diff in pull request #3646: AMBARI-25863: Fix a problem where the 'supported-refresh-commands' Element in configuration files for service was invalided

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani commented on code in PR #3646:
URL: https://github.com/apache/ambari/pull/3646#discussion_r1215271579


##########
ambari-server/src/main/java/org/apache/ambari/server/state/ConfigHelper.java:
##########
@@ -1743,15 +1743,22 @@ public boolean checkStaleConfigsStatusForHostComponent(ServiceComponentHost sch,
       String type = changedConfigType.getKey();
       stale |= (serviceInfo.hasConfigDependency(type) || componentInfo.hasConfigType(type));
       if (stale) {
-        changedProperties.addAll(changedConfigType.getValue());
+        for (String propertyName : changedConfigType.getValue()) {
+          changedProperties.add(type + "/" + propertyName);
+        }
       }
     }
 
     String refreshCommand = calculateRefreshCommand(stackInfo.getRefreshCommandConfiguration(), sch, changedProperties);
 
+    Map<String, HostConfig> actual = sch.getActualConfigs();
+
+    Map<String, Map<String, String>> desired = getEffectiveDesiredTags(cluster, sch.getHostName(),cluster.getDesiredConfigs());
+

Review Comment:
   i understand, but i was just curious if you think we might be able to improve some logging here for debugging in prod env, but the changes look good, please feel free to merge the PR. Thanks



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ambari.apache.org
For additional commands, e-mail: dev-help@ambari.apache.org