-
Notifications
You must be signed in to change notification settings - Fork 68
Adding a remove-clusters command #146
Adding a remove-clusters command #146
Conversation
We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for the commit author(s). If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google. |
e25789d
to
7f42608
Compare
7f42608
to
f422948
Compare
CLAs look good, thanks! |
Pushed a new commit to add a few more unit tests |
Gentle ping for review |
Reviewed 16 of 17 files at r1, 2 of 2 files at r2. app/kubemci/cmd/remove_clusters.go, line 59 at r2 (raw file):
app/kubemci/cmd/remove_clusters.go, line 62 at r2 (raw file):
app/kubemci/cmd/remove_clusters.go, line 101 at r2 (raw file):
app/kubemci/cmd/remove_clusters.go, line 148 at r2 (raw file):
shouldn't we check NewIngressSyncer() for returning nil? (I know it doesn't know, but isn't the pattern to check for nil from a New* func?) app/kubemci/pkg/gcp/backendservice/backendservicesyncer.go, line 273 at r2 (raw file):
minor: can you add a comment please for my benefit? app/kubemci/pkg/gcp/backendservice/backendservicesyncer_test.go, line 221 at r2 (raw file):
app/kubemci/pkg/gcp/backendservice/fake_backendservicesyncer.go, line 66 at r2 (raw file):
put in a glog.Fatal? Would be better for folks to know that this doesn't work if they try it. app/kubemci/pkg/gcp/firewallrule/firewallrulesyncer.go, line 101 at r2 (raw file):
app/kubemci/pkg/gcp/firewallrule/firewallrulesyncer.go, line 257 at r2 (raw file):
app/kubemci/pkg/gcp/forwardingrule/forwardingrulesyncer.go, line 212 at r2 (raw file):
app/kubemci/pkg/gcp/forwardingrule/forwardingrulesyncer.go, line 219 at r2 (raw file):
copy-pasted comment needs updating. app/kubemci/pkg/gcp/instances/fake_instancegetter.go, line 24 at r2 (raw file):
app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 138 at r2 (raw file):
app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 266 at r2 (raw file):
Why is this TODO placed right here? I would either put this in the function comment, or next to ing's first use. app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 291 at r2 (raw file):
app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 383 at r2 (raw file):
app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer_test.go, line 366 at r2 (raw file):
nit: include some text besides the error Comments from Reviewable |
50c253a
to
642f29f
Compare
Review status: all files reviewed at latest revision, 17 unresolved discussions. app/kubemci/cmd/remove_clusters.go, line 59 at r2 (raw file): Previously, G-Harmon wrote…
#58 has an idea of what we can use it for. app/kubemci/cmd/remove_clusters.go, line 62 at r2 (raw file): Previously, G-Harmon wrote…
Good catch. Fixed so that required params explicitly say Required. app/kubemci/cmd/remove_clusters.go, line 101 at r2 (raw file): Previously, G-Harmon wrote…
Done. app/kubemci/cmd/remove_clusters.go, line 148 at r2 (raw file): Previously, G-Harmon wrote…
Done. app/kubemci/pkg/gcp/backendservice/backendservicesyncer.go, line 273 at r2 (raw file): Previously, G-Harmon wrote…
Sure, done app/kubemci/pkg/gcp/backendservice/backendservicesyncer_test.go, line 221 at r2 (raw file): Previously, G-Harmon wrote…
Done. app/kubemci/pkg/gcp/backendservice/fake_backendservicesyncer.go, line 66 at r2 (raw file): Previously, G-Harmon wrote…
Implemented it :) app/kubemci/pkg/gcp/firewallrule/firewallrulesyncer.go, line 101 at r2 (raw file): Previously, G-Harmon wrote…
Makes it easier to prefix "error in removing clusters from firewall rule" to all errors. app/kubemci/pkg/gcp/firewallrule/firewallrulesyncer.go, line 257 at r2 (raw file):
Good idea. Filed #147 and added link to comments in code. app/kubemci/pkg/gcp/forwardingrule/forwardingrulesyncer.go, line 212 at r2 (raw file): Previously, G-Harmon wrote…
Reworded. Hopefully its better now app/kubemci/pkg/gcp/forwardingrule/forwardingrulesyncer.go, line 219 at r2 (raw file): Previously, G-Harmon wrote…
Done. app/kubemci/pkg/gcp/instances/fake_instancegetter.go, line 24 at r2 (raw file): Previously, G-Harmon wrote…
Its a fake :) app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 138 at r2 (raw file): Previously, G-Harmon wrote…
Done. app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 266 at r2 (raw file): Previously, G-Harmon wrote…
Good point. Moved to function comment. Did the same for DeleteLoadBalancer, which had the same comment. app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 291 at r2 (raw file): Previously, G-Harmon wrote…
This is converting a map of clustername to IGs for that cluster into a flat array of all IGs. app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer.go, line 383 at r2 (raw file): Previously, G-Harmon wrote…
That depends on the caller :) app/kubemci/pkg/gcp/loadbalancer/loadbalancersyncer_test.go, line 366 at r2 (raw file): Previously, G-Harmon wrote…
Done at all places in this test. Comments from Reviewable |
Thanks for the detailed review @G-Harmon |
642f29f
to
3c1ae3e
Compare
Reviewed 9 of 9 files at r3. app/kubemci/pkg/gcp/backendservice/fake_backendservicesyncer.go, line 66 at r2 (raw file): Previously, nikhiljindal (Nikhil Jindal) wrote…
nice! app/kubemci/pkg/gcp/firewallrule/firewallrulesyncer.go, line 101 at r2 (raw file): Previously, nikhiljindal (Nikhil Jindal) wrote…
haha, ok. app/kubemci/pkg/gcp/firewallrule/firewallrulesyncer.go, line 257 at r2 (raw file): Previously, nikhiljindal (Nikhil Jindal) wrote…
thanks app/kubemci/pkg/gcp/forwardingrule/forwardingrulesyncer.go, line 212 at r2 (raw file): Previously, nikhiljindal (Nikhil Jindal) wrote…
yes, i follow now. Comments from Reviewable |
As per #58, adding a new
kubemci remove-clusters
command that users can use to remove an existing MCI from some clusters.Things left to be done:
This PR has already become too big, so will do those in follow up PRs.
cc @csbell @G-Harmon
This change is