Kamal Chandraprakash created KAFKA-15272:
--------------------------------------------

             Summary: Fix the logic which finds candidate log segments to 
upload it to tiered storage
                 Key: KAFKA-15272
                 URL: https://issues.apache.org/jira/browse/KAFKA-15272
             Project: Kafka
          Issue Type: Task
            Reporter: Kamal Chandraprakash
            Assignee: Kamal Chandraprakash


In tiered storage, a segment is eligible for deletion from local disk when it 
gets uploaded to the remote storage. 

If the topic active segment contains some messages and there are no new 
incoming messages, then the active segment gets rotated to passive segment 
after the configured {{log.roll.ms}} timeout.

 

The 
[logic|https://github.com/apache/kafka/blob/trunk/core/src/main/java/kafka/log/remote/RemoteLogManager.java#L553]
 to find the candidate segment in RemoteLogManager does not include the 
recently rotated passive segment as eligible to upload it to remote storage so 
the passive segment won't be removed even after if it breaches by retention 
time/size. (ie) Topic won't be empty after it becomes stale.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to