lordcheng10 commented on a change in pull request #13679:
URL: https://github.com/apache/pulsar/pull/13679#discussion_r825869444



##########
File path: 
pulsar-broker/src/test/java/org/apache/pulsar/broker/admin/AdminApiTest.java
##########
@@ -495,6 +495,34 @@ public void brokers() throws Exception {
         assertEquals(admin.clusters().getClusters(), Lists.newArrayList());
     }
 
+    @Test
+    public void testUpdateDynamicCacheConfigurationWithZkWatch() throws 
Exception {
+        // update configuration
+        admin.brokers().updateDynamicConfiguration("managedLedgerCacheSizeMB", 
"1");
+        
admin.brokers().updateDynamicConfiguration("managedLedgerCacheEvictionWatermark",
 "0.8");
+        
admin.brokers().updateDynamicConfiguration("managedLedgerCacheEvictionTimeThresholdMillis",
 "2000");
+
+        // wait config to be updated
+        for (int i = 0; i < 5; i++) {

Review comment:
       Fixed.
   PTAL,thanks! @eolivelli 

##########
File path: 
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/ManagedLedgerFactory.java
##########
@@ -179,4 +180,21 @@ void asyncOpenReadOnlyCursor(String managedLedgerName, 
Position startPosition, M
      */
     CompletableFuture<Boolean> asyncExists(String ledgerName);
 
+    /**
+     * @return return EntryCacheManager.
+     */
+    EntryCacheManager getEntryCacheManager();
+
+    /**
+     * update cache evictionTimeThreshold.
+     *
+     * @param cacheEvictionTimeThresholdNanos time threshold for eviction.
+     */
+    void updateCacheEvictionTimeThreshold(long 
cacheEvictionTimeThresholdNanos);
+
+    /**
+     * @return time threshold for eviction.
+     * */
+    long getCacheEvictionTimeThresholdNanos();

Review comment:
       Fixed.
   PTAL,thanks! @eolivelli 




-- 
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