feat: add topologySpreadConstraints to Helm chart#58
Conversation
Add passthrough topologySpreadConstraints value (empty list by default) to the Helm chart, rendered conditionally in the deployment template at the pod spec level. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Issue: LFXV2-1167 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughThis PR adds optional topology spread constraints support to the lfx-v2-query-service Helm chart. A new ChangesTopology Spread Constraints Configuration
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Pull request overview
This PR updates the Helm chart for lfx-v2-query-service to support optional Kubernetes topologySpreadConstraints at the pod spec level, enabling deployments to spread replicas across nodes/zones when configured while remaining a no-op by default.
Changes:
- Add
topologySpreadConstraints: []tovalues.yamlwith inline documentation and an example. - Render
spec.template.spec.topologySpreadConstraintsconditionally intemplates/deployment.yamlonly when non-empty.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| charts/lfx-v2-query-service/values.yaml | Introduces a documented topologySpreadConstraints value with an empty default to preserve current behavior. |
| charts/lfx-v2-query-service/templates/deployment.yaml | Conditionally renders topologySpreadConstraints in the pod spec when configured. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
topologySpreadConstraints: []tovalues.yaml(empty default, no-op unless overridden){{- with .Values.topologySpreadConstraints }}block todeployment.yamlat the pod spec levelTest plan
helm lintpasses with no errorshelm templatewith empty default produces notopologySpreadConstraintsblockhelm templatewith constraints set renders correctly at pod spec levelContext
Part of LFXV2-1167: add topology spread constraints to all LFX v2 services so pods spread across nodes and availability zones, preventing a single node drain from taking out all replicas.
🤖 Generated with Claude Code