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

Loadbalanced client src ip preservation enters beta #33957

Merged
merged 5 commits into from
Oct 20, 2016

Conversation

bprashanth
Copy link
Contributor

@bprashanth bprashanth commented Oct 3, 2016

Sounds like we're going to try out the proposal (#30819 (comment)) for annotations -> fields on just one feature in 1.5 (scheduler). Or do we want to just convert to fields right now?


This change is Reviewable

@k8s-github-robot k8s-github-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. release-note-label-needed labels Oct 3, 2016
@thockin
Copy link
Member

thockin commented Oct 3, 2016

Please re-title. "ESIPP" has almost no meaning outside our little crew in the office :)

@@ -445,7 +445,7 @@ kube::util::fetch-openapi-spec() {
# repo, e.g. "upstream" or "origin".
kube::util::git_upstream_remote_name() {
git remote -v | grep fetch |\
grep -E 'github.com[/:]kubernetes/kubernetes|k8s.io/kubernetes' |\
grep -E 'github.com[/:]kubernetes/kubernetes|k8s.io/kubernetes|GoogleCloudPlatform/kubernetes' |\
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

really? Isn't it time to change your remote? I don't think we should do this

Copy link
Member

@thockin thockin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG overall - just concerned about breaking on existing objects

in.Annotations[apiservice.AlphaAnnotationExternalTraffic] = valueBeta
}

return autoConvert_api_Service_To_v1_Service(in, out, s)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so if a user writes alpha, they will get both alpha and beta back out. I guess that is OK - just for simplicity?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in case they rollback

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I rescind my OK. Consider this:

User writes alpha

You upconvert to beta

User reads it back in newer client and changes the beta config, writes back

Which do we use? alpha or beta? They should be mutually exclusive.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clarify?

Going from v1 -> internal type, alpha clobbers beta. This will happen through kubectl etc.

Going from internal type -> v1, beta clobbers, because our internal system components do this (so assignment of healthcheck-nodeport shouldn't get clobbered by emptystring, for example).

We store in etcd as v1. On bootup apiserver reads and converts.

User reads it back in newer client and changes the beta config, writes back

So this is going from v1->internal? that will just overwrite beta with alpha.
If we end up with 2 versions, alpha wins, because presumably alpha is holding some resources from before the upgrade.

@@ -161,10 +161,10 @@ func (rs *REST) Create(ctx api.Context, obj runtime.Object) (runtime.Object, err
if shouldCheckOrAssignHealthCheckNodePort(service) {
var healthCheckNodePort int
var err error
if l, ok := service.Annotations[apiservice.AnnotationHealthCheckNodePort]; ok {
if l, ok := service.Annotations[apiservice.BetaAnnotationHealthCheckNodePort]; ok {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what about existing objects which have alpha annotation and not beta?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm copying it over during conversion, so when the apiserver/controller is restarted and gets objects down watch/list whatever they'll get substituted in when they translate to the internal type

@bprashanth bprashanth changed the title Esipp to beta Annotations preserving lb source ip graduate to beta Oct 3, 2016
@bprashanth
Copy link
Contributor Author

@k8s-bot unit test this github issue: #33880

@bprashanth
Copy link
Contributor Author

+ export PROJECT=k8s-jkns-pr-gci-gce
+ PROJECT=k8s-jkns-pr-gci-gce
�[0;33mAttempt 5 failed to create firewall rule e2e-gce-agent-pr-32-0-minion-all. Retrying.�[0m
ERROR: (gcloud.compute.firewall-rules.create) Some requests did not succeed:
 - Quota 'FIREWALLS' exceeded. Limit: 200.0

firewalls quota seems to now be available though, so kicking this

@bprashanth
Copy link
Contributor Author

@k8s-bot gce test this

@bprashanth
Copy link
Contributor Author

@k8s-bot gci gce e2e test this

@bprashanth
Copy link
Contributor Author

Still firewall quota (#33957 (comment)), @kubernetes/goog-testing delete it?

@bprashanth
Copy link
Contributor Author

@k8s-bot unit test this

@ixdy
Copy link
Member

ixdy commented Oct 4, 2016

@bprashanth project is cleaned up now.

@k8s-bot gci gce e2e test this

@k8s-github-robot k8s-github-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 5, 2016
@k8s-ci-robot
Copy link
Contributor

Jenkins verification failed for commit 2726c2c46cce135d7bce368e7b9fa57d98eee1f0. Full PR test history.

The magic incantation to run this job again is @k8s-bot verify test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-github-robot k8s-github-robot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Oct 5, 2016
@k8s-ci-robot
Copy link
Contributor

Jenkins Kubemark GCE e2e failed for commit 2726c2c46cce135d7bce368e7b9fa57d98eee1f0. Full PR test history.

The magic incantation to run this job again is @k8s-bot kubemark e2e test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-github-robot k8s-github-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Oct 6, 2016
@bprashanth bprashanth added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed release-note-label-needed labels Oct 6, 2016
@bprashanth bprashanth changed the title Annotations preserving lb source ip graduate to beta Loadbalanced client src ip preservation enters beta Oct 6, 2016
@thockin
Copy link
Member

thockin commented Oct 19, 2016

ping me when ready

@k8s-github-robot k8s-github-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 19, 2016
@k8s-ci-robot
Copy link
Contributor

Jenkins unit/integration failed for commit c0492294ec7826c12ece0191ea8627bf9fc826b7. Full PR test history.

The magic incantation to run this job again is @k8s-bot unit test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-ci-robot
Copy link
Contributor

Jenkins GCE e2e failed for commit c0492294ec7826c12ece0191ea8627bf9fc826b7. Full PR test history.

The magic incantation to run this job again is @k8s-bot cvm gce e2e test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-ci-robot
Copy link
Contributor

Jenkins GCE etcd3 e2e failed for commit c0492294ec7826c12ece0191ea8627bf9fc826b7. Full PR test history.

The magic incantation to run this job again is @k8s-bot gce etcd3 e2e test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-ci-robot
Copy link
Contributor

Jenkins GCI GCE e2e failed for commit c0492294ec7826c12ece0191ea8627bf9fc826b7. Full PR test history.

The magic incantation to run this job again is @k8s-bot gci gce e2e test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-github-robot k8s-github-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 19, 2016
@k8s-ci-robot
Copy link
Contributor

Jenkins GKE smoke e2e failed for commit 5029bb0. Full PR test history.

The magic incantation to run this job again is @k8s-bot cvm gke e2e test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@k8s-ci-robot
Copy link
Contributor

Jenkins GCI GKE smoke e2e failed for commit 5029bb0. Full PR test history.

The magic incantation to run this job again is @k8s-bot gci gke e2e test this. Please help us cut down flakes by linking to an open flake issue when you hit one in your PR.

@bprashanth
Copy link
Contributor Author

Oh yeah, the validation was kind of a pain because I wanted to lock down the pair of alpha annotations but this should be good to go. Failures are flakes @thockin

@thockin
Copy link
Member

thockin commented Oct 20, 2016

Reviewed 1 of 9 files at r6, 2 of 8 files at r11, 4 of 5 files at r12, 1 of 1 files at r14, 4 of 4 files at r15.
Review status: all files reviewed at latest revision, 2 unresolved discussions, some commit checks failed.


pkg/api/validation/validation_test.go, line 5211 at r15 (raw file):

      },
      {
          name: "LoadBalancer disallows onlyLocal alpha annotations",

test that it allows beta?


pkg/api/validation/validation_test.go, line 6485 at r15 (raw file):

      },
      {
          name: "Service disallows removing one onlyLocal alpha annotation",

Is it important to disallow the disabling of the alpha feature? I think I get the rest, but why this?


Comments from Reviewable

@bprashanth
Copy link
Contributor Author

pkg/api/validation/validation_test.go, line 6485 at r15 (raw file):

Previously, thockin (Tim Hockin) wrote…

Is it important to disallow the disabling of the alpha feature? I think I get the rest, but why this?

in general I want to lock down the alpha, no updates, creates or deletes because one can't tell how behavior changed in beta.

In this specific case, we disallow deletion of healthCheckNodePort even in beta. The only way to release that is by deleting/flipping the onlyLocal annotation, at which point the system releases the port on your behalf. If we allowed deleting onlyLocal, the user can delete alpha.onlyLocal and add beta.onlyLocal and the apiserver code either needs to copy the healthCheckNodePort automatically from alpha to beta, or release the old one and allocate the new one. Messy. So overall just felt easier to force an update to beta before anything.


Comments from Reviewable

@bprashanth
Copy link
Contributor Author

pkg/api/validation/validation_test.go, line 5211 at r15 (raw file):

Previously, thockin (Tim Hockin) wrote…

test that it allows beta?

figured e2es would break anyway, but it's easy enough to add another unittest

Comments from Reviewable

@thockin thockin added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Oct 20, 2016
@thockin
Copy link
Member

thockin commented Oct 20, 2016

LGTM

On Wed, Oct 19, 2016 at 10:48 PM, Prashanth B notifications@github.com
wrote:

pkg/api/validation/validation_test.go, line 5211 at r15
https://reviewable.kubernetes.io:443/reviews/kubernetes/kubernetes/33957#-KUVRBFILtkuJUYzccUK:-KUVcG-tDllh7uMV2v8F:bariowu
(raw file

name: "LoadBalancer disallows onlyLocal alpha annotations",
):
Previously, thockin (Tim Hockin) wrote…

test that it allows beta?

figured e2es would break anyway, but it's easy enough to add another
unittest


Comments from Reviewable
https://reviewable.kubernetes.io:443/reviews/kubernetes/kubernetes/33957


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#33957 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AFVgVAFV_21DDDuhCfyXkx-MteKT4bGvks5q1wClgaJpZM4KM6pw
.

@k8s-github-robot
Copy link

@k8s-bot test this [submit-queue is verifying that this PR is safe to merge]

@k8s-github-robot
Copy link

Automatic merge from submit-queue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants