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

   Fixes #21024 
   
   ### Motivation
   
   Modify the process of update topic policy. 
   
   Make topic policy can be updated correctly when user use pulsar-admin to set 
policy 
   
   ### Modifications
   
   1. Construct a new topicPolicy in internalSetRetention(), which make sure we 
do not update the value of policiesCache in two area. We only update 
policiesCache by SystemTopicBasedTopicPoliciesService#refreshTopicPoliciesCache
   2. All the method about update topicPolicy in pulsar-admin,  should respond 
success to client after policy is actually updated in policiesCache. 
   3. Retry in isRetentionUpdateSuccess(), because systemTopicReader maybe can 
not immediately read next PulsarEvent message.
   4. Improve the test in TopicPoliciesTest to make the test cover more 
complicated pulsar-admin operation. 
   
   ### Verifying this change
   
   - [x] Make sure that the change passes the CI checks.
   
   
   ### Does this pull request potentially affect one of the following parts:
   
   <!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
   
   *If the box was checked, please highlight the changes*
   
   - [ ] 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
   
   ### Documentation
   
   <!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
   
   - [ ] `doc` <!-- Your PR contains doc changes. -->
   - [ ] `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: 
   
   


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