raghavyadav01 commented on code in PR #19053:
URL: https://github.com/apache/pinot/pull/19053#discussion_r3670405676
##########
pinot-core/src/main/java/org/apache/pinot/core/data/manager/BaseTableDataManager.java:
##########
@@ -1248,6 +1248,10 @@ public SegmentDataManager registerSegment(String
segmentName, SegmentDataManager
oldSegmentDataManager = _segmentDataManagerMap.put(segmentName,
segmentDataManager);
}
_recentlyDeletedSegments.invalidate(segmentName);
+ // Fire the post-registration lifecycle hook now that the segment is
swapped into the serving set
+ for (IndexSegment segment : segmentDataManager.getReportableSegments()) {
+ segment.onSegmentAdded();
+ }
Review Comment:
`onSegmentAdded()` fires inline here on the segment-registration / Helix
state-transition thread. The best-effort wrappers in the implementations catch
exceptions but not latency/hangs — a slow remote call in an override would
stall segment registration and the state transition itself, with no timeout or
async offload. Should we tighten the SPI javadoc to require implementations be
bounded/non-blocking (it currently only says failures must be handled
internally), or do the I/O asynchronously in the override?
--
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]