jugomezv opened a new issue, #10049:
URL: https://github.com/apache/pinot/issues/10049

   As example take a look at this code:
   `     try {
           if (!(acquiredSegment instanceof LLRealtimeSegmentDataManager)) {
             // We found an LLC segment that is not consuming right now, must 
be that we already swapped it with a
             // segment that has been built. Nothing to do for this state 
transition.
             _logger
                 .info("Segment {} not an instance of 
LLRealtimeSegmentDataManager. Reporting success for the transition",
                     acquiredSegment.getSegmentName());
             return;
           }
           LLRealtimeSegmentDataManager segmentDataManager = 
(LLRealtimeSegmentDataManager) acquiredSegment;
           SegmentZKMetadata segmentZKMetadata = ZKMetadataProvider
               .getSegmentZKMetadata(_instanceDataManager.getPropertyStore(), 
realtimeTableName, segmentNameStr);
           segmentDataManager.goOnlineFromConsuming(segmentZKMetadata);
         } catch (InterruptedException e) {
           String errorMessage = String.format("State transition interrupted 
for segment %s.", segmentNameStr);
           _logger.warn(errorMessage, e);
           tableDataManager
               .addSegmentError(segmentNameStr, new 
SegmentErrorInfo(System.currentTimeMillis(), errorMessage, e));
           throw new RuntimeException(e);
         } finally {
           tableDataManager.releaseSegment(acquiredSegment);
         }`
   
   The details of realtime segment data manger should be handled in that class 
on a method called when this transitions for all types of segment data 
managers. Default NOP implementation can be used for other types of segement 
data managers


-- 
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: commits-unsubscr...@pinot.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to