Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix a race condition where machineset reconciles too quickly
The race condition is where the machineset reconciles on the same key too quickly, where the creation/deletion of machines is not detected by the second reconcilation, causing it create/delete additional machines. I attempted to use WaitForCacheSync, but that is also insufficient in preventing the race condition. The fix here is to add 1 second sleep before releasing the mutex lock when reconciling, which gives the system a chance to recognize the changes made from the first reconciliation. Issue kubernetes-sigs#245 was created to improve this hacky fix.
- Loading branch information