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

Instance Group Manager does not remove nodes with empty string in the zone field #2658

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Sep 17, 2024

  1. Support for Nodes with Empty Zone

    Nodes can have empty zone if it not has been assigned yet.
    
    The zone was retrieved from providerID using the following Regular Expression Matching and taking the second match: ```var providerIDRE = regexp.MustCompile(`^` + "gce" + `://([^/]+)/([^/]+)/([^/]+)$`)```
    
    In the case of empty zone it was generating an Error.
    In order to allow an empty zone to match the Regular Expression, it has been updated to:
    
    ```var providerIDRE = regexp.MustCompile(`^` + "gce" + `://([^/]+)/([^/]*)/([^/]+)$`)```
    
    After that, I updated all the instances where the code was checking the error, to check also for the empty zone.
    
    I updated the Instance Group Manager to not remove the nodes which do not have a zone assigned.
    08volt committed Sep 17, 2024
    Configuration menu
    Copy the full SHA
    ecd82f1 View commit details
    Browse the repository at this point in the history