-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We have two locks: - per-pod lock to prevent parallel operations - plugin-level lock to prevent races on network configurations We don't actually use the latter correctly; we could find ourselves in a funny state where we read default network name A, but then it changes before we issue the CNI ADD. So, just hold the plugin read-lock during all pod operations. This prevents any sort of racing between pod operations and config reloading. An extra quirk is that we opportunistically re-sync config on failure. This is to fix a podman test flake. It needs a bit of awkward re-locking but it should rarely happen. It's also not a deadlock risk thanks to careful ordering. Signed-off-by: Casey Callendrello <[email protected]>
- Loading branch information
Showing
1 changed file
with
38 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters