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

Document the new NodeInclusionPolicyInPodTopologySpread feature gate #35044

Merged
merged 1 commit into from
Aug 17, 2022

Conversation

kerthcet
Copy link
Member

Signed-off-by: kerthcet kerthcet@gmail.com

Ref: kubernetes/enhancements#3094
/sig scheduling

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jul 15, 2022
@netlify
Copy link

netlify bot commented Jul 15, 2022

👷 Deploy Preview for kubernetes-io-vnext-staging processing.

Name Link
🔨 Latest commit 3b0b5b9
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-io-vnext-staging/deploys/62fc533eb0e39700086103b4

@k8s-ci-robot k8s-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Jul 15, 2022
@k8s-ci-robot k8s-ci-robot added the language/en Issues or PRs related to English language label Jul 15, 2022
@k8s-ci-robot k8s-ci-robot requested a review from sftim July 15, 2022 06:09
@k8s-ci-robot k8s-ci-robot added the sig/docs Categorizes an issue or PR as relevant to SIG Docs. label Jul 15, 2022
Copy link
Contributor

@chrisnegus chrisnegus left a comment

Choose a reason for hiding this comment

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

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 18, 2022
@sftim
Copy link
Contributor

sftim commented Jul 18, 2022

This doesn't seem to be ready for review.
/lgtm cancel

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 18, 2022
@k8s-ci-robot k8s-ci-robot requested a review from chrisnegus July 18, 2022 19:45
@kerthcet kerthcet force-pushed the feat/topology-policy branch from 89c8cd9 to c20b438 Compare July 28, 2022 08:46
@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jul 28, 2022
@kerthcet kerthcet marked this pull request as ready for review July 28, 2022 08:47
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 28, 2022
@kerthcet kerthcet force-pushed the feat/topology-policy branch from c20b438 to b2683dd Compare July 28, 2022 08:54
@kerthcet
Copy link
Member Author

Document is ready to review now. cc @alculquicondor

@kerthcet kerthcet force-pushed the feat/topology-policy branch from b2683dd to fbd534d Compare July 28, 2022 08:58
@kerthcet kerthcet changed the title Add introductions to NodeInclusionPolicy Document the new NodeInclusionPolicyInPodTopologySpread feature gate Jul 28, 2022
@cathchu
Copy link
Contributor

cathchu commented Jul 29, 2022

Hey there 👋 @kerthcet, 1.25 Release Docs Shadow here!

Thanks for filing this placeholder. As a reminder, final docs PRs are due August 9th. Take a look at Documenting a release for additional information for the docs requirement for the release.

Thanks again!

@k8s-ci-robot k8s-ci-robot removed language/fr Issues or PRs related to French language language/id Issues or PRs related to Indonesian language language/uk Issues or PRs related to Ukrainian language language/zh Issues or PRs related to Chinese language labels Aug 3, 2022
@reylejano
Copy link
Member

/milestone 1.25
/assign @cathchu
/cc @kcmartin

