Skip to content

driver/daemonset: Align node selection behavior with Kubernetes scheduler#1958

Merged
franknstyle merged 7 commits intovmware-tanzu:mainfrom
nonylene:fix-node-selection
Sep 17, 2024
Merged

driver/daemonset: Align node selection behavior with Kubernetes scheduler#1958
franknstyle merged 7 commits intovmware-tanzu:mainfrom
nonylene:fix-node-selection

Conversation

@nonylene
Copy link
Copy Markdown
Contributor

@nonylene nonylene commented Feb 5, 2024

What this PR does / why we need it:

Align node selection behavior with Kubernetes scheduler in DaemonSet driver.

Which issue(s) this PR fixes

Special notes for your reviewer:

Release note:

Align node selection behavior with Kubernetes scheduler in DaemonSet driver.

Align node filter behavior with Kuberntes scheduler
to avoid errors when both of nodeSelctor and nodeAffinity are set
to PodSpec.

> If you specify both nodeSelector and nodeAffinity, both must be satisfied for the Pod to be scheduled onto a node.
>
> https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/

Issue: vmware-tanzu#1957
Signed-off-by: nonylene <nonylene@gmail.com>
Align nodeAffinity matching behavior with Kubernetes schduler.

> If you specify multiple expressions in a single matchExpressions field associated with a term in nodeSelectorTerms, then the Pod can be scheduled onto a node only if all the expressions are satisfied (expressions are ANDed).
>
> https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/

Close vmware-tanzu#1957

Signed-off-by: nonylene <nonylene@gmail.com>
@franknstyle franknstyle self-requested a review June 27, 2024 09:35
@franknstyle franknstyle merged commit 7700f31 into vmware-tanzu:main Sep 17, 2024
@nonylene nonylene deleted the fix-node-selection branch September 17, 2024 02:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Node selector / Node affinity behavior is inconsistent with Kubernetes Scheduler

2 participants