nodece commented on code in PR #20884:
URL: https://github.com/apache/pulsar/pull/20884#discussion_r1277690804


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/BrokerService.java:
##########
@@ -2848,6 +2848,20 @@ public <T> void registerConfigurationListener(String 
configKey, Consumer<T> list
         configRegisteredListeners.put(configKey, listener);
     }
 
+    /**
+     * Allows the third-party plugin to add a custom dynamic configuration.
+     * <p>
+     * The custom dynamic configuration doesn't support setting up a listener.
+     */
+    public void addCustomDynamicConfiguration(String key, String defaultValue, 
Predicate<String> validator) {

Review Comment:
   I see, this method is used for the third-party plugin, when a dynamic 
configuration has been added, the user can use the `PulsarAdmin` to update this 
dynamic configuration, and then the plugin can also call the 
`pulsar().getPulsarResources().getDynamicConfigResources().getDynamicConfigurationAsync()`
 to get the dynamic configuration.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to