-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Adding nodeports services to quota #22154
Adding nodeports services to quota #22154
Conversation
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
Labelling this PR as size/M |
GCE e2e build/test passed for commit 14425ba6877fe92d9aa7204f35c7edb0a50b6bed. |
Need to double check my company for CLA (sorry for this don't know what is happening). |
Does this cover pod HostPorts or just Service NodePorts? I think it is the latter - can you explain why the difference in policy? |
@thockin at the moment only NodePorts. I'm OK to cover HostsPorts either in this PR or in a follow-up, if you're OK with the approach. |
@thockin the same for |
Well, NodePorts and HostPorts are different. a HostPort is 1 node * 1 On Sun, Feb 28, 2016 at 10:22 PM, Dario Minonne notifications@github.com
|
Code submitted in this PR simply counts the NodePort type services. Not the Ports. HostPort should be similar: Just counting the container with the hostPorts spec. I'm happy to modify this if you disagree or you've better options, but my understanding is that clearly ports need to enter in the quota mechanism somehow. |
@@ -2189,6 +2189,8 @@ const ( | |||
ResourceSecrets ResourceName = "secrets" | |||
// ResourcePersistentVolumeClaims, number | |||
ResourcePersistentVolumeClaims ResourceName = "persistentvolumeclaims" | |||
// ResourceNodePorts, number | |||
ResourceNodePorts ResourceName = "nodeports" |
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.
What do you think about making this services.nodeports
instead?
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.
I'm OK. with service.nodeports
I think we should make it clear that this is related to quota nodeports associated with a service, so I am biased to that being included in the resource name. |
14425ba
to
0860452
Compare
GCE e2e build/test passed for commit 08604521e02d32d544b95a2df6c48f8ae6960930. |
@derekwaynecarr @thockin CLA issue is a pure technical problem. We're trying to solve it (not a lot of visibility on it) |
PR needs rebase |
0860452
to
1cf877d
Compare
@thockin waiting from cla, anything I need to do to improve this? |
GCE e2e build/test failed for commit 1cf877d4751e94fe4a71036e0221a91c9210da21. Please reference the list of currently known flakes when examining this failure. If you request a re-test, you must reference the issue describing the flake. |
@sdminonne PR needs rebase |
1cf877d
to
41ebce0
Compare
Rebased |
Labelling this PR as size/L |
GCE e2e build/test passed for commit 8b2701805c933e62a61cefe20a572e3f766b53c6. |
8b27018
to
27b038d
Compare
GCE e2e build/test passed for commit 27b038d9adc6e69a8487b37e6db4300637d2556f. |
} | ||
|
||
// QuotaService returns true if the service is eligible to track against a quota | ||
func QuotaService(service *api.Service) bool { |
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.
I think we should rename this since a service is always eligible to track against a quota if the quota is just on 'services' and not 'services.nodeports'. Can you rename this QuotaServiceType
returns true if the service type is eligible to track against a quota?
One nit, then this is LGTM |
27b038d
to
15b7577
Compare
@derekwaynecarr right. Thanks |
GCE e2e build/test passed for commit 15b7577. |
@derekwaynecarr done (and squashed) |
LGTM |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit 15b7577. |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit 15b7577. |
Automatic merge from submit-queue |
Automatic merge from submit-queue Adding loadBalancer services to quota system @derekwaynecarr follow up to #22154.
UPSTREAM: 70647: Always run untag when removing docker image Origin-commit: 8d848f9d6ecbae401811e1b1856bfb5b5073ec66
To fix #21677
@derekwaynecarr