Skip to content

adding soft topology spread constraints - #479

Open
dmesser wants to merge 1 commit into
quay:masterfrom
dmesser:topology-contraints
Open

adding soft topology spread constraints#479
dmesser wants to merge 1 commit into
quay:masterfrom
dmesser:topology-contraints

Conversation

@dmesser

@dmesser dmesser commented Jun 28, 2021

Copy link
Copy Markdown
Contributor

Signed-off-by: Daniel Messer dmesser@redhat.com

Adding soft topology constraints to drive scheduling as much as possible for Quay and related components to remain available in the event of node or entire zone failures.

Summary by Sourcery

Enhancements:

  • Implement topology spread constraints for Quay, Clair, and Mirror deployments to ensure better distribution across Kubernetes zones and nodes

Signed-off-by: Daniel Messer <dmesser@redhat.com>
@openshift-ci

openshift-ci Bot commented Jul 7, 2022

Copy link
Copy Markdown

@dmesser: PR needs rebase.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@deshpandevlab

Copy link
Copy Markdown
Contributor

@sourcery-ai summary

@deshpandevlab

Copy link
Copy Markdown
Contributor

@sourcery-ai guide

@sourcery-ai

sourcery-ai Bot commented Apr 3, 2025

Copy link
Copy Markdown

Reviewer's Guide by Sourcery

This pull request introduces topology spread constraints to the Quay, Clair, and Mirror deployments. These constraints ensure that pods are distributed across Kubernetes zones and nodes, enhancing availability and resilience. The maxSkew is set to 1, and whenUnsatisfiable is set to ScheduleAnyway to allow scheduling even if the constraints cannot be fully met.

No diagrams generated as the changes look simple and do not need a visual representation.

File-Level Changes

Change Details Files
Added topology spread constraints to Quay, Clair, and Mirror deployments.
  • Added a topology spread constraint for the topology.kubernetes.io/zone topology key.
  • Added a topology spread constraint for the kubernetes.io/hostname topology key.
  • Set maxSkew to 1 for both constraints.
  • Set whenUnsatisfiable to ScheduleAnyway for both constraints.
  • Used a labelSelector to match pods with the quay-component label.
kustomize/base/quay.deployment.yaml
kustomize/components/clair/clair.deployment.yaml
kustomize/components/mirror/mirror.deployment.yaml

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!
  • Generate a plan of action for an issue: Comment @sourcery-ai plan on
    an issue to generate a plan of action for it.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@deshpandevlab

Copy link
Copy Markdown
Contributor

@sourcery-ai review

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey @dmesser - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Consider using a Kustomize transformer to avoid duplicating the topologySpreadConstraints in each deployment.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@HammerMeetNail

Copy link
Copy Markdown
Collaborator

@sourcery-ai review

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey @dmesser - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Consider using a Kustomize transformer to avoid repeating the topologySpreadConstraints in each deployment.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Review instructions: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@HammerMeetNail

Copy link
Copy Markdown
Collaborator

@sourcery-ai review

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey @dmesser - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Consider using a Kustomize transformer to avoid duplicating the topologySpreadConstraints in each deployment.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Review instructions: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@openshift-ci

openshift-ci Bot commented Mar 12, 2026

Copy link
Copy Markdown

@dmesser: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/ocp-latest-verify-deps d1aa97e link true /test ocp-latest-verify-deps
ci/prow/ocp-latest-e2e d1aa97e link true /test ocp-latest-e2e
ci/prow/ocp-latest-ci-bundle-quay d1aa97e link true /test ocp-latest-ci-bundle-quay

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants