kfaraz commented on code in PR #19679:
URL: https://github.com/apache/druid/pull/19679#discussion_r3572518517
##########
indexing-service/src/main/java/org/apache/druid/indexing/common/actions/SegmentTransactionalReplaceAction.java:
##########
@@ -209,49 +212,47 @@ void registerUpgradedPendingSegmentsOnSupervisor(
return;
}
- // Register each upgraded pending segment on the supervisor and summarize
the batch. The per-segment mapping is
- // unbounded (a broad REPLACE can upgrade thousands of segments), so INFO
carries aggregate counts plus a bounded
- // sample and the full mapping is materialized only when DEBUG is enabled.
- final boolean debugEnabled = log.isDebugEnabled();
- final Map<String, Integer> notifiedTasksSample = new LinkedHashMap<>();
- final Map<String, Integer> notifiedTasksBySegment = debugEnabled ? new
LinkedHashMap<>() : null;
- int registeredSegments = 0;
- int totalNotifiedTasks = 0;
+ // Try to register the upgraded pending segments with all eligible
supervisors
+ // Only the supervisor which owns a pending segment will actually register
it
+ for (String supervisorId : activeSupervisorIdWithAppendLock) {
+ registerUpgradedPendingSegmentOnSupervisor(task, toolbox,
upgradedPendingSegments, supervisorId);
Review Comment:
Most likely not, since
`SupervisorManager.registerUpgradedPendingSegmentOnSupervisor()` just logs any
exception thrown inside and returns an empty `OptionalInt`. There are no other
calls within `SegmentTransactionalReplaceAction` that are likely throw an
exception.
So, ideally, all supervisors would get the notification.
--
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]