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 2022/10/27 09:07:30 UTC

[GitHub] [pulsar] poorbarcode opened a new pull request, #18220: [fix][test]fix flaky test deleteNamespaceGracefully

poorbarcode opened a new pull request, #18220:
URL: https://github.com/apache/pulsar/pull/18220

   ### Motivation
   
   https://github.com/poorbarcode/pulsar/actions/runs/3267034877/jobs/5371836130
   https://github.com/apache/pulsar/actions/runs/3242148385/jobs/5326408439
   
   The original implementation determines whether to wait for the creation of `__chang_event` based on whether a broker has taken ownership of the bundle or not. However, there are often 'set namespace policy', 'unload namespace', 'delete namespace', 'split bundle', and other operations in the test case. When the `bundle unload` and the 'bundle check` concurrently execute, the method `deleteNamespaceGraceFully` will run unstably.
   
   ### Modifications
   - Instead of relying on 'bundle owned' to determine whether to wait for the creation of topic `__change_event`, change to track the creation of all system topic clients (`readers & writers`) and wait for all clients(`readers & writers`) to be created finished before deleting the namespace
   - Originally, `deleteNamespaceGraceFully` in class `BrokerTestBase`, and then `MockedPulsarServiceBaseTest` called `BrokerTestBase.deleteNamespaceGraceFully()`. But `MockedPulsarServiceBaseTest` is the super class of `BrokerTestBase`, so move method `deleteNamespaceGraceFully` to `MockedPulsarServiceBaseTest`.
   
   ### Documentation
   
   <!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
   
   - [ ] `doc` <!-- Your PR contains doc changes. Please attach the local preview screenshots (run `sh start.sh` at `pulsar/site2/website`) to your PR description, or else your PR might not get merged. -->
   - [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
   - [x] `doc-not-needed` <!-- Your PR changes do not impact docs -->
   - [ ] `doc-complete` <!-- Docs have been already added -->
   
   ### Matching PR in forked repository
   
   PR in forked repository:
   
   - https://github.com/poorbarcode/pulsar/pull/31
   


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


[GitHub] [pulsar] nodece commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
nodece commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1323022478

   @poorbarcode Could you fix these conflicts?


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


[GitHub] [pulsar] gaoran10 commented on a diff in pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
gaoran10 commented on code in PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#discussion_r1027297282


##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/auth/MockedPulsarServiceBaseTest.java:
##########
@@ -669,27 +671,57 @@ public Map<Class<?>, Collection<Class<?>>> register(Object callback, Object... c
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force)
+    protected void deleteNamespaceWithRetry(String ns, boolean force)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force, PulsarAdmin admin)
+    protected void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link MockedPulsarServiceBaseTest#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFullyByMultiPulsars(String ns, boolean force, PulsarAdmin admin,
-                                                           PulsarService...pulsars) throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsars);
+    public static void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin, PulsarService...pulsars)
+            throws Exception {
+        deleteNamespaceWithRetry(ns, force, admin, Arrays.asList(pulsars));
+    }
+
+    /**
+     * Wait until system topic "__change_event" and subscription "__compaction" are created, and then delete the namespace.
+     */
+    public static void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin,
+                                                Collection<PulsarService> pulsars) throws Exception {
+        for (PulsarService pulsar : pulsars) {
+            // Prevents new events from triggering system topic creation.
+            CanPausedNamespaceService canPausedNamespaceService =
+                    (CanPausedNamespaceService) pulsar.getNamespaceService();
+            canPausedNamespaceService.pause();
+        }
+
+        Awaitility.await().until(() -> {

Review Comment:
   Maybe we can add the most wait time.



##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/auth/MockedPulsarServiceBaseTest.java:
##########
@@ -669,27 +671,57 @@ public Map<Class<?>, Collection<Class<?>>> register(Object callback, Object... c
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force)
+    protected void deleteNamespaceWithRetry(String ns, boolean force)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force, PulsarAdmin admin)
+    protected void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link MockedPulsarServiceBaseTest#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFullyByMultiPulsars(String ns, boolean force, PulsarAdmin admin,
-                                                           PulsarService...pulsars) throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsars);
+    public static void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin, PulsarService...pulsars)
+            throws Exception {
+        deleteNamespaceWithRetry(ns, force, admin, Arrays.asList(pulsars));
+    }
+
+    /**
+     * Wait until system topic "__change_event" and subscription "__compaction" are created, and then delete the namespace.

Review Comment:
   Does the description need to be modified?



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


[GitHub] [pulsar] poorbarcode commented on a diff in pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on code in PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#discussion_r1009015758


##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/admin/AdminApi2Test.java:
##########
@@ -164,7 +164,7 @@ public void resetClusters() throws Exception {
         pulsar.getConfiguration().setForceDeleteNamespaceAllowed(true);
         for (String tenant : admin.tenants().getTenants()) {
             for (String namespace : admin.namespaces().getNamespaces(tenant)) {
-                deleteNamespaceGraceFullyByMultiPulsars(namespace, true, admin, pulsar,
+                deleteNamespaceGraceFully(namespace, true, admin, pulsar,

Review Comment:
   When `admin.namespaces().deleteNamespace()` and `auto create topic __change_event` are concurrent executed, there is a problem https://github.com/apache/pulsar/pull/17070, and `deleteNamespaceGraceFully` is used to solve this problem



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


[GitHub] [pulsar] poorbarcode commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1325973008

   /pulsarbot rerun-failure-checks


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


[GitHub] [pulsar] nodece merged pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
nodece merged PR #18220:
URL: https://github.com/apache/pulsar/pull/18220


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


[GitHub] [pulsar] poorbarcode commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1325398292

   /pulsarbot rerun-failure-checks


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


[GitHub] [pulsar] poorbarcode commented on a diff in pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on code in PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#discussion_r1031090937


##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/auth/MockedPulsarServiceBaseTest.java:
##########
@@ -669,27 +671,57 @@ public Map<Class<?>, Collection<Class<?>>> register(Object callback, Object... c
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force)
+    protected void deleteNamespaceWithRetry(String ns, boolean force)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force, PulsarAdmin admin)
+    protected void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link MockedPulsarServiceBaseTest#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFullyByMultiPulsars(String ns, boolean force, PulsarAdmin admin,
-                                                           PulsarService...pulsars) throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsars);
+    public static void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin, PulsarService...pulsars)
+            throws Exception {
+        deleteNamespaceWithRetry(ns, force, admin, Arrays.asList(pulsars));
+    }
+
+    /**
+     * Wait until system topic "__change_event" and subscription "__compaction" are created, and then delete the namespace.
+     */
+    public static void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin,
+                                                Collection<PulsarService> pulsars) throws Exception {
+        for (PulsarService pulsar : pulsars) {
+            // Prevents new events from triggering system topic creation.
+            CanPausedNamespaceService canPausedNamespaceService =
+                    (CanPausedNamespaceService) pulsar.getNamespaceService();
+            canPausedNamespaceService.pause();
+        }
+
+        Awaitility.await().until(() -> {

Review Comment:
   Already fixed.



##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/auth/MockedPulsarServiceBaseTest.java:
##########
@@ -669,27 +671,57 @@ public Map<Class<?>, Collection<Class<?>>> register(Object callback, Object... c
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force)
+    protected void deleteNamespaceWithRetry(String ns, boolean force)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link BrokerTestBase#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFully(String ns, boolean force, PulsarAdmin admin)
+    protected void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin)
             throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsar);
+        BrokerTestBase.deleteNamespaceWithRetry(ns, force, admin, pulsar);
     }
 
     /**
-     * see see {@link BrokerTestBase#deleteNamespaceGraceFully(String, boolean, PulsarAdmin, Collection)}
+     * see {@link MockedPulsarServiceBaseTest#deleteNamespaceWithRetry(String, boolean, PulsarAdmin, Collection)}
      */
