Skip to content

feat(huntsman): Update the default config in the values file for Helm deployment. - #432

Merged
LinZhihao-723 merged 2 commits into
y-scope:mainfrom
LinZhihao-723:default-value-update
Aug 7, 2026
Merged

feat(huntsman): Update the default config in the values file for Helm deployment.#432
LinZhihao-723 merged 2 commits into
y-scope:mainfrom
LinZhihao-723:default-value-update

Conversation

@LinZhihao-723

@LinZhihao-723 LinZhihao-723 commented Aug 7, 2026

Copy link
Copy Markdown
Member

Description

This PR updates the following default values for Helm deployment, including:

  • EM liveness: previously, heartbeats are sent every 10 seconds, which is too sparse. Change it to send a heartbeat every second.
  • Scheduler active_job_queue_capacity: Change it from 64 to 16 since by default there're only 4 workers.
  • Scheduler dispatch_queue_capacity: Change it from 64 to 16 since by default there're only 4 workers.
  • Scheduler ready_task_capacity: Change it from 65536 to 1048576 to match storage's inbound ready queue's capacity.

Checklist

  • The PR satisfies the contribution guidelines.
  • This is a breaking change and that has been indicated in the PR title, OR this isn't a
    breaking change.
  • Necessary docs have been updated, OR no docs need to be updated.

Validation performed

  • Ensure all workflows pass.

Summary by CodeRabbit

  • Performance

    • Improved execution scheduling responsiveness by increasing the frequency of scheduler and storage heartbeat checks.
    • Expanded the ready-task queue capacity to support substantially larger workloads.
  • Reliability

    • Adjusted active and dispatch queue capacities to help maintain more predictable scheduling behaviour under load.
    • Existing capacity and timeout settings remain unchanged.

@LinZhihao-723
LinZhihao-723 requested review from a team and sitaowang1998 as code owners August 7, 2026 20:55
@coderabbitai

coderabbitai Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Walkthrough

The Helm values reduce scheduler and storage heartbeat intervals to 1 second. They also reduce active-job and dispatch queue capacities and increase ready-task capacity.

Changes

Scheduler Runtime Tuning

Layer / File(s) Summary
Runtime configuration updates
tools/deployment/spider-helm/values.yaml
Heartbeat intervals change from 10 seconds to 1 second. Active-job and dispatch queue capacities change from 64 to 16. Ready-task capacity changes from 65,536 to 1,048,576. Other timeout values remain unchanged.

Estimated code review effort: 2 (Simple) | ~10 minutes

Suggested reviewers: sitaowang1998

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the update to the default Huntsman Helm deployment configuration, which matches the main changes.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
tools/deployment/spider-helm/values.yaml (1)

44-45: 🩺 Stability & Availability | 🔵 Trivial

Keep the one-second heartbeat interval aligned with liveness timeouts.

scheduler_heartbeat_interval_sec and storage_heartbeat_interval_sec are applied verbatim to the EM liveness actors. With a one-second tick, ensure the scheduler dead_em_cutoff_sec/storage stale threshold and Kubernetes liveness probe timeout stay large enough for normal network and scheduling delay, otherwise the worker can be marked dead or replaced because a heartbeat RPC is slower than one interval.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tools/deployment/spider-helm/values.yaml` around lines 44 - 45, Update the
liveness configuration associated with scheduler_heartbeat_interval_sec and
storage_heartbeat_interval_sec so scheduler dead_em_cutoff_sec, the storage
stale threshold, and the Kubernetes liveness probe timeout provide sufficient
margin above the one-second heartbeat interval for normal RPC and scheduling
delays. Keep both heartbeat intervals at one second while aligning all related
timeout values.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@tools/deployment/spider-helm/values.yaml`:
- Around line 62-67: Before shipping the one-million-task buffer configured by
ready_task_capacity in the scheduler values, add an explicit Kubernetes memory
resource limit to this chart’s scheduler deployment and create a load test that
exercises the million-entry ready queue, including OOM and queue-saturation
behavior. Ensure the test validates the configured capacity under the
deployment’s memory limit.

---

Nitpick comments:
In `@tools/deployment/spider-helm/values.yaml`:
- Around line 44-45: Update the liveness configuration associated with
scheduler_heartbeat_interval_sec and storage_heartbeat_interval_sec so scheduler
dead_em_cutoff_sec, the storage stale threshold, and the Kubernetes liveness
probe timeout provide sufficient margin above the one-second heartbeat interval
for normal RPC and scheduling delays. Keep both heartbeat intervals at one
second while aligning all related timeout values.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c2754654-1f95-45cc-8861-4d9b34ec44c7

📥 Commits

Reviewing files that changed from the base of the PR and between b0c66b2 and cdea7df.

📒 Files selected for processing (1)
  • tools/deployment/spider-helm/values.yaml

Comment on lines +62 to +67
active_job_queue_capacity: 16
cleanup_ready_task_capacity: 256
commit_ready_task_capacity: 256
dispatch_queue_capacity: 64
dispatch_queue_capacity: 16
finalizing_job_expiration_timeout_sec: 300
ready_task_capacity: 65536
ready_task_capacity: 1048576

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

rg -n -C 8 \
  'ready_task_capacity|task_capacity|resources:|limits:|memory:' .

Repository: y-scope/spider

Length of output: 27472


🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

echo "== helm chart templates for scheduler pod =="
for f in $(git ls-files 'tools/deployment/spider-helm/templates/*schedule*' 'tools/deployment/spider-helm/templates/*scheduler*' 'tools/deployment/spider-helm/templates/*' | egrep -i 'scheduler|schedule|deployment|statefulset|daemonset' || true); do
  echo "--- $f"
  wc -l "$f"
  sed -n '1,220p' "$f"
done

echo "== values relevant to scheduler/storage resources =="
sed -n '1,140p' tools/deployment/spider-helm/values.yaml | nl -ba

echo "== search for scheduler image/env/resource references =="
rg -n -C 4 '\${?*scheduler|scheduler.*image|image:|resources:|limits:|memory:|ready_task_capacity|task_capacity|RoundRobinConfig' tools/deployment/spider-helm tools/deployment || true

Repository: y-scope/spider

Length of output: 18540


Confirm scheduler memory before shipping the one-million-task buffer.

ready_task_capacity is the total pending ready tasks buffered in the scheduler, and this value now matches storage.runtime.ready_queue_config.task_capacity. The scheduler deployment does not set Kubernetes resource limits in this chart, and the repository does not contain an OOM/queue-saturation test for the million-entry schedule. Add a memory limit and a load test before release.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tools/deployment/spider-helm/values.yaml` around lines 62 - 67, Before
shipping the one-million-task buffer configured by ready_task_capacity in the
scheduler values, add an explicit Kubernetes memory resource limit to this
chart’s scheduler deployment and create a load test that exercises the
million-entry ready queue, including OOM and queue-saturation behavior. Ensure
the test validates the configured capacity under the deployment’s memory limit.

sitaowang1998
sitaowang1998 previously approved these changes Aug 7, 2026
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