kfaraz commented on PR #19700:
URL: https://github.com/apache/druid/pull/19700#issuecomment-5004535735

   @Fly-Style , since the methods `requireRestart` and the new one 
(`shouldRolloverTasksOnRestart`) are closely related, I wonder if we shouldn't 
just have a single method that returns a tri-state enum.
   
   The `requireRestart` method could then be changed to:
   
   ```java
   SupervisorAction getActionOnUpdateTo(SupervisorSpec proposedSpec);
   
   enum SupervisorAction
   {
     NONE, RESTART_SUPERVISOR, RESTART_SUPERVISOR_AND_TASKS
   }
   ```
   
   The advantage is that implementers would have to implement just one method 
and not need to worry about how the two methods play together. The end result 
would be much more intuitive.
   
   cc: @jtuglu1 , do you have any thoughts?


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