Skip to content

[Feature/NiFiCluster] Add support topologySpreadConstraint #18

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

Merged
merged 2 commits into from
Mar 15, 2022

Conversation

juldrixx
Copy link
Contributor

@juldrixx juldrixx commented Mar 15, 2022

Q A
Bug fix? no
New feature? yes
API breaks? no
Deprecations? no
Related tickets Orange-OpenSource/nifikop#210
License Apache 2.0

What's in this PR?

Adds support for the k8s 1.19+ feature topologySpreadConstraint. This feature can be used to spread NiFi nodes across AZs by placing NiFi node pods into k8s nodes which live in unique AZs.

Example:

topologySpreadConstraints:
- maxSkew: 1,
  topologyKey: 'topology.kubernetes.io/zone',
  whenUnsatisfiable: 'ScheduleAnyway',
  labelSelector:
    matchLabels:
      app: nifi

Why?

Because we want to ensure our NiFi cluster deployment is multi-az tolerant. This implementation uses native k8s types and does not change existing behavior.

Checklist

  • Implementation tested
  • Error handling code meets the guideline
  • Logging code meets the guideline
  • User guide and development docs updated (if needed)
  • Append changelog with changes

@juldrixx juldrixx requested a review from erdrix March 15, 2022 21:07
@erdrix erdrix merged commit ff1c13b into master Mar 15, 2022
@erdrix erdrix deleted the feature/support-topologySpreadConstraints branch March 15, 2022 21:20
erdrix pushed a commit that referenced this pull request Aug 3, 2022
* Adds support topologySpreadConstraint

* Update changelog
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.

2 participants