Badhsuha commented on PR #20399: URL: https://github.com/apache/pinot/pull/20399#issuecomment-7229459595
## Changes - `PinotLLCRealtimeSegmentManager.buildPartitionGroupConsumptionStatusFromZKMetadata`: Added a null check for zkMetadata.getStartOffset() (matching the existing getEndOffset() != null guard) so building consumption status does not fail when startOffset is absent. - `PinotLLCRealtimeSegmentManager.ensureAllPartitionsConsuming`: Added null checks before parsing startOffset (when all replicas of the latest segment are OFFLINE) and endOffset (when resuming consumption after an ONLINE or CONSUMING segment). When the required offset is missing, we log an error and continue to skip creating a successor segment for that partition rather than failing the entire validation loop. - `PinotLLCRealtimeSegmentManagerTest#testRepairs`: Added test coverage verifying that partitions with null `startOffset/endOffset` (both ONLINE/UPLOADED and OFFLINE) do not throw `NumberFormatException` or create successor segments, while healthy partitions in the same table continue to repair normally ## Why we skip repair instead of falling back to a default offset (smallest / largest) Adding default offset ( latest or earliest ) when startOffset or endOffset is null is unsafe for realtime ingestion: Falling back to smallest: Re-ingests already-committed data from the beginning of retention, causing duplicate records Falling back to largest: Skips any messages produced between the uploaded segment's actual end boundary and the current stream head causing data loss Because the controller cannot safely infer the exact stream offset boundary of an offset-less LLC segment, logging an error and skipping repair for that partition isolates the blast radius allowing all healthy partitions in the table to keep consuming and repairing normally, while leaving explicit offset recovery to the operator (either by populating the segment's offsets in ZK metadata or by offset manual rest ( earliest / latest ) -- 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]
