9aman opened a new pull request, #18148:
URL: https://github.com/apache/pinot/pull/18148
## Summary
- When segment end time is invalid, the RetentionManager currently skips
the segment entirely — it is never deleted regardless of the retention policy.
This adds an optional fallback to use `segmentZKMetadata.getCreationTime()`
instead, so segments with missing/invalid end times can still be cleaned up.
- Gated behind cluster config
`controller.retentionManager.enableCreationTimeFallback` (default **false**) —
no behavior change unless explicitly opted in.
- Supports dynamic config updates via the existing cluster config change
listener — no controller restart needed.
## Test plan
- [ ] `TimeRetentionStrategyTest#testCreationTimeFallback` — unit tests
covering: fallback disabled (existing behavior preserved), fallback enabled
with valid/recent/invalid/zero creation time, valid end time takes priority
over fallback
- [ ] `RetentionManagerTest#testCreationTimeFallbackOnChange` — verifies
dynamic config toggle via `onChange()`
- [ ]
`RetentionManagerTest#testRetentionWithInvalidEndTimeAndCreationTimeFallback` —
end-to-end: segment with invalid end time is deleted when fallback is enabled
and creation time exceeds retention
--
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]