Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automated cherry pick of #6696: More robust system Tier creation / update (#6696) #6724

Commits on Oct 9, 2024

  1. More robust system Tier creation / update (antrea-io#6696)

    System Tier initialization should ideally wait for the Tier informer's
    cache to sync before using the lister.  Otherwise we may think that the
    system Tiers have not been created yet when in fact it is just the
    informer that has not completed the initial List operation.
    
    Additionally, we improve the logic in system Tier initialization:
    * After every failed API call, we should probably check the state of the
      informer cache again (via the lister) and decide which step is needed
      next (creation / update / nothing). In case of a failed create or
      update, this gives us the opportunity to check again if the Tier
      actually exists, and if yes, what its priority is.
    * AlreadyExists is no longer treated differently for create. The reason
      is that if the Tier already exists and for some reason it was not
      returned by the Lister, it will probably be the validation webhook
      that fails (overlapping priority), and the error won't match
      AlreadyExists.
    
    Related to antrea-io#6694
    
    Signed-off-by: Antonin Bas <[email protected]>
    antoninbas committed Oct 9, 2024
    Configuration menu
    Copy the full SHA
    101361b View commit details
    Browse the repository at this point in the history