rdhabalia commented on issue #2437: Race condition function-runtime-manager 
read old assignments
URL: https://github.com/apache/incubator-pulsar/pull/2437#issuecomment-415612533
 
 
   >  In the scheduleManager, we have a check before invoking actual scheduling:
   
   yes, exactly 
[SchedulerManager](https://github.com/apache/incubator-pulsar/blob/master/pulsar-functions/worker/src/main/java/org/apache/pulsar/functions/worker/SchedulerManager.java#L93)
 tries to schedule only if it is a leader and at that time MemberShipManager 
has not received that notification  of leader so, schedulerManager skips 
scheduling and RuntimeManager reads last available assignment.
   I am able to reproduce it in standalone function worker where 
standalone-scheduler-manager skips scheduling as it finds `isLeader()` false.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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

Reply via email to