AmatyaAvadhanula commented on PR #16667:
URL: https://github.com/apache/druid/pull/16667#issuecomment-2197895305

   @kfaraz @abhishekrb19 
   Thank you for your feedback!
   
   The reason I had made the change within an existing TaskAction besides 
simplicity was to ensure that segments killed from the metadata store actually 
get killed from deep storage.
   
   > (new task action) Determine the root segment IDs of the segments to be 
nuked.
   > Nuke the segments.
   > (new task action) Determine which root segment IDs are still referenced.
   
   Having multiple actions would mean that a lock revokation between the 
actions can cause the task to fail after nuking the segments during 
determination of segments to kill from deep storage. In such a case, segments 
may not be cleaned up from deep storage.
   This would not have happened with a single task action happening within a 
critical section.
   Please do let me know if this understanding is incorrect.
   
   ---
   
   However, I've changed the behaviour so that one can determine the segments 
to be killed before they are killed, with the assumption that every segment in 
the batch would be killed. 
   This can now be broken into a separate task action, and I'll make the change.


-- 
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]

Reply via email to