codelipenghui opened a new pull request #6795:
URL: https://github.com/apache/pulsar/pull/6795


   ### Motivation
   
   Fix some empty message related problems in the compacted topic.
   
   1. Fix message delete of a key for the batch message.
   2. Fix compaction for all empty messages in the topic. If all messages are 
empty, the compaction should delete all messages in the compacted topic. 
Without this fix, the compact task failure with NPE and the consumer can get 
all messages.
   3. Seek to the compaction horizon when the last compaction task deletes all 
messages from the compacted topic(all previous messages are deleted by empty 
message). Without this fix, the consumer will stuck because of no entries in 
the ledger that the compacted topic used.
   
   ### Verifying this change
   
   Add unit test for the changes
   
   ### Does this pull request potentially affect one of the following parts:
   
   *If `yes` was chosen, please highlight the changes*
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API: (no)
     - The schema: (no)
     - The default values of configurations: (no)
     - The wire protocol: (no)
     - The rest endpoints: (no)
     - The admin cli options: (no)
     - Anything that affects deployment: (no)
   
   ### Documentation
   
     - Does this pull request introduce a new feature? (no)
   


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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to