Skip to content

Add optional AZ awareness topology constraints - #176

Open
nadav-govari wants to merge 2 commits into
mainfrom
nadav/az
Open

Add optional AZ awareness topology constraints#176
nadav-govari wants to merge 2 commits into
mainfrom
nadav/az

Conversation

@nadav-govari

Copy link
Copy Markdown
Contributor

Adds AZ aware routing to the Quickwit Indexer Kubernetes service. The actual API for getting the AZ from a node is only default-enabled as of Kubernetes 1.35. It's off by default and is opt-in.

@fmassot
fmassot requested a review from shuheiktgw July 7, 2026 13:41

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: dbc203a5e5

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

topologySpreadConstraints:
{{- toYaml $tsc | nindent 8 }}
{{- if .Values.azAwareness.enabled }}
{{- include "quickwit.azTopologySpreadConstraint" (include "quickwit.indexer.selectorLabels" .) | nindent 8 }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Avoid duplicating zone spread constraints

When an install already sets a global or indexer topologySpreadConstraints entry with topologyKey: topology.kubernetes.io/zone and whenUnsatisfiable: ScheduleAnyway, enabling azAwareness unconditionally prepends another constraint with the same pair before rendering the user-supplied list. Kubernetes only permits one topologySpreadConstraint for each topologyKey/whenUnsatisfiable pair, so that common existing zone-spread configuration renders an invalid StatefulSet and blocks the upgrade; skip or merge the generated constraint when the user already supplies one.

Useful? React with 👍 / 👎.

topologySpreadConstraints: []

# Availability Zone awareness
azAwareness:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I’d prefer not to introduce a dedicated azAwareness value here. The more values we add, the more featurs we need to support, so I’d like to keep this as minimal as possible.

The chart already exposes indexer.topologySpreadConstraints and indexer.serviceAnnotations, so could we use those instead?

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