-
Notifications
You must be signed in to change notification settings - Fork 303
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
Replace all uses of Snapshotter with CloudLister #590
Conversation
Hi @agau4779. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/ok-to-test |
/assign @rramkumar1 @bowei |
5ee003d
to
676f5e1
Compare
…ation that is solely used for garbage collection
Also can you squash commits? |
if len(l) >= 2 { | ||
uid = l[len(l)-1] | ||
} | ||
c := strings.Split(name, "-") | ||
c := strings.Split(l[0], "-") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why was there a change here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Example: k8s-um-test--uid1
The first split above (L208) splits by cluster delimiter (--
), giving us ["k8s-um-test", "uid1"]. We need to split the first item of this by -
in order to get the NameComponents, which should be ["k8s", "um", "test"]. Previously we split the full name, which gives us ["k8s", "um", "test", "", "", "uid1"], since we only cared about the first two items.
Does this make sense?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added some clarifying comments in the code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it. Now that I look at the previous code, I'm surprised it even worked lol.
add L7 to syncState simplify cloudlister. use named fields in namer_test remove Cloudlist interface in favor of List() ([]string, error) method
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: agau4779, rramkumar1 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Follow-up to #514 .
Replace the use of /pkg/storage/pools.go (Snapshotter) with a CloudLister interface, to be called as-needed during Garbage Collection. This should reduce the number of calls we make to the GCE API, as well as make GC more reliable.
We will use this for L7 loadbalancers, InstanceGroups, and Backends.
Verified that this properly garbage collects IGs, Backends, and Loadbalancers (TargetProxies, Forwarding Rules, URL Maps) via manual testing