fantapsody commented on issue #6173: Log compaction fails due to timeout URL: https://github.com/apache/pulsar/issues/6173#issuecomment-581862529 The error can be reproduced if the topic is empty, as described by @KannarFr , as it will try to read the next message which is not there, and a scheduled timeout will kick in after ten seconds and complete the compaction with a TimeoutException: https://github.com/apache/pulsar/blob/13d8ecd20a3c6795405fbf5946c1907e9c90dd91/pulsar-broker/src/main/java/org/apache/pulsar/compaction/TwoPhaseCompactor.java#L106 And even if a message is produced to the empty topic after the compaction started, it will still fail with a TimeoutException as the condition to end the async loop will not be true because `lastMessageId` will be `MessageId.earliest` and always less than the id of the message just received in this case: https://github.com/apache/pulsar/blob/13d8ecd20a3c6795405fbf5946c1907e9c90dd91/pulsar-broker/src/main/java/org/apache/pulsar/compaction/TwoPhaseCompactor.java#L139 However, I have not reproduced the error when compacting a non-empty topic yet, follow the steps as @EugenDueck described. Does it reproduce the problem every time? And what if you trigger the compaction again after you see the timeout error? Could you provide a complete code snippet of exactly how you produced the messages? Thanks! @EugenDueck Also, the problem describled by @pienio7 seems to be a different one due to the empty value of the message, and I'll dig into it further.
---------------------------------------------------------------- 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] With regards, Apache Git Services
