Skip to content
This repository has been archived by the owner on Dec 15, 2021. It is now read-only.

Add soft pod anti affinity #1115

Merged
merged 3 commits into from Feb 21, 2020
Merged

Add soft pod anti affinity #1115

merged 3 commits into from Feb 21, 2020

Conversation

d0x2f
Copy link
Contributor

@d0x2f d0x2f commented Feb 20, 2020

Issue Ref: None

Description:

Adds a soft pod anti affinity rule to function deployments so that, where possible, function pods are deployed to different nodes.

Being only a soft or "PreferredDuringSchedulingIgnoredDuringExecution" anti affinity rule it remains backwards compatible because if the rule can't be satisfied it'll fall back to the current behavior.

Some reading for those unfamiliar: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#inter-pod-affinity-and-anti-affinity

TODOs:

  • Ready to review
  • Automated Tests
  • Docs

I'm unsure if this needs to be documented anywhere, point me in the right direction if it should be.

Copy link
Contributor

@andresmgot andresmgot left a comment

Choose a reason for hiding this comment

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

Thanks for the PR @d0x2f !

Regarding the documentation, maybe we can add a small note in docs/advanced-function-deployment.md, before the section Deploying large functions.

pkg/utils/kubelessutil.go Outdated Show resolved Hide resolved
pkg/utils/kubelessutil.go Outdated Show resolved Hide resolved
Add created-by label match requirement.
Add small docs section.
@d0x2f
Copy link
Contributor Author

d0x2f commented Feb 20, 2020

Thanks again for reviewing @andresmgot
I've added the doc section and addressed your comments.

Copy link
Contributor

@andresmgot andresmgot left a comment

Choose a reason for hiding this comment

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

Great, thanks for the changes!

@andresmgot andresmgot merged commit 3eff84c into vmware-archive:master Feb 21, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants