void-ptr974 opened a new pull request, #25794:
URL: https://github.com/apache/pulsar/pull/25794

   
   
     Fixes #25775
   
     ### Motivation
   
     `CompactionConcurrencyTest.testDisableCompactionConcurrently` is flaky 
because it assumes two `__compaction` subscription delete requests will overlap.
   
     With the shared in-memory metadata store, the first delete can finish 
before the second reaches the broker. In that case both requests may complete 
successfully, so the test does not
     reliably verify the `disablingCompaction` guard.
   
     ### Modifications
   
     Make the concurrency window deterministic.
   
     The test now blocks `currentCompaction` before sending the first 
`__compaction` delete, waits until `disablingCompaction=true`, then sends the 
second delete and verifies it fails with
     `PreconditionFailedException`.
   
     After that, it completes the blocked compaction future and verifies the 
first delete succeeds and `disablingCompaction` is reset.
   
     ### Verifying this change
   
     - [x] Make sure that the change passes the CI checks.
   
     This change updates an existing test and can be verified as follows:
   
     ```bash
     ./gradlew :pulsar-broker:test --tests 
org.apache.pulsar.broker.service.persistent.CompactionConcurrencyTest 
--no-daemon
   ```
     ### Does this pull request potentially affect one of the following parts:
   
     - [ ] Dependencies (add or upgrade a dependency)
     - [ ] The public API
     - [ ] The schema
     - [ ] The default values of configurations
     - [ ] The threading model
     - [ ] The binary protocol
     - [ ] The REST endpoints
     - [ ] The admin CLI options
     - [ ] The metrics
     - [ ] Anything that affects deployment


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