@k8s-ci-robot k8s-ci-robot added this to the 1.25 milestone Aug 4, 2022
@k8s-ci-robot k8s-ci-robot requested a review from kcmartin August 4, 2022 05:15
@@ -123,6 +125,33 @@ your cluster. Those fields are:
See [Label Selectors](/docs/concepts/overview/working-with-objects/labels/#label-selectors)
for more details.
Copy link
Member

Choose a reason for hiding this comment

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

We have improved our API docs a lot to include definitions of "topology domain", "eligible domain", and others. For example: https://github.com/kubernetes/api/blob/c8f06018bfc8e3c8213c53ec87b7fa4e2b9121ab/core/v1/types.go#L3396

Could you add those in this doc?

Maybe we could add the definitions before talking about the field themselves.

Copy link
Contributor

Choose a reason for hiding this comment

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

It's also OK to link to https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#scheduling (ie, in Markdown it'd be [anchor text](/docs/reference/kubernetes-api/workload-resources/pod-v1/#scheduling)) if that's useful. No need to repeat the API reference word-for-word.

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks, updated

@@ -556,7 +585,7 @@ section of the enhancement proposal about Pod topology spread constraints.
cluster. This could lead to a problem in autoscaled clusters, when a node pool (or
node group) is scaled to zero nodes, and you're expecting the cluster to scale up,
because, in this case, those topology domains won't be considered until there is
at least one node in them.
Copy link
Contributor

Choose a reason for hiding this comment

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

Please retain the line break here (triggered by two spaces at the end of the line).

Copy link
Member Author

Choose a reason for hiding this comment

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

Should we? I found other paragraphs don't have this. It was auto formatted.

Copy link
Member

Choose a reason for hiding this comment

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

Maybe use an actual empty line?

Copy link
Contributor

Choose a reason for hiding this comment

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

If you'd like to insist this change, at least make it a separate commit (or even separate PR). It's not part of documenting NodeInclusionPolicyInPodTopologySpread.

Copy link
Member Author

Choose a reason for hiding this comment

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

hold for #35966
/hold

@@ -1010,7 +1010,7 @@ Each feature gate is designed for enabling/disabling a specific feature:
allowing the selection of a port range instead of a single port.
- `NetworkPolicyStatus`: Enable the `status` subresource for NetworkPolicy objects.
- `NodeInclusionPolicyInPodTopologySpread`: Enable using `nodeAffinityPolicy` and `nodeTaintsPolicy`
in Pod [topology spread constraints](/docs/concepts/workloads/pods/pod-topology-spread-constraints/)
in Pod [topology spread constraints](/docs/concepts/scheduling-eviction/topology-spread-constraints/)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
in Pod [topology spread constraints](/docs/concepts/scheduling-eviction/topology-spread-constraints/)
in [Pod topology spread constraints](/docs/concepts/scheduling-eviction/topology-spread-constraints/)

Copy link
Member Author

@kerthcet kerthcet Aug 9, 2022

Choose a reason for hiding this comment

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

updated.

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 15, 2022
Copy link
Member

@alculquicondor alculquicondor left a comment

Choose a reason for hiding this comment

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

:( I forgot to send my review last week

Comment on lines 117 to 119
We consider each <key, value> as a "bucket", and try to put balanced number
of pods into each bucket.
We define a domain as a particular instance of a topology.
Copy link
Member

Choose a reason for hiding this comment

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

I just realized we were saying the same thing twice.

Suggested change
We consider each <key, value> as a "bucket", and try to put balanced number
of pods into each bucket.
We define a domain as a particular instance of a topology.
We call each instance of a topology (in other words, a <key, value> pair) a domain. The scheduler will try to put a balanced number of pods into each domain.

Copy link
Member

Choose a reason for hiding this comment

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

You can fix the API too, but we can leave that for 1.26.

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated as advised in another PR #35966, this one only focus on the new feature introduced.

@@ -556,7 +585,7 @@ section of the enhancement proposal about Pod topology spread constraints.
cluster. This could lead to a problem in autoscaled clusters, when a node pool (or
node group) is scaled to zero nodes, and you're expecting the cluster to scale up,
because, in this case, those topology domains won't be considered until there is
at least one node in them.
Copy link
Member

Choose a reason for hiding this comment

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

Maybe use an actual empty line?

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 16, 2022
@alculquicondor
Copy link
Member

I can lgtm after rebase

Signed-off-by: kerthcet <kerthcet@gmail.com>
@kerthcet kerthcet force-pushed the feat/topology-policy branch from 4a66046 to 3b0b5b9 Compare August 17, 2022 02:32
@kerthcet
Copy link
Member Author

Rebased.

@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 17, 2022
@kerthcet
Copy link
Member Author

/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 17, 2022
@tengqm
Copy link
Contributor

tengqm commented Aug 17, 2022

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: tengqm

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 17, 2022
@cathchu
Copy link
Contributor

cathchu commented Aug 17, 2022

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 17, 2022
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: ae161d09cb8f224bc723ba5f1763063b69d79572

@k8s-ci-robot k8s-ci-robot merged commit a98137b into kubernetes:dev-1.25 Aug 17, 2022
@kerthcet kerthcet deleted the feat/topology-policy branch August 17, 2022 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. language/en Issues or PRs related to English language lgtm "Looks good to me", indicates that a PR is ready to be merged. sig/docs Categorizes an issue or PR as relevant to SIG Docs. sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants