deepthi912 opened a new pull request, #18468:
URL: https://github.com/apache/pinot/pull/18468

     ## Summary
   
     `BaseStrictRealtimeSegmentAssignment.getExistingAssignment` returned the 
**first** LLC
     segment it found for a partition. When multi-tier dedup tables rebalance 
and a partition's
     CONSUMING segment moves to a new instance pool, the older segment 
lingering in
     `idealState` can be picked first — causing the next CONSUMING segment to 
land on
     cold tier instead of hot tiers.
   
     This PR, scoped to `MultiTierStrictRealtimeSegmentAssignment`, changes the 
behavior to:
   
     1. **Pick the latest LLC segment** for the partition (highest sequence 
number),
        not the first one encountered. Iteration order of `currentAssignment` is
        lexicographic on segment name (Helix `ZNRecord.getMapFields()` is a 
`TreeMap`),
        which diverges from numeric sequence order — so explicit comparison is 
required.
     2. **Honor tier placement**: if the chosen segment has been moved to a tier
        (`SegmentZKMetadata.getTier() != null`), it lives on a different 
instance pool
        than the CONSUMING segment, so return `null` and let `assignSegment` 
fall back
        to the assignment derived from instance partitions.
   
     The base class is unchanged in behavior — the only modification is 
visibility
     (`private` → `protected`) to allow the subclass override. Single-tier 
strict
     realtime assignment is untouched.


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to