jiajunwang commented on issue #690: Reset the WAGED rebalancer once the 
controller newly acquires leadership.
URL: https://github.com/apache/helix/pull/690#issuecomment-577445579
 
 
   > @jiajunwang Could we separate the scope for this change?
   > 
   > 1. Is it possible to create a PR that includes the change on resetting the 
cluster data change detector?
   > 2. The next PR would be the movement of the rebalancer to Generic Helix 
Controller. It's not too clear why this is necessary
   > 
   > > Move the stateful WAGED rebalancer to the GenericHelixController object 
instead of the rebalance stage. This is for resolving the possible race 
condition between the event processing thread and leader switch handling thread.
   > 
   > Could you explain this further? I am afraid in terms of design, we might 
be introducing a new dependency (between GenericHelixController and the 
rebalancer/stages). This doesn't seem too great to me because Helix's design I 
believe aims to keep them independent.
   
   Separate change is a good idea, will do so. So I will create another PR 
before this one. Just adding reset methods.
   As for the additional dependency that you mentioned,
   1. Another option is to keep the assignment metadata store and change 
detector in the controller. But that actually makes the story more complicated 
and introduce some skip level dependencies. I tried, this design is not looking 
nice.
   2. Even with this change, GenericHelixController does not depend on the 
stage.
   3. GenericHelixController will be bound with the WAGED rebalancer. Since it 
is stateful, tracking it in the controller makes more sense than a certain 
stage as we are doing now. Note that the stages are better to be stateless. But 
I agree it is not perfect.
   Like what we did for the several other stateful objects in the controller 
instance, I don't have a better option for now. Please let me know if you have 
a good idea.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to