This is an automated email from the ASF dual-hosted git repository.

houxiaoyu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/master by this push:
     new 4ed8a871bfa [fix][test] testModularLoadManagerRemoveBundleAndLoad 
(#19710)
4ed8a871bfa is described below

commit 4ed8a871bfa9a7a8e30d86d782e33a556646d7b1
Author: houxiaoyu <[email protected]>
AuthorDate: Mon Mar 6 12:48:41 2023 +0800

    [fix][test] testModularLoadManagerRemoveBundleAndLoad (#19710)
---
 .../org/apache/pulsar/broker/namespace/NamespaceServiceTest.java  | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git 
a/pulsar-broker/src/test/java/org/apache/pulsar/broker/namespace/NamespaceServiceTest.java
 
b/pulsar-broker/src/test/java/org/apache/pulsar/broker/namespace/NamespaceServiceTest.java
index f4c4799e576..ac5d92c8802 100644
--- 
a/pulsar-broker/src/test/java/org/apache/pulsar/broker/namespace/NamespaceServiceTest.java
+++ 
b/pulsar-broker/src/test/java/org/apache/pulsar/broker/namespace/NamespaceServiceTest.java
@@ -45,7 +45,7 @@ import java.util.Map;
 import java.util.Optional;
 import java.util.Set;
 import java.util.concurrent.CompletableFuture;
-import java.util.concurrent.ScheduledExecutorService;
+import java.util.concurrent.ExecutorService;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.atomic.AtomicReference;
 import lombok.Cleanup;
@@ -823,10 +823,10 @@ public class NamespaceServiceTest extends BrokerTestBase {
         // Wait until "ModularLoadManager" completes processing the ZK 
notification.
         ModularLoadManagerWrapper modularLoadManagerWrapper = 
(ModularLoadManagerWrapper) loadManager;
         ModularLoadManagerImpl modularLoadManager = (ModularLoadManagerImpl) 
modularLoadManagerWrapper.getLoadManager();
-        ScheduledExecutorService scheduler = (ScheduledExecutorService) 
FieldUtils.readField(
-                modularLoadManager, "scheduler", true);
+        ExecutorService executors = (ExecutorService) FieldUtils.readField(
+                modularLoadManager, "executors", true);
         CompletableFuture<Void> waitForNoticeHandleFinishByLoadManager = new 
CompletableFuture<>();
-        scheduler.execute(() -> 
waitForNoticeHandleFinishByLoadManager.complete(null));
+        executors.execute(() -> 
waitForNoticeHandleFinishByLoadManager.complete(null));
         waitForNoticeHandleFinishByLoadManager.join();
         // Manually trigger "LoadResourceQuotaUpdaterTask"
         loadManager.writeResourceQuotasToZooKeeper();

Reply via email to