hubcio commented on code in PR #2958:
URL: https://github.com/apache/iggy/pull/2958#discussion_r2974754443


##########
core/server/src/shard/system/segments.rs:
##########
@@ -172,6 +182,16 @@ impl IggyShard {
                 continue;
             }
 
+            // Same barrier as delete_expired_segments_for_partition: do not
+            // delete segments containing unconsumed messages.
+            let min_committed = Self::min_committed_offset(
+                &partition.consumer_offsets,
+                &partition.consumer_group_offsets,
+            );
+            if min_committed.is_some_and(|barrier| first.end_offset > barrier) 
{
+                continue;
+            }
+

Review Comment:
   I added following prints when consumer/consumer group lags. deletion will be 
still blocked.
   <img width="2489" height="696" alt="image" 
src="https://github.com/user-attachments/assets/306b2218-a498-4002-8650-8153d9197110";
 />
   



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