You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by pe...@apache.org on 2022/07/15 02:36:42 UTC

[pulsar] 11/15: [fix][flaky-test] Fix flaky test testConsumerBacklogEvictionTimeQuotaWithEmptyLedger (#16419)

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

penghui pushed a commit to branch branch-2.10
in repository https://gitbox.apache.org/repos/asf/pulsar.git

commit 379506284d78dda78d3fa782b7a727d0d7341d4c
Author: gaozhangmin <ga...@qq.com>
AuthorDate: Wed Jul 13 13:12:06 2022 +0800

    [fix][flaky-test] Fix flaky test testConsumerBacklogEvictionTimeQuotaWithEmptyLedger (#16419)
    
    Co-authored-by: gavingaozhangmin <ga...@didiglobal.com>
    (cherry picked from commit 28ff97aa2e5f0e9518887c19d9a888cc9dc02009)
---
 .../java/org/apache/pulsar/broker/service/BacklogQuotaManagerTest.java   | 1 +
 1 file changed, 1 insertion(+)

diff --git a/pulsar-broker/src/test/java/org/apache/pulsar/broker/service/BacklogQuotaManagerTest.java b/pulsar-broker/src/test/java/org/apache/pulsar/broker/service/BacklogQuotaManagerTest.java
index 88f13b7324c..0cbd2c1b2e7 100644
--- a/pulsar-broker/src/test/java/org/apache/pulsar/broker/service/BacklogQuotaManagerTest.java
+++ b/pulsar-broker/src/test/java/org/apache/pulsar/broker/service/BacklogQuotaManagerTest.java
@@ -523,6 +523,7 @@ public class BacklogQuotaManagerTest {
                         .limitTime(TIME_TO_CHECK_BACKLOG_QUOTA)
                         .retentionPolicy(BacklogQuota.RetentionPolicy.consumer_backlog_eviction)
                         .build(), BacklogQuota.BacklogQuotaType.message_age);
+        config.setPreciseTimeBasedBacklogQuotaCheck(true);
         PulsarClient client = PulsarClient.builder().serviceUrl(adminUrl.toString()).statsInterval(0, TimeUnit.SECONDS)
                 .build();