You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2021/12/23 08:44:33 UTC

[GitHub] [pulsar] Technoboy- commented on a change in pull request #13420: [Broker] Fix create the dynamic configuration resource if not exist

Technoboy- commented on a change in pull request #13420:
URL: https://github.com/apache/pulsar/pull/13420#discussion_r774410350



##########
File path: pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/BrokersBase.java
##########
@@ -181,7 +181,7 @@ public void deleteDynamicConfiguration(@PathParam("configName") String configNam
     public Map<String, String> getAllDynamicConfigurations() throws Exception {
         validateSuperUserAccess();
         try {
-            return dynamicConfigurationResources().getDynamicConfiguration();
+            return dynamicConfigurationResources().getDynamicConfiguration().orElse(Maps.newHashMap());

Review comment:
       orElse -> orElseGet.




-- 
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: commits-unsubscribe@pulsar.apache.org

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