lifepuzzlefun commented on code in PR #21193:
URL: https://github.com/apache/pulsar/pull/21193#discussion_r1335385611


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/persistent/MessageDeduplication.java:
##########
@@ -493,6 +501,12 @@ public synchronized void purgeInactiveProducers() {
         long minimumActiveTimestamp = System.currentTimeMillis() - 
TimeUnit.MINUTES
                 
.toMillis(pulsar.getConfiguration().getBrokerDeduplicationProducerInactivityTimeoutMinutes());
 
+        // if not enabled just clear all inactive producer record.
+        if (!isEnabled()) {

Review Comment:
   if we enable and disable deduplication for master code logic. the inactive 
producer will be delay for 
getBrokerDeduplicationProducerInactivityTimeoutMinutes to clean up.
   
   Do we want to check in Topic.checkMessageDeduplicationInfo to check if 
deduplication is enabled if not just skip call purgeInactiveProducers ? If yes 
the inactive producer should be clear in disable deduplication logic. 



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