-    protected void deleteNamespaceGraceFullyByMultiPulsars(String ns, boolean force, PulsarAdmin admin,
-                                                           PulsarService...pulsars) throws Exception {
-        BrokerTestBase.deleteNamespaceGraceFully(ns, force, admin, pulsars);
+    public static void deleteNamespaceWithRetry(String ns, boolean force, PulsarAdmin admin, PulsarService...pulsars)
+            throws Exception {
+        deleteNamespaceWithRetry(ns, force, admin, Arrays.asList(pulsars));
+    }
+
+    /**
+     * Wait until system topic "__change_event" and subscription "__compaction" are created, and then delete the namespace.

Review Comment:
   Already fixed.



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


[GitHub] [pulsar] codecov-commenter commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1325354379

   # [Codecov](https://codecov.io/gh/apache/pulsar/pull/18220?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#18220](https://codecov.io/gh/apache/pulsar/pull/18220?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (d442374) into [master](https://codecov.io/gh/apache/pulsar/commit/cd85a67bd3a880732678b0dfd5f7769ad90a90ef?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (cd85a67) will **decrease** coverage by `15.59%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/pulsar/pull/18220/graphs/tree.svg?width=650&height=150&src=pr&token=acYqCpsK9J&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/pulsar/pull/18220?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@              Coverage Diff              @@
   ##             master   #18220       +/-   ##
   =============================================
   - Coverage     47.39%   31.79%   -15.60%     
   + Complexity    10479     6773     -3706     
   =============================================
     Files           698      698               
     Lines         68070    68070               
     Branches       7279     7279               
   =============================================
   - Hits          32264    21646    -10618     
   - Misses        32228    43406    +11178     
   + Partials       3578     3018      -560     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | unittests | `31.79% <ø> (-15.60%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/pulsar/pull/18220?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...n/java/org/apache/pulsar/client/api/RawReader.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2NsaWVudC9hcGkvUmF3UmVhZGVyLmphdmE=) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...ava/org/apache/pulsar/broker/admin/v1/Brokers.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9hZG1pbi92MS9Ccm9rZXJzLmphdmE=) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...ava/org/apache/pulsar/broker/admin/v2/Brokers.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9hZG1pbi92Mi9Ccm9rZXJzLmphdmE=) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...va/org/apache/pulsar/broker/admin/v1/Clusters.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9hZG1pbi92MS9DbHVzdGVycy5qYXZh) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [.../org/apache/pulsar/broker/admin/v1/Properties.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9hZG1pbi92MS9Qcm9wZXJ0aWVzLmphdmE=) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [.../org/apache/pulsar/client/impl/RawMessageImpl.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2NsaWVudC9pbXBsL1Jhd01lc3NhZ2VJbXBsLmphdmE=) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [.../apache/pulsar/broker/admin/v2/ResourceGroups.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9hZG1pbi92Mi9SZXNvdXJjZUdyb3Vwcy5qYXZh) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...ar/common/naming/PartitionedManagedLedgerInfo.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2NvbW1vbi9uYW1pbmcvUGFydGl0aW9uZWRNYW5hZ2VkTGVkZ2VySW5mby5qYXZh) | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | [...e/pulsar/broker/admin/impl/ResourceQuotasBase.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9hZG1pbi9pbXBsL1Jlc291cmNlUXVvdGFzQmFzZS5qYXZh) | `0.00% <0.00%> (-96.43%)` | :arrow_down: |
   | [...he/pulsar/broker/service/AnalyzeBacklogResult.java](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9zZXJ2aWNlL0FuYWx5emVCYWNrbG9nUmVzdWx0LmphdmE=) | `0.00% <0.00%> (-92.31%)` | :arrow_down: |
   | ... and [169 more](https://codecov.io/gh/apache/pulsar/pull/18220/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
   


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


[GitHub] [pulsar] nodece commented on a diff in pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
nodece commented on code in PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#discussion_r1009032545


##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/admin/AdminApi2Test.java:
##########
@@ -164,7 +164,7 @@ public void resetClusters() throws Exception {
         pulsar.getConfiguration().setForceDeleteNamespaceAllowed(true);
         for (String tenant : admin.tenants().getTenants()) {
             for (String namespace : admin.namespaces().getNamespaces(tenant)) {
-                deleteNamespaceGraceFullyByMultiPulsars(namespace, true, admin, pulsar,
+                deleteNamespaceGraceFully(namespace, true, admin, pulsar,

Review Comment:
   > I try to fix the flaky test this way: make delete namespace after __change_events is successfully created, but there still has another race condition: the `__change_events/__compaction` async creates and `__change_events` delete by namespace delete. Therefore, I will disabled systemTopic in method `testDeleteTenant` to solve this flaky test.
   
   Do you point?
   
   If right, I suggest we should fix this first.
   
   



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


[GitHub] [pulsar] nodece commented on a diff in pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
nodece commented on code in PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#discussion_r1009014707


##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/admin/AdminApi2Test.java:
##########
@@ -164,7 +164,7 @@ public void resetClusters() throws Exception {
         pulsar.getConfiguration().setForceDeleteNamespaceAllowed(true);
         for (String tenant : admin.tenants().getTenants()) {
             for (String namespace : admin.namespaces().getNamespaces(tenant)) {
-                deleteNamespaceGraceFullyByMultiPulsars(namespace, true, admin, pulsar,
+                deleteNamespaceGraceFully(namespace, true, admin, pulsar,

Review Comment:
   I have a question, can we use the `admin.namespaces().deleteNamespace()` instead of this?
   
   `deleteNamespaceGraceFully` looks like a hack operation.
   
   



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


[GitHub] [pulsar] poorbarcode commented on a diff in pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on code in PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#discussion_r1009057214


##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/admin/AdminApi2Test.java:
##########
@@ -164,7 +164,7 @@ public void resetClusters() throws Exception {
         pulsar.getConfiguration().setForceDeleteNamespaceAllowed(true);
         for (String tenant : admin.tenants().getTenants()) {
             for (String namespace : admin.namespaces().getNamespaces(tenant)) {
-                deleteNamespaceGraceFullyByMultiPulsars(namespace, true, admin, pulsar,
+                deleteNamespaceGraceFully(namespace, true, admin, pulsar,

Review Comment:
   In user use, the probability of occurrence is almost 0. Even if it actually occurs, the user can try to execute the `delete namespace` again. But to solve this problem fundamentally requires a big change



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


[GitHub] [pulsar] poorbarcode commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1325938153

   /pulsarbot rerun-failure-checks


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


[GitHub] [pulsar] Technoboy- closed pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
Technoboy- closed pull request #18220: [fix][test]fix flaky test deleteNamespaceGracefully
URL: https://github.com/apache/pulsar/pull/18220


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


[GitHub] [pulsar] poorbarcode commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1326002931

   @nodece 
   
   > Could you fix these conflicts?
   
   Already fixed.


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


[GitHub] [pulsar] poorbarcode commented on pull request #18220: [fix][test] Fix flaky test deleteNamespaceGracefully

Posted by GitBox <gi...@apache.org>.
poorbarcode commented on PR #18220:
URL: https://github.com/apache/pulsar/pull/18220#issuecomment-1325870073

   /pulsarbot rerun-failure-checks


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